Self-hosted FOSS cloud step 5.1: Transmission bittorrent client (headless mode) and its web GUI on Debian

A short memo on how to install the Transmission bittorent client and control it from a web GUI, both of them running on a headless server. The aim is to replace the “download station” bundled in the Synology NAS software (DSM), see http://julien.coubronne.net/a-self-hosted-fr…opensource-cloud/

Install Transmission

sudo aptitude install transmission transmission-deamon

It should install automatically transmission-cli and transmission-common.

Configuration

You need to stop the daemon, as the daemon overwrites its configuration file when exited (hence discarding all changes you may have done while the daemon was running).

sudo service transmission-daemon stop

You can then modify its configuration file (after a backup).

sudo cp /var/lib/transmission-daemon/info/settings.json /var/lib/transmission-daemon/info/settings.json.orig

sudo nano /var/lib/transmission-daemon/info/settings.json

I modified the following main parameters:

  • “download-dir”: “/path/to/downloads”,
  • “incomplete-dir”: “/path/to/downloads/incomplete”,
  • “incomplete-dir-enabled”: true,
  • “rpc-password”: “new password”,
  • “rpc-username”: “new user”,
  • “rpc-whitelist”: “127.0.0.1,192.168.*.*”,

The default password and user are: Transmission. You should change this default value. You can replace the long hashed value in rpc-password by your new password, it will be hashed at the next startup.

You can find more details on the transmission wiki page.

Addressing specific users, groups, and file rights

Transmission runs under a specific user (debian-transmission), itself member of a specific group (debian-transmission). To avoid conflicts in the files created by the daemon, you should add your user to the same group:

sudo usermod -a -G debian-transmission user

(Here replace “user” by your specific user).

You also need to change the group owner of the folder where Transmission will download its files:

sudo chgrp -R debian-transmission /path/to/downloads

You may see that the current file rights do not allow the group to write within this folders. You need to change the rights to “775” (rwxrwxr-x):

sudo chmod -R 775 /mnt/data01/Partage/Downloads

For further info on linux file rights, refer to: http://www.codecoffee.com/tipsforlinux/articles/032-2.html

You can now start the daemon:

sudo service transmission-daemon start

Finally… open your firewall / router

You also need to make sure that the correct port is opened in your firewall / router.

You can access the web interface on http://myserver.com:9091 (if you plan to access this interface from a remote network, you’ll need to include your IP address in the list of “rpc-whitelist” and open the port 9091 in your router).

 

Ressources:

  • https://wiki.debian.org/BitTorrent/Transmission
  • https://help.ubuntu.com/community/TransmissionHowTo
  • http://www.htpcbeginner.com/install-transmission-web-interface-on-ubuntu-1204/

Leave a Reply