Headline News
GoPro Returns with New Range (September 26, 2016 7:31 pm)
TRAILER: Doctor Strange (April 13, 2016 8:23 am)
TRAILER: Dawn of Justice Trailer 2 (December 3, 2015 6:25 pm)
Luther Season 4 Returns to the BBC (December 2, 2015 9:13 pm)
Sherlock Special (December 2, 2015 9:01 pm)

Arch Linux: Command Line Browsing And Fetching Torrents

April 9, 2014
664 Views

In this guide I will show you how to set up the Transmission command-line client on Arch Linux and then install and configure Links, a command-line browser so we can fetch torrents when connected to our machine via ssh.

First we will install Transmission.

pacman -S transmission-cli transmission-remote-cli

Now we will start the Transmission daemon and set it to run at boot.

systemctl start transmission
systemctl enable transmission

Now Transmission has been started, the config files will have been created. To edit the config files, we need to stop transmission again.

systemctl stop transmission

Now we can edit the config file in /var/lib/transmission/.config/transmission-daemon/settings.json. I have a memory stick connected to my Raspberry Pi to store torrents on, this is mounted at /media/storage. You should create one folder for completed files and another for incomplete files. The config file is quite long so here are the main lines you need to change. The Transmission daemon must be stopped while we edit this file or the settings will not stick.

vi /var/lib/transmission/.config/transmission-daemon/settings.json

"download-dir": "/media/storage/torrents", 
"incomplete-dir": "/media/storage/torrents/incomplete", 
"incomplete-dir-enabled": true, 

Save the file and start the Transmission daemon.

systemctl start transmission

We can now connect to the Transmission daemon.

trasmission-remote-cli

Unless you know the exact URI of any torrents and feel like typing them in manually, this won’t be of much help. Press q to quit and go back to the command line.

Now we will install Links, a browser we can use from the command line to fetch our torrents.

pacman -S links

Now run links.

links

Before we try to get any torrents, we need to configure Links to handle magnet links and send them to Transmission. With Links open (it will look like a blank page at startup), press Esc, go to the Setup menu, and down to Mail and Telnet. In the Mail and Telnet menu, under “Magnet program”, enter the following, then select OK.

transmission-remote -a %

We now need to save these settings before we close Links or they will not stick. Press Esc and go to the Setup menu, then Save Options. Now you can press g to go to a URL. You use the up and down arrows to navigate the page, and the left and right arrows to go back and forward. When you find a magnet link that you want to download, select it and press enter. The screen will flash, this means the torrent has been sent to transmission. You can now quit Links with q and open up Transmission again to see the progress of your torrent.