This tutorial is geared towards both novice and advanced Linux users who are either thinking about purchasing a VPS or already own one, and want to setup an easy-to-use BitTorrent client that features a great-looking Web interface. Many people who setup a seedbox default to using rTorrent or Deluge, but Transmission is one that’s often overlooked, despite being feature-rich and reliable.
The biggest reason that some choose to use either rTorrent or Deluge is that a Web-based interface has the potential for being more of a security-risk. This, to me, isn’t a major concern, and I’ve never experienced an issue with mine, but for those who do care a lot about security, I’m going to list some tips to ensure your installation is as secure as possible.
Why do I choose Gentoo, and can this guide apply to other distributions? I choose Gentoo because for VPS use, it’s the easiest to use and manage. There’s a caveat that it has to compile everything it installs, but aside from that, getting Transmission, or even other clients like rTorrent, setup, is an easy process. As for this guide being applicable to other distributions… the answer is “maybe”. Most of the steps will work in all distributions, but the setup process will differ in minor ways.
Step One
Log into your VPS account and then reformat your VPS to use Gentoo. The version doesn’t matter, and neither does it matter whether you install a 32-bit or 64-bit version. If you are planning to A) use your VPS also as a webserver, or B) have more than 3GB of RAM installed, then opt for the 64-bit version if it’s available.
Step Two
If in Windows, connect to your VPS through Putty (http://www.chiark.greenend.org.uk/~sgtatham/putty/).
If on Linux or Mac, you can use whatever terminal application is available to you.
In Putty, the first screen you will see is Session. From here, type in your VPS’ IP address.

I recommend enabling TCP keepalives as well, to ensure that your SSH connection doesn’t timeout during use. For Linux or Mac, a keepalive option might already be enabled, but to verify, look at the documentation for your particular terminal and find out how to change the value.

Step Three
When finished with the configuration, use the Open button to start a connection to your VPS.
Once the connection has been established, you will need to A) log in as root, B) add a personal user account, C) change that account’s password and OPTIONAL D) update the OS.
The last step is optional as it will take a while to update the OS on most VPS machines. If you don’t mind waiting, or have a faster VPS than most, I’d recommend going through the update process for the sake of added security. Most Linux distributions available for VPS aren’t the most up-to-date, so it’s never a bad idea to make sure you’re current.
Alternatively, you can execute the command ‘emerge –sync ; emerge -uDav world‘ instead, which will display the list of packages to be upgraded. From there, you can cancel the update and look through the list, and manually update any packages that look important (openssh would be considered an important one).

If you chose to upgrade the packages on the system, you will want to run ‘etc-update’ after the process is done. This enables you to update configuration files on the fly, and for the most part, you can apply all changes since this is a new install. The OS will automerge non-significant changes, and for the rest, you can type in ‘-3′ and then ‘y’ + ‘enter’ until all the updates are applied.
Step Four
After a primary user has been created and you (may have) updated your OS, you can install Transmission. Like most Linux distributions that have software repositories, Gentoo doesn’t always have the latest version of any piece of software marked as “stable”. Therefore, if you install Transmission as is, you’re likely to get an older version, and that’s not what I’d recommend as later versions feature additional feature and security fixes.
Before installing Transmission, I recommend searching for the package at Package.Gentoo.org and seeing if there is a newer version available. You can also run ‘emerge -s transmission’ to see which version it would install as stable.
http://packages.gentoo.org/package/net-p2p/transmission
On this page, green = stable, orange = unstable and red = bleeding-edge or unavailable. It’s never recommended to install a red version, but if there are orange versions available, then that’s what you’d want to install.
Installing the Stable Version of Transmission
emerge -av transmission
Installing the Unstable Version of Transmission (Recommended)
32-bit OS:
ACCEPT_KEYWORDS=”~x86″ emerge -av transmission
or specific version:
ACCEPT_KEYWORDS=”~x86″ emerge -av =transmission-2.12
64-bit OS:
ACCEPT_KEYWORDS=”~amd64″ emerge -av transmission
or specific version:
ACCEPT_KEYWORDS=”~x86″ emerge -av =transmission-2.12
To see whether you are running the 32-bit or 64-bit version of Gentoo, run ‘uname -a’ at the command-prompt. Unless it specifies something akin to x86-64, it’s the 32-bit version.

Once one of the commands above are executed, the OS will first show you which version is going to be installed, and from there, you can type in ‘y’ or ‘yes’ and then enter to install it and its dependencies.
Step Five
With Transmission installed, close your SSH connection and reconnect using the primary user.
Once connected as a non-root user, type in ‘transmission-daemon’. After hitting enter, nothing will happen, but the program will be running in the background (verify by typing in ‘ps ax | grep transmission’). IMPORTANT: Close down transmission-daemon first before editing the configuration file, as your changes will be overwritten otherwise.

