Tutorial on Install Deluge Torrent on Ubuntu Server 18.04

deluge torrent

Must read:

Ferdian Alfianto

Ferdian Alfianto

Ferdian Alfianto is an Internet enthusiast, Mac Lover; likes using Wordpress, experimenting with Linux (especially Debian and Ubuntu), tinkering with pfSense routers, happy experimenting with LEMP (Linux, Nginx, MariaDB, PHP) and Redis. You can contact me here.

This article will explain the tutorial to install Deluge Torrent on Ubuntu Server 18.04. What is Deluge Torrent? Deluge Torrent is a software BitTorrent lightweight, free and open source (GPL3); which is available for Linux, FreeBSD, Mac OS X and Windows.
Deluge has a variety plugins which can be installed to provide additional features. For example, we can install a plugin to stream videos, so that we can watch videos online while Deluge is downloading them.

Why do you need to install Deluge on an Ubuntu server? To download torrent files, you can use the BitTorrent client, install directly on a PC or laptop, run & download. However, direct downloading of torrent files has drawbacks, namely, the download speed is relatively slow, we are also required to share an Internet connection so that other people can download the same file and may face legal entities, because torrent activity itself is actually still illegal; not to mention the files we download are also mostly illegal files! :)
Now, using Deluge, torrent files will be downloaded to the server. We rent this server from a lease from a VPS service provider. Once on the server, then we can download the file at maximum speed, without having to share bandwidth, and relatively safer!

Installation Process

Make sure you have rented a VPS or Cloud server at your favorite hosting service provider. Here I use a service from Hetzner, at a cost of 2.49 Euros per month I have got a cloud server with a spec of 1 CPU, 2 GB RAM, 20 GB Storage Capacity and 20 TB of bandwidth, enough for Deluge Torrent needs. Don't forget to install Ubuntu server 18.04 on that VPS / Cloud server.

Then log into the server, and type the following command:

sudo add-apt-repository ppa: deluge-team / ppa


sudo apt install deluged deluge-webui

After that we will create user and group deluge so that Deluge can be run without having to use an administrator, thus increasing server security.

sudo adduser --system --group deluge

Use flag --system means that we will create system users, not ordinary users. System users have no passwords and cannot log in, perfect for Deluge requirements. Directory / home / deluge will be created for this user. The files that are downloaded by default are placed in the folder / home / deluge / Downloads.

sudo gpasswd -a username-your deluge

Next we create a file systemd service for deluge, run the command:

sudo nano /etc/systemd/system/deluged.service

Copy and paste the following lines into the file.

[Unit] Description=Deluge Bittorrent Client Daemon After=network-online.target [Service] Type=simple User=deluge Group=deluge UMask=007 ExecStart=/usr/bin/deluged -d Restart=on-failure TimeoutStopSec=300 [ Install] WantedBy=multi-user.target 

Save the above configuration by exiting the text editor with the command Ctrl + O, and enter for confirmation. Then run deluge daemon with the command:

systemctl start deluged
deluge status

Access WebUI Deluge Torrent

In order to access the web interface, we need to create a file systemd service for web deluge.

sudo nano /etc/systemd/system/deluge-web.service

Copy and paste the following text into the file

[Unit] Description=Deluge Bittorrent Client Web Interface After=network-online.target [Service] Type=simple User=deluge Group=deluge UMask=027 ExecStart=/usr/bin/deluge-web Restart=on-failure [Install] WantedBy=multi-user.target

Save and then close the text editor, as before. Then we run and activate it deluge-web, and check the status.

systemctl start deluge-web
systemctl enable deluge-web
systemctl deluge-web status
web deluge status

Now open a browser, and access your server with the format:


You will be asked for a password to log in, the default password is deluge.

web deluge login

You will be offered to change the default password, select "Yes". Before changing the password, the Connection Manager window will appear. Click host, then click "Start Daemon", and click "Connect".

To change the default password, in the window Preferences, click a category Interface, and on the column Password, enter the default password in "Old Password", and enter the new password in "New Password", and confirm the new password in "Confirm Password".

change password deluge

Deluge Torrent installation is complete, now you can use it to download torrent files.

How to Download Torrent Files with Deluge Torrent

Find the torrent file that you want to download first. You can download torrent files from the magnetic link, or from torrent files with extensions .torrent. As an example here I will download from a magnet link.

Copy the magnet link that we want to download, then on the Deluge Torrent interface, select the "Add" menu (it's in the upper left corner). Then the Add Torrents window will appear, click the “Url” menu if using a magnet link, select “File” if using a .torrent file. Paste the magnet link that we previously copied, and select Add. (see image below).

how to download torrent

After clicking "Add", a torrent information window will appear that you want to download, once again click "Add".

added torrent

And the torrent download process will run as shown below.

torrent download process

To download torrent files to your computer, use FTP software, and connect to the Deluge Torrent server with SSH protocol, and navigate to the folder / home / deluge / Downloads.

Using a Domain / Subdomain on a Deluge Torrent

In order to easily remember the address to access the Deluge Torrent server, we can point a domain / subdomain. Prepare a domain / subdomain that you will use, create an A record in the DNS domain / subdomain, and point it to the Deluge Torrent server IP address that we created earlier.

Next we install nginx with the command

sudo apt install nginx

Run Nginx

sudo systemctl start nginx

Create an Nginx configuration file

sudo nano /etc/nginx/conf.d/deluge-webui.conf

Copy and paste the following configuration. Don't forget to change the red text with your domain / subdoamine name.

server { listen 80; server_name torrent.yourdomain.com; access_log /var/log/nginx/torrent.yourdomain.com.access; error_log /var/log/nginx/torrent.yourdomain.com.error; location / { proxy_pass; } }

Save and close the text editor. We first test the Nginx configuration above with the command:

sudo nginx -t

If there are no errors, reload Nginx with:

sudo systemctl reload nginx

Now you can access the Deluge Torrent server with the domain / subdomain address.

For server security, we will configure Deluge Torrent so that it only accepts connections from localhost ( For that, we have to change the configuration in the file systemd service.

sudo nano /etc/systemd/system/deluge-web.service

Look for the following line:

ExecStart = / usr / bin / deluge-web

Change to:

ExecStart = / usr / bin / deluge-web -i

Save and close the text editor. Reload systemd daemon with the command:

systemctl daemon-reload

Restart deluge-web:

systemctl restart deluge-web

Check the status with the command:

sudo netstat -lnpt | grep 8112

Install SSL

In order to make the connection from your computer to the Deluge Torrent server more secure, we will install an SSL certificate, so that later when we access it, it will be HTTPS.

Run the following commands one by one (don't forget to replace the red text with your email and domain / subdomain):

sudo apt install software-properties-common
sudo add-apt-repository ppa: certbot / certbot
sudo apt install certbot python3-certbot-nginx
sudo certbot --nginx --redirect --agree-tos --hsts --staple-ocsp --email your email address -d torrent.yourdomain.com 

Now reload the browser, then your connection to the Deluge Torrent server is now HTTPS.


Latest articles:

MongoDB logo

Easy to Install MongoDB on Ubuntu 20.04

This tutorial explains how to install and configure MongoDB Community Edition on Ubuntu 20.04. MongoDB is a free, open-source document database. Belongs to the so-called database family

Related article:

MongoDB logo

Easy to Install MongoDB on Ubuntu 20.04

This tutorial explains how to install and configure MongoDB Community Edition on Ubuntu 20.04. MongoDB is a free, open-source document database. Belongs to the so-called database family


World's First Website

On 6 August 1991, without fanfare, British computer scientist Tim Berners-Lee published his first website while working at CERN, the large particle physics laboratory.