Running FileBot from the console, Groovy / FileBot scripting, shell scripts, etc
Post Reply
Posts: 2
Joined: 22 Nov 2018, 07:17


Post by ryan2600 » 22 Nov 2018, 16:59

First time poster (appoligies for my n00bish formatting), long time browser. Looking for help to get rTorrent to kick off filebot AMC script after a torrent is finished downloading. I've been going after this for a few days now and can't seem to figure out why rTorrent is not triggering filebot. My filebot/amc script works fine when I run it manually against the completed torrent folder. My rtorrent.rc config is below and you'll see I've made some adjustments with no luck. I cant even figure out why its not logging anything. I'm running this off a ubuntu 18 headless server and a docker container from bytesized hosting.

rtorrent.rc file:

Code: Select all

execute = {sh,-c,/usr/bin/php7 /usr/share/webapps/rutorrent/php/initplugins.php bytesized &}
execute.nothrow = rm,/run/php/.rtorrent.sock
network.scgi.open_local = /run/php/.rtorrent.sock
schedule = socket_chmod,0,0,"execute=chmod,0660,/run/php/.rtorrent.sock"
schedule = socket_chgrp,0,0,"execute=chgrp,abc,/run/php/.rtorrent.sock"
log.open_file = "rtorrent", /config/log/rtorrent/rtorrent.log
log.add_output = "info", "rtorrent"
min_peers = 40
max_peers = 1200
max_uploads = 50
download_rate = 300000
upload_rate = 300000
# schedule = watch_directory_1,5,5,"load.start=/data/watch/*.torrent"
directory = /data/completed
session = /config/rtorrent/rtorrent_sess
schedule = low_diskspace,5,60,close_low_diskspace=200M
bind =
port_range = 6826-6826
#check_hash = yes
use_udp_trackers = yes
encryption = allow_incoming,try_outgoing,enable_retry
dht = auto
check_hash = no
port_random = no
dht_port = 3682
peer_exchange = yes
# scgi_port =
encoding_list = UTF-8
system.umask.set = 002
method.set_key = event.download.finished,filebot,"execute.throw.bg={/home/bytesized/config/rtorrent/rtorrent/rtorrent-postprocess.sh,$d.base_path=}"
log.execute = /tmp/exec.log
In addition any insight as to why rTorrent is not kicking off filebot, is there a way to manually kick off rTorrent's "method.set_key event.download.finished" logic so that its easier to test? Currently, every time I make a change to the rTorrent.rc file, I download another torrent to see if it kicked off.

Thanks in advance and happy thanksgiving!


User avatar
The Source
Posts: 18361
Joined: 16 Nov 2011, 08:59
Location: Taipei

Re: rTorrent

Post by rednoah » 22 Nov 2018, 17:06

How did you come up with this? Does rTorrent call your script at all? :arrow: viewtopic.php?f=4&t=3067

Code: Select all

method.set_key = event.download.finished,filebot,"execute.throw.bg={/home/bytesized/config/rtorrent/rtorrent/rtorrent-postprocess.sh,$d.base_path=}"

Have you tried the official setup guide yet?

That would add a config line like this:

Code: Select all

:idea: Please read the FAQ and How to Request Help.

Posts: 2
Joined: 22 Nov 2018, 07:17

Re: rTorrent

Post by ryan2600 » 22 Nov 2018, 17:16

This is really embarrassing... apparently I got it to work last night at 2am but didn't see it. This morning I had commented out the method.set line to try and get the log file to work. I just looked in plex and saw some of the torrents I tested last night had been added automatically. I enabled the method.set line, downloaded a torrent, and bam it worked.

1. I came up with that based on a number of other posts I researched on google. https://github.com/rakshasa/rtorrent/issues/579

2. Yup, started with the setup guide and made adjustments from there. Guess I did get it working last night but my eyes were falling out of my head. Always good to take a break and come back fresh.

Thanks again for your reply!

Post Reply