Ultimate Home Server Part 6 – Download Server

We’re now firmly in the realms of having a really usable server. It’s storing our data with redundancy, it’s accessible from other devices on our network and it’s serving up media to our connected devices.

But we can do more, in this part I’ll show you how to set up your server to act as a central download server.

This might seem like a strange role when you can just download pretty much any file to your PC, laptop or mobile phone, but there are some advantages.

For one, if you have a slow internet connection it means you don’t have to leave another device on when you’re downloading large files. Your server is designed to run 24×7 anyway, so it’s important it’s doing as much as possible in order to be as green as possible.

We’re going to use a program called Transmission to fulfill the “download server” role. It’s a great open-source application which can download torrents (including via magnet links) as well as download files directly from websites just by copying the link to the file.

Installing Transmission

The first step is to add the online repository for Transmission. A repository is a place for developers to store their application so that it can be downloaded by ordinary users. By adding the repository to our Ubuntu system we’re basically saying “check this repository when you look for updates”

Open a terminal (or an SSH session) and type the following:

sudo add-apt-repository ppa:transmissionbt/ppa

Next, update repositories so that your server checks for files:

sudo apt-get update

Next type the following to install Transmission:

sudo apt-get install transmission-cli transmission-common transmission-daemon

You may be prompted to confirm installation of packages, press Y.

Once the installation is complete you’ll need to configure Transmission.

Configuring Transmission

The first step is to stop the Transmission-daemon from running so that you can make changes to the configuration files:

sudo service transmission-daemon stop

Next you’ll need to open the Transmission configuration file:

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

The configuration file for Transmission will open in your terminal window.

You’ll need to change a few settings from the default for security and usability

The default username and password are both “transmission”. You can leave these as they are, but if you want to restrict access to the web interface you can change them by ammending the following two lines:

"rpc-password": "{62b16db87b89a91dd49a5110a7cafc06d20eb4f2wtK6kqPj",
"rpc-username": "transmission",

Just change the text inside the inverted commas on both lines to change the username and password.

The next step is to add your home networks IP range to the whitelist so that other devices on your home network can connect to the Transmission web interface. Find the line:

"rpc-whitelist": "",

And ammend it to include addresses on your home network, you can use an asterisk as a wildcard to allow a range of devices permission to connect:

 "rpc-whitelist": ",192.168.0.*", 

You’ll also need to change a line called “umask” from the default reading of “18” to a new reading of “2”. This gives all connected users permission to access files and folders created by Transmission:

"umask": 2,

Lastly use Ctrl+O to save the changes to the file, then Ctrl+X to close the file.

The last stage of configuration is to restart the Transmission daemon so that the configuration changes take effect:

sudo service transmission-daemon start

Using Transmission

If everything has gone to plan you should be able to open a web browser from any machine on your network and access the Transmission web interface by typing in the following:

http://*your server IP*:9091

You’ll be prompted for a user name and password, use the credentials you saved in the configuration file, or the defaults of “transmission””transmission” if you didn’t change them.

You’ll be presented with the Transmission web interface:

There are a few steps we need to complete before we can download anything. Click on the Spanner in the bottom-left toolbar, a menu pops up:

Change the “Download to:” field so that it matches a location in your RAID array. If you’ve followed the previous parts in this guide then the folder above will work.

Click on the “Network” tab in the Window and you’ll see the following:

The Listening Port needs to be open in order for Torrent downloads to work. In some home setups this will be automatic and you won’t need to do anything.

But if the text above reads “Port is Closed” then you’ll need to setup port forwarding for port 51413 on your router. The process for doing this is different for every router, so if you don’t know how to do this the best thing to do is Google “port forwarding” and your router model, you should find a usable guide to help you.

With these changes complete Transmission is now setup properly and you should be able to use it to download Torrented files directly to your server.

To download a Torrent, Magnet or online file from within the Transmission web interface click on the Blue folder on the toolbar at the top of the screen:

The following window will come up:

If you have a Torrent file for your download, click “Choose Files” and click Upload.

If you have a Magnet link or a link to a file online, paste the URL into the text box and click Upload.

You’ll be returned to the main Transmission window and should see the download job queued up. The progress bar and information will show how much of the file has been downloaded. When a line reaches 100% you’ll be able to see it in the Downloads folder on your server.

And that’s it for Part 6!

In the last part of this series I’ll show you how to setup your server as a private cloud server, allowing you to sunc important files and documents across all your devices, while ensuring everything is backed up for good measure!

Leave a Reply