Install Bitcannon on Ubuntu 15.x

bitcannon logoStephen304 has created BitCannon which gives you your own personal torrent archive site. It backs up KAT and demonoid locally in a database for your convenience. You can search the database, download torrent files just like on KickAssTorrents but from your own machine. The idea is that even if torrent sites continue to be attacked, it will be easy for users to continue using the torrent database even if the main site is down. BitCannon comes in 32 and 64 bit versions and can autoupdate its database with an hourly torrent database dump. I also show you how to import the entire KickAssTorrents archive. This guide is for Ubuntu. Do torrent safely with a VPN service like Private Internet Access or PureVPN.

VPN Service
All Platforms
Number of Connections
Monthly Cost
Annual Cost
Private Internet Access
Yes
5
$6.95
$39.95
($3.33 / month)
Pure VPN
Yes
5
$10.95
$59.95
($4.91 / month)
IPVanish
Yes
5
$10.00
$77.00
($6.41 / month)

Install Bitcannon on Ubuntu 15.x

You need a few simple components for your personal KickAssTorrents backup

  • Mongo Database to store the torrent files you import
  • BitCannon which imports the torrent database and gives you a web interface to search for torrents
  • A dump of KickAssTorrents if you want the entire database (around 600 MB in size) which requires an API key

Install Mongo Database

On Ubuntu it is very easy to install MongoDB

sudo apt-get install mongodb -y

Install BitCannon

Download BitCannon, the latest release from Stephen304's page

You will be taken to a Mega page, click the BC_Linux version e.g. BC_Linux_v0.1.1.zip.

Click the Download arrow at the top and choose Download as ZIP – this prevents a ‘This file may harm your computer' error which I got in Google Chrome.

bitcannon megaupload linux

Transfer the zip file to any folder on your Ubuntu device using SFTP with a client like WinSCP

Back in SSH or local terminal session navigate to where the zip file is stored and install unzip

sudo apt-get install unzip -y

Unzip the Bitcannon package

unzip BC_Linux*

Move it to an appropriate install directory

sudo mv bitcannon /opt/bitcannon

Change the ownership of the directory so it doesn't run as root, adjust user to your Ubuntu username

sudo chown -R user:user /opt/bitcannon

Open the BitCannon configuration file

nano /opt/bitcannon/config.json

If you have an API key for KAT you can insert your API key in place of $USERHASH

{
  "mongo": "127.0.0.1",
  "bitcannonPort": "1337",
  "scrapeEnabled": true,
  "scrapeDelay": 0,
  "trackers": [
    "udp://open.demonii.com:1337",
    "udp://tracker.istole.it:80",
    "udp://tracker.openbittorrent.com:80",
    "udp://tracker.publicbt.com:80",
    "udp://tracker.coppersurfer.tk:6969",
    "udp://tracker.leechers-paradise.org:6969",
    "udp://exodus.desync.com:6969"
  ],
  "archives": [{
    "name": "KickAssTorrents",
    "url": "https://kat.cr/api/get_dump/hourly/?userhash=$USERHASH&verified=1",
    "frequency": 3600
  }, {
    "name": "Demonoid",
    "url": "http://www.demonoid.pw/api/demonoid24h.txt.gz",
    "frequency": 86400
  }, {
    "name": "BitSnoop",
    "url": "http://bitsnoop.com/api/latest_tz.php?t=all"
  }]
}

Ctrl+X. Y and Enter to save the BitCannon config.json file

Enter the BitCannon folder

cd /opt/bitcannon

Test execution of BitCannon, for 32-bit

./bitcannon_linux_386

For 64-bit users (user the 32-bit if the 64-bit version fails)

./bitcannon_linux_amd64

Now open up a browser and point it to http://ip.address:1337 or http://localhost:1337 if you're on the same machine to which you just installed BitCannon.

You should see this interface and can browse the last hour's torrents from KickAssTorrents. You can now Browse and search your own personal KickAssTorrents backup.

bitcannon install main interface

If you want to import the whole KickAssTorrents database download you will need a KAT API key and then download it into your /opt/bitcannon folder

wget https://kat.cr/api/get_dump/daily/?userhash=$USERHASH&verified=1

Then tell BitCannon to import the dailydump

./bitcannon_linux_386 dailydump.txt.gz

Autostart BitCannon on Ubuntu 15.x

You will need to kill the BitCannon process started before with Ctrl+C or Ctrl+Z

Create the BitCannon systemd service

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

Paste the systemd script, adjust user to your username and bitcannon_linux to either bitcannon_linux_386 (for 32 bit) or bitcannon_linux_amd64 (64-bit)

[Unit]

Description=Bitcannon Daemon
After=network.target

[Service]

User=user
Group=user
Type=forking
ExecStart=/opt/bitcannon/bitcannon_linux
KillMode=process
Restart=on-failure

[Install]

WantedBy=multi-user.target

Enable the BitCannon systemd script and reboot to test

sudo systemctl enable bitcannon.service
sudo service bitcannon start

BitCannon will update from the KickAssTorrents database every hour so it will stay updated.