myCLOUD BitTorrent Server

Deluge was started by two members of ubuntuforums.org, Zach Tibbitts and Alon Zakai, who previously hosted and maintained the project at READ MORE...

Add-on APP to myCLOUD

  • This tutorial is to build BitTorrent upon the Raspberry Pi 4 already running myCLOUD services.
  • SOFTWARE - Deluge is a lightweight, Free Software, cross-platform BitTorrent client.
  • OPERATING SYSTEM - Raspberry Pi OS with desktop.
  • RASPBERRY PI - Raspberry Pi motherboard model 4B 2GB. But you can use Raspberry Pi models 4B 4GB/8GB, 3A+, 3B, 3B+ instead.
  • Wi-Fi 6 MESH ROUTER - You need two units of M18 to form a back haul broadband Internet access
shipping coupon insurance

Deluge BitTorrent

Deluge was started by two members of ubuntuforums.org, Zach Tibbitts and Alon Zakai, who previously hosted and maintained the project at Google Code, but who subsequently moved it to its own website.

Deluge is released under the terms of the GNU General Public License version 3.

Running a BitTorrent server on the Raspberry Pi is a good way to offload work from your main workstation, saving precious resources, such as processing power, memory, bandwidth and even electricity.

You may thus have it always-on without interruption.

This tutorial provides step-by-step instructions for configuring a Deluge BitTorrent server on the Raspberry Pi 4 2GB motherboard.

What is BitTorrent?

BitTorrent (abbreviated to BT) is a communication protocol for peer-to-peer file sharing (P2P), which enables users to distribute data and electronic files over the Internet in a decentralized manner.

BitTorrent is one of the most common protocols for transferring large files; such as, digital video files containing TV shows and video clips, or digital audio files containing songs.

In 2019, BitTorrent was a dominant file sharing protocol and generated a substantial amount of Internet traffic, with 2.46% of downstream, and 27.58% of upstream traffic.

Power up and get your Raspberry Pi online

Click on the wireless icon then choose the WiFi network name and enter the its secured password.

sudo apt update

sudo apt upgrade

That should be enough for the Raspberry Pi preparation.

sudo fdisk -l

you would expect to see /dev/sda1 at the bottom of the command response.

sudo apt install deluged deluge-web

Create a new service to run the Deluge daemon automatically after system start and once a network connection has been established. Use the “deluged-user” user that was created automatically during the initial installation of the Deluge daemon

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

[Unit]
Description=Deluge Daemon
After=network-online.target

[Service]
Type=simple
User=deluged-user
Group=deluged-user
UMask=002
ExecStart=/usr/bin/deluged -d
Restart=on-failure
TimeoutStopSec=300

[Install]
WantedBy=multi-user.target

Press “CTRL+X” to exit, “Y” to save changes, and “Enter” to confirm the filename.

sudo systemctl enable deluged.service

Create a new service to run the Deluge web interface automatically after system start, and once a network connection has been established. Use the “deluged-user” user that was created automatically during the initial installation of the Deluge daemon.

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

[Unit]
Description=Deluge Web Interface
After=network-online.target deluged.service
Wants=deluged.service

[Service]
Type=simple
User=deluged-user
Group=deluged-user
UMask=002
ExecStart=/usr/bin/deluge-web
Restart=on-failure

[Install]
WantedBy=multi-user.target

Press “CTRL+X” to exit, “Y” to save changes, and “Enter” to confirm the filename.

sudo systemctl enable deluge-web.service

Configuration and Permissions

The first time Deluge runs, it generates its default configuration files in the users home directory. Our user, “deluged-user” has a home directory at “/var/lib/deluged.” We will start our new system services, which will have “deluged-user” run Deluge for us.

sudo systemctl start deluged
sudo systemctl start deluge-web

Optionally, you can check the status of these services now to double-check that they are working. If they are working or not, it will be indicated by some highlighted green or red text, respectively.

sudo systemctl status deluged
sudo systemctl status deluge-web

Now, lets stop the services and Deluge components from running so we can make some needed changes.

sudo systemctl stop deluged
sudo systemctl stop deluge-web

sudo usermod -aG deluged-user pi

sudo chown -R deluged-user:deluged-user /var/lib/deluge

sudo chmod -R 770 /var/lib/deluge

sudo reboot

Configure the Web Interface

sudo systemctl status deluged
sudo systemctl status deluge-web

hostname -I

Navigate to the Deluge web interface from your main workstation (a computer other than the Raspberry Pi).

http://IPADDRESS:8112

You should be presented with a login prompt. The default password is “deluge.” Change this password to one of your liking. You may also be presented with a prompt from the “Connection Manager.” Here you will want to connect to the host with an address of “127.0.0.1” which is your local machine. This connects the web interface to the Deluge daemon which does all the heavy lifting in the background.

From here you can change any number of settings through the web interface, by selecting the “Preferences” menu. I would highly recommend changing the download folder locations, as well as allowing remote access.

Any folder that you choose to download to, or setup as one of your various download locations for torrents, you must grant permissions to the “deluged-user” group to function, or you’ll encounter errors.

sudo mkdir /myCLOUD/shared/tt
sudo chown deluged-user:deluged-user /myCLOUD/shared/tt
sudo chmod 770 /myCLOUD/shared/tt

sudo systemctl stop deluged
sudo systemctl stop deluge-web

sudo systemctl stop deluged
sudo systemctl stop deluge-web

Packing List

myCLOUD NAS DIY Kit ↺ GO BACK
  • 1 x USB3.0 Dual Harddisk Docking Station (See Note*)
  • 1 x Aluminum Case Enclosure = Heat Sink
  • 1 x USB WiFi dongle
  • 1 x 5dBi Omni Antenna
  • 1 x micro htmi to hdmi 6 FT cable
  • 1 x 5V 3.5A Power Supply Module
  • 1 x myCLOUD NAS installer
  • 1 x User guide

M18 MESH Router ↺ GO BACK
  • Compliant to IEEE 802.11ax International Standard
  • 3 WAN/LAN Gigabit Ethernet Ports
  • Power supply unit
  • 中文 menu supplemented with English user guide

Note* : Two drive slots - harddisk not included. You may fit a 3.5in SATA or 2.5in SATA on each slot. Max 16TB each drive. Total max storage capacity 32TB. The Harddisk Docking Station also comes with CLONE feature. Simply insert the master harddisk in the SOURCE slot and the slave harddisk in the TARGET slot, then press the CLONE button to clone.


:: Copyright ® 2020 DataCom Network Limited
The registered trademarks and logos belong to the respective companies.
:: Copyright ® 2021 DataCom Network Limited. The registered trademarks and logos belong to the respective companies.