Page 3 of 5

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 02 Mar 2014, 17:00
by rednoah
1. RTFM
--def clean=y Automatically empty folders and clutter files that may be left behind after moving the video files or temporary extracted files after copying

2. Yes, it's very easy for anyone who knows a bit of programming

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 12 Mar 2014, 13:49
by plittlefield
I cannot seem to get Transmission to run my script.

I have downloaded the original amc.groovy file and tweaked it to work with my directories.

If I run it manually substituting the Transmission variables for full paths and filenames etc. it works.

If I run it manually passing the Transmission variables for full paths and filenames etc. it works.

But Transmission does not run it itself.

My settings and files are as follows:-

Code: Select all

#!/bin/bash
# transmission_filebot.sh
/usr/bin/filebot -script "/home/paully/Bin/amc_paully.groovy" --output "/home/paully/Videos" --log-file "/home/paully/.filebot/logs/amc_paully.log" --action copy --conflict override -non-strict --def "ut_dir=$TR_TORRENT_DIR/$TR_TORRENT_NAME" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME"

Code: Select all

/etc/transmission-daemon/settings.json
"script-torrent-done-enabled": true, 
"script-torrent-done-filename": "/home/paully/Bin/transmission_filebot.sh",
Any ideas?

Thanks

:-)

Paully

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 12 Mar 2014, 15:33
by rednoah
Could you be missing a simple chmod +x? Or some other type of permission issue that would stop transmission from executing the script?

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 12 Mar 2014, 17:48
by plittlefield
All good as far as I can see...

Code: Select all

-rwxrwxr-x 1 paully paully 344 Mar 12 14:10 /home/paully/Bin/transmission_filebot.sh*
...and besides it works when I feed it variables...

Code: Select all

$ TR_TORRENT_DIR="/home/paully/Downloads/transmission/tv" TR_TORRENT_NAME="Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE" ~/Bin/transmission_filebot.sh
...and the log file shows...

Code: Select all

Parameter: ut_dir = /home/paully/Downloads/transmission/tv/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE
Parameter: ut_kind = multi
Parameter: ut_title = Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE
Read archive [marvels.agents.of.s.h.i.e.l.d.s01e15.720p.hdtv.x264-remarkable.rar] and extract to [/home/paully/Downloads/transmission/tv/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE/marvels.agents.of.s.h.i.e.l.d.s01e15.720p.hdtv.x264-remarkable/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE]
Extracting files [/home/paully/Downloads/transmission/tv/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE/marvels.agents.of.s.h.i.e.l.d.s01e15.720p.hdtv.x264-remarkable/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE.mkv]
Input: /home/paully/Downloads/transmission/tv/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE/marvels.agents.of.s.h.i.e.l.d.s01e15.720p.hdtv.x264-remarkable/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE.mkv
Group: [tvs:Marvels Agents of S H I E L D] => [Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE.mkv]
Rename episodes using [TheTVDB]
Auto-detected query: [Marvels Agents of S H I E L D]
Fetching episode data for [Marvel's Agents of S.H.I.E.L.D.]
[COPY] Rename [/home/paully/Downloads/transmission/tv/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE/marvels.agents.of.s.h.i.e.l.d.s01e15.720p.hdtv.x264-remarkable/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE/Marvels.Agents.of.S.H.I.E.L.D.S01E15.720p.HDTV.x264-REMARKABLE.mkv] to [/home/paully/Videos/TV/Marvel's_Agents_of_S_H_I_E_L_D/Marvel's_Agents_of_S_H_I_E_L_D_S01E15.mkv]
Processed 1 files
Done ヾ(@⌒ー⌒@)ノ
...it just won't do it on its own.

:-(

Paully

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 12 Mar 2014, 18:15
by rednoah
Then I guess the next step is figure out why transmission is not calling the script, or any scripts for that matter. Try posting in their forums as well.

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 13 Mar 2014, 08:24
by plittlefield
I will, good idea... however...

I used to have a simple script to output exactly those same variables to a text log file.

Code: Select all

#!/bin/bash
# torrent_done.sh
{
LOG_FILE=/tmp/torrent_done.log
echo "${TR_TORRENT_ID}/${TR_TORRENT_DIR}/${TR_TORRENT_NAME}" >>$LOG_FILE
} &
That's been working perfectly for the last year!

Could it be to do with Java versions?

The saga continues...

:-\

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 13 Mar 2014, 09:13
by plittlefield
I have put back the original script to test it tonight.

Code: Select all

/etc/transmission-daemon/settings.json
"script-torrent-done-enabled": true, 
"script-torrent-done-filename": "/home/paully/Bin/torrent_done.sh",
PS: I have tried 3 times to register on the Transmission forum, it's not easy!

:-)

Paully

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 13 Mar 2014, 10:28
by rednoah
Well, if the script is called then why don't you add lots of logging and output redirects so you can figure out what it says and where exactly it fails?

If the script is run correctly then it can't not work.

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 13 Mar 2014, 11:54
by plittlefield
I am going to test it tonight using my old simple logging script (which uses exactly the same TR_ variables!), then try the filebot version again tomorrow.

I have posted on the Transmission forum for any thoughts.

I DO love a challenge...

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 14 Mar 2014, 16:24
by plittlefield
Well, needless to say my old script was run by Transmission as expected and gave me my log file...

Code: Select all

/tmp/torrent_done.log
1//home/paully/Downloads/transmission/tv/The.Big.Bang.Theory.S07E18.720p.HDTV.X264-DIMENSION
2//home/paully/Downloads/transmission/tv/The.Crazy.Ones.S01E18.720p.HDTV.x264-KILLERS
...so, it's not Transmission!

Any other ideas?

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 14 Mar 2014, 16:49
by plittlefield
Aaaaah, I think I may have found something in the debug logs...!

Code: Select all

/home/paully/.filebot/logs/amc_paully.log (Permission denied)
Ofcourse, the script is being run by the transmission-daemon user and group...!

So, if I change the group ownership of my ~/.filebot folder to the same group as Transmission, and make it writeable then the error should go and the Filebot script should run...

Code: Select all

chgrp -R debian-transmission ~/.filebot
chmod -R g+w ~/.filebot
...fingers crossed tonight.

:-)

