[HELP] Automatic Renaming and Moving to Freenas

Running FileBot from the console, Groovy scripting, shell scripts, etc
Post Reply
bevoh
Posts: 4
Joined: 08 Jul 2015, 01:37

[HELP] Automatic Renaming and Moving to Freenas

Post by bevoh »

I am running Windows 8.1 with FileBot 4.6.

I have my Utorrent Downloads set to download to a directory on this computer and I want FileBot to check that folder, rename and move the files to directories on my Freenas server that I have just built. Permissions on freenas are set so that anyone can copy data it's CIFS share so that should be fine.

This is the what I have put in uTorrent's Run Program Script

filebot.launcher -script fn:amc --output "\\freenas\BEVShare" --log-file amc.log --action copy --conflict override -non-strict --def "ut_dir=%D" "ut_file=%F" "ut_kind=%K" "ut_title=%N" "ut_label=%L" "ut_state=%S"

Is this okay? Or should the directory be different? Or is this not even possible? Sorry I'm relatively new to the whole server thing but I have decent general PC knowledge so I am keen to get this fixed and working. I am using the GUI script as per the guide ratehr than the cmdline as I don't really want a pop up to steal focus every time something finishes downloading.

Utorrent logger showed that it executed the script but I dont think it renamed the file and it definitely did not move it to the freenas directory.

Is there any logs or additional information I can provide and if so where/how do I obtain it?

Thanks for providing this solution and I hope i can get it working soon.
bevoh
Posts: 4
Joined: 08 Jul 2015, 01:37

Re: [HELP] Automatic Renaming and Moving to Freenas

Post by bevoh »

Okay I have got the script running and it is a dream. Updated Java and changed to absolute path. Also mounted my freenas on a drive letter to use that directory. Thankyou for all your work with this software.

2 Questions Though.

1. Is it possible to run this script on my current downloads folder and have it rename and move them to my NAS?

2. Can the script actually move instead of copy or at least delete the original copy of it so it is not stored on the client PC and only on the NAS? Or do you have to do this manually? (The original idea of the NAS was to free up storage on this machine)

Edit: Answered number 2 with a bit of research.

Script now looks like this and works quite well.

Code: Select all

"C:\Program Files\FileBot\filebot.launcher.exe" -script fn:amc --output "Z:\Media" --log-file amc.log --action move --conflict override -non-strict --def "ut_dir=%D" "ut_file=%F" "ut_kind=%K" "ut_title=%N" "ut_label=%L" "ut_state=%S" --def clean=y
Cheers!
User avatar
rednoah
The Source
Posts: 23953
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: [HELP] Automatic Renaming and Moving to Freenas

Post by rednoah »

1.
Yes. Why not? It's just a command-line tool. :D

2.
Yes. But if utorrent is keeping file locks it's simply not gonna work. There is no support for talking to utorrent to remove torrents prior to removing the files.

I highly recommend keeping downloads and organised files in the same filesystem so you can use hardlinks (file pointer copy) instead of copies (file content copies). Best of both works. ;)
:idea: Please read the FAQ and How to Request Help.
bevoh
Posts: 4
Joined: 08 Jul 2015, 01:37

Re: [HELP] Automatic Renaming and Moving to Freenas

Post by bevoh »

rednoah wrote:1.
Yes. Why not? It's just a command-line tool. :D
Okay thanks. So I can just use the AMC script but change the input? What is the command to make it scan a folder instead of after running after torrent is finished? --input my/download/folder or something like this?

Sorry very new to this whole scripting thing.
bevoh
Posts: 4
Joined: 08 Jul 2015, 01:37

Re: [HELP] Automatic Renaming and Moving to Freenas

Post by bevoh »

@rednoah

I think I've got it working with this

filebot -script fn:amc --output "Z:\Media" --log-file amc.log --action copy -non-strict -extract -r "G:\Downloads\Complete\Media" --def excludeList=amc.txt

Hasn't finished yet but seems to be working it's magic. Thought I'd post what worked for me in case anyone else stumbles across the thread.

Thanks again for the software and support. Very much appreciated.
Post Reply