Install Latest NZBGet on Ubuntu 15.x with Easy Updates

nzbgetNZBGet has grown in popularity due its low memory footprint and considerable power. Previously NZBGet had to be built from source and each time a new version was released you had to rebuild NZBGet. Using this method to install NZBGet you will easily be able to update to newer versions without having to rebuild from source. This installation method works on Debian and Ubuntu systems on any CPU architecture (x64, x86 and ARM), I have included a working NZBGet systemd service to work with Debian 8 Jessie and Ubuntu Vivid Vervet and later distros that use systemd.

If you are on Ubuntu 14.x you should use the init.d script from here instead of the systemd script.

Usenet Provider
Backbone
Retention
Speed
Connections
VPN
Monthly
Annual
UsenetServer
UsenetServer
3199
Unlimited
30
Yes
$10
$95.40
Newshosting
Newshosting
3199
Unlimited
30
Yes
$10
$99
Frugal
Frugal
3000
Unlimited
20
No
$4.16
$50
Usenetlink
Cloudgate
2000
100 Mbit
30
No
$15
$140

Install NZBGet on Ubuntu 15.x

Install unrar

Install unrar first

We are going to build the latest unrar from source adapted from these instructions.

Make sure you have building tools

sudo apt-get install build-essential -y

Enter your temporary directory

cd /tmp

Download the latest unrar source tarball

wget rarlab.com/rar/unrarsrc-5.2.7.tar.gz

Unpack the unrar source

tar -xvf unrarsrc-5.2.7.tar.gz

Enter the unrar source

cd unrar

Get the number of processors for compiling faster

nproc

I have 2 so when building I add 2 after -j

make -j2 -f makefile

Now install unrar

sudo install -v -m755 unrar /usr/bin

Cleanup your unrar source and unpacked directory

cd ..
rm -R unrar
rm unrarsrc-5.2.7.tar.gz

Install NZBGet Latest Ubuntu

Download the latest stable NZBGet installer by copying and pasting all 3 lines.

wget -O - http://nzbget.net/info/nzbget-version-linux.json | \
  sed -n "s/^.*stable-download.*: \"\(.*\)\".*/\1/p" | \
  wget --no-check-certificate -i - -O nzbget-latest-bin-linux.run

Install NZBGet on Ubuntu 15.x

sudo sh nzbget-latest-bin-linux.run --destdir /opt/nzbget

Remove the installer

rm nzbget-latest-bin-linux.run

Change ownership of the NZBGet installation to your user

sudo chown -R username:username /opt/nzbget

Update your NZBGet configuration file to run as  your user

sed -i "/DaemonUsername=/c\DaemonUsername=username" /opt/nzbget/nzbget.conf

Create the NZBGet systemd service, if you are on Ubuntu 14.x use the init.d script section from here

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

Paste the working NZBGet systemd script for Ubuntu

[Unit]
Description=NZBGet Daemon
Documentation=http://nzbget.net/Documentation
After=network.target

[Service]
User=username
Group=username
Type=forking
ExecStart=/opt/nzbget/nzbget -c /opt/nzbget/nzbget.conf -D
ExecStop=/opt/nzbget/nzbget -Q
ExecReload=/opt/nzbget/nzbget -O
KillMode=process
Restart=on-failure

[Install]
WantedBy=multi-user.target

If you notice your hard drive is being mounted after NZBGet is autostarted then add this line in the Unit section

Replace /mnt/usbstorage with the path to your mount point which should fix the problem where NZBGet isn't starting because the hard drive isn't mounted yet

[Unit]
Description=NZBGet Daemon
Documentation=http://nzbget.net/Documentation
After=network.target
RequiresMountsFor=/mnt/usbstorage

Enable the NZBGet systemd service

systemctl enable nzbget.service

Start the NZBGet systemd service for Ubuntu

sudo service nzbget start

Now you can access NZBGet on Ubuntu on port 6789, the default username is nzbget and password is tegbzn6789

When NZBGet updates are released you can now upgrade from the NZBGet web interface.

Now you can configure NZBGet and use some of its useful scripts like FakeDetector and FailureLink.

You can also use NZBGet with SickRage, CouchPotato, Sonarr and Mylar.