Paully

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 14 Mar 2014, 17:40
by rednoah
Yes, naturally filebot will not full access to it's application data folder, the log is the first thing that fails, but more importantly it'll need it a place to cache some data.

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 14 Mar 2014, 19:01
by plittlefield
OK, fixed it completely and it's so annoyingly simple.

Change the user transmission-daemon runs as, then fix folder ownership.

Code: Select all

$ sudo /etc/init.d/transmission-daemon stop
$ sudo nano /etc/init.d/transmission-daemon
  USER=paully
$ sudo chown paully /etc/transmission-daemon/*
$ sudo chown -R paully /var/lib/transmission-daemon/
$ sudo /etc/init.d/transmission-daemon start
Transmission then downloads all torrents as my username and so Filebot uses those variables and copies files into folders already owned by me.

Growl, sigh, and general comments like "yeah, why isn't that in the documentation?!?... mumble, moan."

:-)

Paully

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 14 Mar 2014, 19:45
by rednoah
You're welcome to write an extra thread on this issue, or an improved / alternate tutorial for setting things up correctly. ;)

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 15 Mar 2014, 13:06
by plittlefield
OK, I'll put it on my list of things to do :-)

I will donate now too.

Thanks.

Paully

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 16 Jun 2014, 18:01
by ErsinB
I'm having some trouble since the update. My AMC doesn't work anymore. I just read every single topic about this, but couldn't fix it. I'll be delighted if someone could help me with this.

I'm just using the simple script:

Code: Select all

#!/bin/bash
/Applications/Filebot.app/Contents/MacOS/filebot -script fn:amc --output "/Users/ErsinB/Downloads" --log-file amc.log --action copy --conflict override -non-strict --def artwork=n subtitles=en,nl --def [email protected] "ut_dir=$TR_TORRENT_DIR/$TR_TORRENT_NAME" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME"
But this didn't execute the automatic renaming proces after a download. If I execute this file terminal gives me this:
Last login: Mon Jun 16 19:04:42 on ttys000
imac-van-ersinb:~ ErsinB$ /Users/ErsinB/Desktop/transmission-postprocess ; exit;
/Users/ErsinB/Desktop/transmission-postprocess: line 2: /Applications/Filebot.app/Contents/MacOS/filebot: No such file or directory
logout

[Proces voltooid]
So I looked in the /Applications/Filebot.app/Contents/MacOS/filebot folder, and only saw filebot.sh. So i changed the script into this:

Code: Select all

#!/bin/bash
/Applications/Filebot.app/Contents/MacOS/filebot.sh -script fn:amc --output "/Users/ErsinB/Downloads" --log-file amc.log --action copy --conflict override -non-strict --def artwork=n subtitles=en,nl --def [email protected] "ut_dir=$TR_TORRENT_DIR/$TR_TORRENT_NAME" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME"
This still didn't rename any downloaded file. When I execute this terminal tells me:
Last login: Mon Jun 16 19:43:13 on ttys000
/Users/ErsinB/Desktop/transmission-postprocess ; exit;
imac-van-ersinb:~ ErsinB$ /Users/ErsinB/Desktop/transmission-postprocess ; exit;
Exception in thread "main" java.lang.UnsupportedClassVersionError: net/filebot/Main : Unsupported major.minor version 51.0
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClassCond(ClassLoader.java:637)
at java.lang.ClassLoader.defineClass(ClassLoader.java:621)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
logout

[Proces voltooid]
I already installed Oracle Java SE Runtime Environment 8, that didn't solve anything. I tried to delete/reinstall the latest FileBot, but that didn't fix it neither. So I'm out of ideas.

Could someone help me with this? What am I doing wrong?

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 16 Jun 2014, 18:26
by rednoah
You're still running Java 6. Use google to figure out how to make it use Java 8 instead.

Java 6 runtime telling you that it can't run Java 7 code:

Code: Select all

Exception in thread "main" java.lang.UnsupportedClassVersionError: net/filebot/Main : Unsupported major.minor version 51.0

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 16 Jun 2014, 18:46
by ErsinB
Ok, I think I fixed that. Terminal gives me this when I ask for the current version:
Last login: Mon Jun 16 20:41:06 on ttys000
imac-van-ersinb:~ ErsinB$ java -version
java version "1.8.0_05"
Java(TM) SE Runtime Environment (build 1.8.0_05-b13)
Java HotSpot(TM) 64-Bit Server VM (build 25.5-b02, mixed mode)
imac-van-ersinb:~ ErsinB$
But when I execute the transmission-postprocess, it gives me this now:
Last login: Mon Jun 16 20:44:30 on ttys000
imac-van-ersinb:~ ErsinB$ /Users/ErsinB/Desktop/transmission-postprocess ; exit;
Locking /Users/ErsinB/.filebot/logs/amc.log
Parameter: artwork = n
Parameter: subtitles = en,nl
Parameter: mailto = *****
Parameter: ut_dir = /
Parameter: ut_kind = multi
Parameter: ut_title = null
NullPointerException: java.lang.NullPointerException
java.lang.NullPointerException
at net.filebot.media.ReleaseInfo$FolderEntryFilter.accept(ReleaseInfo.java:421)
at net.filebot.media.MediaDetection.isDiskFolder(MediaDetection.java:92)
at net.filebot.cli.ScriptShellMethods.isDisk(ScriptShellMethods.java:89)
at Script1.resolveInput(Script1.groovy:141)
at Script1$_resolveInput_closure80.doCall(Script1.groovy:142)
at Script1.resolveInput(Script1.groovy:142)
at Script1$_run_closure46.doCall(Script1.groovy:165)
at Script1.run(Script1.groovy:165)
at net.filebot.cli.ScriptShell.evaluate(ScriptShell.java:60)
at net.filebot.cli.ScriptShell.runScript(ScriptShell.java:81)
at net.filebot.cli.ArgumentProcessor.process(ArgumentProcessor.java:108)
at net.filebot.Main.main(Main.java:192)
Failure (°_°)
logout

[Proces voltooid]
So what's wrong now :?

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 16 Jun 2014, 19:06
by rednoah
The environment variables that transmission should be passing in are not passed in.

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 16 Jun 2014, 19:21
by ErsinB
Which means?

I justed tested it with a download, it did proces everything. Renaming, downloading subs and creating a folder. Everything just worked. I don't know why and how, but it did :D.

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 17 Jul 2014, 16:37
by Meph88
Hi guys,

I am having major issues here.
I just got a mac mini and am fairly new to the mac OS environment.
I have the filebot postprocess running on a Windows 8.1 PC perfectly but want to move these processes to the new mac mini.
I've tried a few variations to get this working and I have followed the instructions here exactly but it appears that transmission is not running the script I'm telling it to.

The script I have set up and am attempting to use is as follows:

#!/bin/bash
/Applications/Filebot.app/Contents/MacOS/filebot.sh -script fn:amc --output "/Users/KevsMacMini/Documents/Sorted” --log-file amc.log --action copy --conflict override -non-strict --def music=y subtitles=en artwork=y plex=http://plexserver/web/index.html pushover=xxxxxxxxxx "ut_dir=$TR_TORRENT_DIR/$TR_TORRENT_NAME" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME"

Obviously I changed the plex and pushover specifics but I can not for the life of me get this to do anything. The torrent files download and then........ nothing else happens.

Please help me. I have tried for hours, I believe I am close but just can't get this running.

To add from the above, I have tried running in terminal this:
#!/bin/bash
/Applications/Filebot.app/Contents/MacOS/filebot.sh -script fn:amc "/Users/KevsMacMini/Documents/TestDLlocation" --output "/Users/KevsMacMini/Documents/Sorted" --action move --conflict override -non-strict --def music=y artwork=y --def excludeList=excludelog.txt

This script works fine and I'm able to use it to organise files but the automated postprocess I can not get working.

Any help is appreciated.

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 04 Aug 2014, 19:56
by DrKnate
Try to just install the Java 8 JDK, it will change all the variables needed during the install.

http://www.oracle.com/technetwork/java/ ... 33151.html


After Installing:

Code: Select all

$ java -version
java version "1.8.0_11"
Java(TM) SE Runtime Environment (build 1.8.0_11-b12)
Java HotSpot(TM) 64-Bit Server VM (build 25.11-b03, mixed mode)

Seems to work now.

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 11 Oct 2014, 18:30
by iMe
Hi guys,

There is a way to run a program feature in uTorrent for Mac but you'll have to use it via remote.utorrent.com after you set the login settings in uTorrent preferences

Image

So, can anyone make a tutorial about Mac+uTorrent?

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 31 Oct 2014, 12:16
by donok
Hi,

I tried to set up filebot with transmission on Mac OS X 10.10 and can't make it work. I installed filebot with Homebrew cask as detailed here http://www.filebot.net/forums/viewtopic.php?f=4&t=2049

I created a script as suggested

Code: Select all

#!/bin/bash

filebot -script fn:amc --output "/Volumes/Media" --log-file amc.log --action copy -non-strict "ut_dir=$TR_TORRENT_DIR/$TR_TORRENT_NAME" "ut_kind=multi" "ut_title=$TR_TORRENT_NAME"

The script works perfectly when called from Terminal, but doesn't run when called from Transmission.

It tried to add log monitoring to the script to make sure it is called by Transmission, and that works perfectly. The script is called, but the filebot action is not performed and the argument are correctly passed
I also tried with a fixed input folder

Code: Select all

#!/bin/bash

filebot -script fn:amc --output "/Volumes/Media" --log-file amc.log --action copy -non-strict "/Users/Myself/Downloads"  

Again, works fine when called from Terminal, no action when called from Transmission.

Any other idea why filebot is not cooperative when called from Transmission script ??

Thanks

Re: [GUIDE] Fully Automated Media Center with Transmission (

Posted: 31 Oct 2014, 15:11
by rednoah
So it works if you run it yourself but not from transmission? And you made sure the script is called by redirecting output? Try redirecting filebot output (including error output!!!) to a file and see what it says.