In my case, the program is ID 24040, so to close it:
kill 24040
Since the program was started at least once, a configuration file has been created that you must edit. This is located at /home/username/.config/transmission-daemon/settings.json. You can edit using the program nano. Open it using ‘nano -w /home/username/.config/transmission-daemon/settings.json’.

There are a couple of things to edit here. Here’s a list of the important ones:
“download-dir”: “/home/jackjeckel/Downloads”,
This is the download folder, and can be changed. For the sake of added security, I’d recommend changing it, because if someone does manage to exploit Transmission, it’ll be harder for them to find something when the default folder is changed.
“incomplete-dir”: “/home/jackjeckel/Downloads”,
“incomplete-dir-enabled”: false,
If you want your default download folder to be only for completed downloads, you can change the values here to save incomplete torrents elsewhere.
“peer-limit-global”: 240,
“peer-limit-per-torrent”: 60,
If you are planning to use your seedbox to seed a lot of torrents, these values could be increased accordingly if you believe they will be too limiting.
IMPORTANT SETTING
“rpc-port”: 9091,
This is the port required to connect to the WebInterface. Change it to a similarly high number.
IMPORTANT SETTING
“rpc-authentication-required”: false,
“rpc-password”: “{4ce8feb86766c4793c9213dd281cd1acfc7ef5c0tjSgnTIj”,
“rpc-username”: “”,
You don’t want your Transmission client to be accessible to anyone, so it’s important to create a username and password here, while also enabling the prompt. For the password, just edit the entire string that’s found in between the quotes. Anything you type here will be encrypted to the same hash form next time Transmission is run.
IMPORTANT SETTING
“rpc-whitelist”: “127.0.0.1″,
If you plan to connect to your Transmission client from only one Internet connection, you can change this IP address value to yours (check http://www.ipchicken.com for your IP). But, if your ISP changes your IP address on you often, this isn’t ideal since you will need to log into your VPS via SSH and change the value often. Ideally, a static IP is the way to go, but if that’s not available to you, you can change this value to *.*.*.* which means you can access it from anywhere.
“upload-slots-per-torrent”: 14
To upload to a greater number of people at once on a per-torrent basis, increase this number.
Example Configuration
Changed values have been made bold.
{
“alt-speed-down”: 50,
“alt-speed-enabled”: false,
“alt-speed-time-begin”: 540,
“alt-speed-time-day”: 127,
“alt-speed-time-enabled”: false,
“alt-speed-time-end”: 1020,
“alt-speed-up”: 50,
“bind-address-ipv4″: “0.0.0.0″,
“bind-address-ipv6″: “::”,
“blocklist-enabled”: false,
“blocklist-url”: “http://www.example.com/blocklist“,
“cache-size-mb”: 2,
“dht-enabled”: true,
“download-dir”: “/home/jackjeckel/torrents”,
“encryption”: 1,
“idle-seeding-limit”: 30,
“idle-seeding-limit-enabled”: false,
“incomplete-dir”: “/home/jackjeckel/torrents/incomplete”,
“incomplete-dir-enabled”: true,
“lazy-bitfield-enabled”: true,
“lpd-enabled”: false,
“message-level”: 2,
“open-file-limit”: 32,
“peer-limit-global”: 500,
“peer-limit-per-torrent”: 60,
“peer-port”: 51413,
“peer-port-random-high”: 65535,
“peer-port-random-low”: 49152,
“peer-port-random-on-start”: false,
“peer-socket-tos”: 0,
“pex-enabled”: true,
“port-forwarding-enabled”: true,
“preallocation”: 1,
“ratio-limit”: 2,
“ratio-limit-enabled”: false,
“rename-partial-files”: true,
“rpc-authentication-required”: false,
“rpc-bind-address”: “0.0.0.0″,
“rpc-enabled”: true,
“rpc-password”: “!.super#secret$password”,
“rpc-port”: 6800,
“rpc-username”: “juggalo”,
“rpc-whitelist”: “*.*.*.*”,
“rpc-whitelist-enabled”: true,
“script-torrent-done-enabled”: false,
“script-torrent-done-filename”: “”,
“speed-limit-down”: 100,
“speed-limit-down-enabled”: false,
“speed-limit-up”: 100,
“speed-limit-up-enabled”: false,
“start-added-torrents”: true,
“trash-original-torrent-files”: false,
“umask”: 18,
“upload-slots-per-torrent”: 50
}
Once finished editing the configuration, you can hit Ctrl + X to exit, at which point nano will ask you if you want to save. Type in ‘y’ and then enter to save the changes.
Step Six
It’s time to take Transmission for a spin! With the configuration file all edited, start Transmission again with ‘transmission-daemon’. This will start the service and allow you to connect to it through a browser.

The UI at first might look quite bland, but that’s because there are no torrents!

See how much better it looks when there are a slew of torrents loaded into it? From here, you can begin to add torrents using the “Open” button. If you want to save the torrents to a different folder than default, you can click the small icon to the bottom-left corner and change the default folder there (making sure to change it back again after the torrent has been added).
Happy torrenting!








