Skip to main content

Raymii.org Raymii.org Logo

Quis custodiet ipsos custodes?
Home | About | All pages | Cluster Status | RSS Feed

Transmission Web on a Raspberry Pi with Arch Linux

Published: 28-04-2014 | Author: Remy van Elst | Text only version of this article


❗ This post is over ten years old. It may no longer be up to date. Opinions may have changed.

transmission

One of my Raspberry Pi's was running a test setup of the Citadel groupware service. The test was sucessfull, so I set up a real world setup. The Raspberry Pi would serve another purpose, namely, a Linux Torrent seedbox. As in, to seed Linux torrents from linuxtracker.org.

Recently I removed all Google Ads from this site due to their invasive tracking, as well as Google Analytics. Please, if you found this content useful, consider a small donation using any of the options below:

I'm developing an open source monitoring app called Leaf Node Monitoring, for windows, linux & android. Go check it out!

Consider sponsoring me on Github. It means the world to me if you show your appreciation and you'll help pay the server costs.

You can also sponsor me by getting a Digital Ocean VPS. With this referral link you'll get $200 credit for 60 days. Spend $25 after your credit expires and I'll get $25!

I choose Transmission for this, because it is simple, fast and stable. Transmission has a good webinterface, plus it allows access from remote clients with the transmission-remote gui packages.

My Pi's run Arch Linux, so setup of Transmission is fairly easy. First install it with pacman:

sudo pacman -Syu transmission-cli

Enable the service at startup:

sudo systemctl enable transmission

Start the service:

sudo systemctl start transmission

Create a folder where your user and the transmission group (where the transmission user belongs to) can read and write:

sudo mkdir -p /mnt/data/torrents/{incomplete,complete,torrentfiles}
sudo chown -R remy:transmission /mnt/data/torrents
sudo chmod -R 775 /mnt/data/torrents

In my example the folder /mnt/data/torrents is an external USB harddrive which is mounted via /etc/fstab at boot. Remember to change remy to your Pi username.

Stop the daemon to make sure the config file edits stick:

sudo systemctl stop transmission

Edit the default config file to allow remote access to the daemon (or do not do that and use an ssh tunnel every time) and update the downloads path:

sudo vim /var/lib/transmission/.config/transmission-daemon/settings.json

Change the following parameters:

    # From
    "download-dir": "/var/lib/transmission/Downloads",
    # To
    "download-dir": "/mnt/data/torrents/complete",

    # From:
    "incomplete-dir": "/var/lib/transmission/Downloads",
    # To
    "incomplete-dir": "/mnt/data/torrents/incomplete",

    # From
    "incomplete-dir-enabled": false,
    # To
    "incomplete-dir-enabled": true,

    # From
    "rpc-whitelist": "127.0.0.1",
    # To
    "rpc-whitelist": "*.*.*.*",

This sets the correct download folders and allows access from everywhere to the transmission webinterface. You can also list a range there (192.168.1.0/24) or just one IP address.

If you do not udate the ACL you get a nice error message when connecting:

403: Forbidden

Unauthorized IP Address.

Either disable the IP address whitelist or add your address to it.

If you're editing settings.json, see the 'rpc-whitelist' and 'rpc-whitelist-enabled' entries.

If you're still using ACLs, use a whitelist instead. See the transmission-daemon manpage for details.

If all went well you should be able to connect to http://YOUR-PI-IP:9091 and see the nice transmission webinterface.

If you are going to download copyrighted material you might want to enable a blocklist, see iblocklist.com for more info on that.

If you want more info on Transmission on Arch Linux, read up on the arch wiki.

Tags: arch , blog , linux , linuxtracker , raspberry-pi , systemd , torrent , torrents , transmission