Editing rtorrent.rc

The configuration file for rTorrent is located at ~/.config/rtorrent/rtorrent.rc


Edit at your own risk. You are responsible for any changes. Please be careful, and only do things you understand how to do. There are a couple things you need to keep in mind:

  1. Be sure this file is saved with \n (LF) line breaks. If you're connecting via SSH and using nano (or similar), this shouldn't be a problem. However, if you're on Windows and are (S)FTP'ing the file to your computer, there's a chance that the line breaks may change. If there aren't LF line breaks, rTorrent will not start.
  2. Please respect the fact that this is a shared server. Hash checking on completion is disabled because most times it will spike the load while it's checking the files. For large torrents, this can take a very long time, and generally isn't even needed.
  3. scgi_local must not be changed, in order for ruTorrent (and wTorrent) to work. If you choose to use nTorrent or have another reason to connect to rTorrent using xmlrpc, you can access it through HTTPS using:
    Protocol: HTTPS
    Host: server.whatbox.ca
    Port: 443
    Mountpoint: /xmlrpc
    Username: user
    Password: <password>

Manipulating rtorrent.rc

To edit rtorrent.rc you will need to be able to connect to your server through SSH. Changes only take effect after restarting rTorrent. rTorrent can be restarted from your Manage page.

Resetting to default configuration

If you make a mistake, the configuration can be reset to Whatbox defaults with the following commands:

cp /etc/skel/.config/rtorrent/rtorrent.rc ~/.config/rtorrent/rtorrent.rc
ln -s ~/.config/rtorrent/rtorrent.rc ~/.rtorrent.rc

Backing up and restoring configurations

To make a backup copy of your current configuration before making modifications use:

cp ~/.config/rtorrent/rtorrent.rc ~/.config/rtorrent/rtorrent.rc.backup

To restore a backup use:

mv ~/.config/rtorrent/rtorrent.rc.backup ~/.config/rtorrent/rtorrent.rc

Editing rtorrent.rc

While you can edit rtorrent.rc over FTP, it is recommended that you edit it over SSH. The easiest editor for a beginner to use is nano. For in depth information on nano, see their documentation. Otherwise, stick to the basics:

Open rtorrent.rc using nano ~/.config/rtorrent/rtorrent.rc
Navigate using arrow keys
Save using Ctrl-O
Exit using Ctrl-X


In rtorrent.rc each line represents a command (or setting). Lines prefixed with # are comments. These lines do not affect the configuration of rTorrent.

Common Tasks

Remove data when erasing a torrent:

method.set_key = event.download.erased, rm_complete,"execute={rm,-drf,--,$d.get_base_path=}"

Add another watch directory (replace "watchdirectory" with the directory you want watched):

schedule = watch_directory_2,5,5,load.start=~/watchdirectory/*.torrent

Set a different download directory for a watch directory (replace "downloaddirectory" with the directory you want watched):

schedule = watch_directory_2,5,5,"load.start=~/watchdirectory/*.torrent,d.set_directory=~/downloaddirectory/"

Adding more than one watch or download directory

If you wish to add more than one watch or download directory, you must number then sequentially. Example:

schedule = watch_directory_2,5,5,load.start=~/watchdirectory/*.torrent
schedule = watch_directory_3,5,5,load.start=~/watchdirectory_another/*.torrent
schedule = watch_directory_4,5,5,load.start=~/watchdirectory_yetanother/*.torrent