[GUIDE] Install SABnzbd 0.7.12

Most of this post is taken from http://community.wdc.com/t5/Netzwerk-Laufwerke/Guide-SABnzbd-und-sickbeard-auf-My-Book-Live/m-p/483818/highlight/true#M1175

All credit goes to Shackles for the original post with minor modifications by me

 

Users looking to upgrade to 0.7.12 please see this post

http://community.wd.com/t5/My-Book-Live/GUIDE-Install-SABnzbd-0-7-12/m-p/572529/highlight/true#M22850

Connect to the MBL with PuTTY or Terminal and install optware

wget http://mybookworld.wikidot.com/local--files/optware/setup-mybooklive.sh
sh setup-mybooklive.sh

Issue the following commands to ensure that we can use the command “ipkg” from any directory

echo "export PATH=$PATH:/opt/bin:/opt/sbin" >> /root/.bashrc
echo "export PATH=$PATH:/opt/bin:/opt/sbin" >> /etc/profile

Close PuTTY or Terminal (Very Important)

Open PuTTY or Terminal and connect to the MBL again

ipkg update
ipkg install sabnzbdplus par2cmdline python25 py25-cheetah py25-openssl screen lynx unrar

Download latest SABnzbd http://sourceforge.net/projects/sabnzbdplus/files/sabnzbdplus/0.7.12/SABnzbd-0.7.12-src.tar.gz/download

Extract the SABnzbd-0.7.12 folder inside the tar.gz file with 7-zip 9.20
Start WinSCP
In the right panel, navigate to /opt/share/SABnzbd
In the left panel, navigate to SABnzbd-0.7.12 and highlight all the extracted files in the left panel and drag them to the right panel
Overwrite all files when prompted
Close WinSCP

Start SABnzbd so that it creates sabnzbd.ini

/opt/bin/python2.5 /opt/share/SABnzbd/SABnzbd.py -f /opt/share/SABnzbd/sabnzbd.ini -d

 Edit sabnzbd.ini

nano /opt/share/SABnzbd/sabnzbd.ini

Find host = localhost
and change it to
host = 0.0.0.0
Hit control and o
Hit enter
Hit control and x

This will save the edited file and close nano

Create SabNZB auto start file

nano /etc/init.d/sabnzbd

Paste this text into the empty nano window (right click)

#!/bin/sh

	case "$1" in
	start)
	  # help sabnzbd to find par2, unrar etc.
	  PATH=$PATH:/opt/bin:/opt/sbin
	  echo "Starting SABnzbd."
	  /opt/bin/python2.5 /opt/share/SABnzbd/SABnzbd.py -f /opt/share/SABnzbd/sabnzbd.ini -d
	;;
	stop)
	  echo "Shutting down SABnzbd."
	  /usr/bin/wget -q --delete-after "http://0.0.0.0:8080/sabnzbd/api?mode=shutdown&apikey=ENTERAPIKEYHERE"
	;;
	*)
	  echo "Usage: $0 {start|stop}"
	  exit 1
	esac

	exit 0

Hit control and o
Hit enter
Hit control and x
This will save the new file and close nano

Change permission on the sabnzbd folder, add sabnzbd to startup and reboot the MBL

chmod 755 /etc/init.d/sabnzbd
update-rc.d sabnzbd defaults

Now we want to start SabNZB

/etc/init.d/sabnzbd start

Now let’s get our API Key and fix the sabnzbd script

Login to the SABnzbd dashboard from a browser yourmybookliveip:8080

Click on Config and General and on the right side of the screen look for your API Key

Copy the key to your clipboard

Now let’s edit sabnzbd

nano /etc/init.d/sabnzbd

Look for the text that says ENTERAPIKEYHERE and delete just that text and right click to paste your API key

The line should look similar to this after you paste your API Key

/usr/bin/wget -q --delete-after "http://0.0.0.0:8080/sabnzbd/api?mode=shutdown&apikey=a6ebdd7158c2d5eg9e0ac91ad3ad5114"

Hit control and o
Hit enter
Hit control and x
This will save the new file and close nano

Now we can stop the server from SSH if needed

#Create a share from the MyBookLive dashboard for your SABnzb downloads

#To login to the SABnzbd dashboard from a browser yourmybookliveip:8080
#Setup your usenet server information
#Go to Folders
#Temporary Download Folder - /DataVolume/shares/ share you just created for downloads
#Completed Download Folder - /DataVolume/shares/ share you just created for downloads
#Permissions for completed downloads 775
#Save changes
#Finish setting up SabNZB (RSS Feeds) etc

#Done

6 Likes

Thanks for sharing.

Guide updated to use Python 2.5 to get a nice speed boost :slight_smile:
Using Python 2.6 I was pulling down 2MB/sec on my 30Mb connection
Using Python 2.5 I am pulling down 3MB/sec on my 30Mb connection

Python 2.5 includes yenc 0.3-1 which takes some load off the CPU in the MBL while decoding yenc binaries

It is my understanding that you would need to compile yenc 0.3-1 for Python 2.6 and I haven’t gotten that far yet :stuck_out_tongue:

2 Likes

this is excellent. extremely helpful. i have sabnzbd running and downloading but once the files are completed, how do i get access to them through the media share? can i set the “complete” folder to be accessed from the media share?

You created a share for the SABnzb downloads from the MBL dashboard first right? Otherwise you may run into issues as SABnzb will create the share for you which is bad as it wouldn’t be visible from the network. I just updated the guide to reflect this step in case that was your issue. If you didn’t do this, you need to create a share from the MBL dashboard and point SABnzb to this share.

If the above does not apply…

It is possibly a permissions issue on your folder. I’m not sure if you’re on Mac or Windows, but the easiest way to fix this in Windows would be using WinSCP

Browse to /DataVolume/shares and then browse inside the share you are using for SABnzb downloads

Right click your “complete” folder and select properties. Change group to share and owner to root and the Octal to 775 and click OK and see it you can access it now.


Here’s how I did it

I first created a share from MBL dashboard for the SABnzb downloads called Downloads
Then from the SABnzb control panel I went to the Folders option
Temporary Download Folder
/DataVolume/shares/Downloads/incomplete
Completed Download Folder
/DataVolume/shares/Downloads
Permissions for completed downloads
775
Hit save

This in turn created a folder called incomplete in my MBL Downloads share where all the files are decoded and processed
Once the files are repaired and processed, they are moved to the Downloads share in a folder based on the nzb name or the RSS feed title name

Thanks!!

Hi nfodiz, Just wondering if you have installed sickbeard like Shackles has in his guide? I have absolutely No german knolledge and chrome translate isn’t working for some reason.

As a side note, If sabnzb and sickbeard are able to be installed on these, what about couchpotato, headphones and lazy librarian?

EDIT- all of these programs run on python so I don’t see why not… I wish I knew more about how to use a linux terminal cause I’m sure it would be possible :cry:

Couchpotato and Headphones should be easy, I will look into it. I have never heard of lazy librarian but I will check it out.

Hi, I was wondering do I need the Windows or Linux version of Sabnzbd, an update came out I wanted to make sure I have the latest.

How to manually update from 0.7.11 to 0.7.12 if you followed the old guide

Also let’s fix the sabnzbd script while we’re at it so we can shut down the server from SSH

 

Let’s get our API Key and fix the sabnzbd script first

Login to the SABnzbd dashboard from a browser yourmybookliveip:8080

Click on Config and General and on the right side of the screen look for your API Key

Copy the key to your clipboard

Now let’s edit sabnzbd

nano /etc/init.d/sabnzbd

Look for the text that says ENTERAPIKEYHERE and delete just that text and right click to paste your API key

The line should look similar to this after you paste your API Key

/usr/bin/wget -q --delete-after "http://0.0.0.0:8080/sabnzbd/api?mode=shutdown&apikey=a6ebdd7158c2d5eg9e0ac91ad3ad5114"

Hit control and o
Hit enter
Hit control and x
This will save the new file and close nano

Now we can stop the server from SSH by typing

/etc/init.d/sabnzbd stop

Download latest SABnzbd

http://sourceforge.net/projects/sabnzbdplus/files/sabnzbdplus/0.7.12/SABnzbd-0.7.12-src.tar.gz/download
Extract the SABnzbd-0.7.12 folder with 7-zip 9.20
Start WinSCP
In the right panel, navigate to /opt/share/SABnzbd
In the left panel, navigate to SABnzbd-0.7.12 and highlight all the extracted files in the left panel and drag them to the right panel
Overwrite all files when prompted
Close WinSCP

Restart SabNZB from PuTTY

/etc/init.d/sabnzbd restart

Guide updated for SABnzb 0.7.12

Also added instructions to properly fix your sabnzbd file so that it will shut down the server when you issue

/etc/init.d/sabnzbd stop

 This can come in handy when we want to update the server as I recommend you stop the server first

Real nice guide but I have a problem with starting SABnzbd. Can you help me?

I just started SAB on the NAS and I want to log in with the following command:

http://192.168.1.146:8080/

But then I get an error that I cant make a connection, what must I do?

When you start SAB in PuTTY by typing

/etc/init.d/sabnzbd start

What does it say?

Been having troubles with SABNzb lately. It will run for about 2-3days no worries and then the whole MBL just stops. I think it is a memory issue. Its using a lot of memory, granted I generally have ~180 NZBs queued, but it just crashes the whole system and won’t even work after a reboot. I can use everything else on the MBL (very slowly) but cannot access SABNzb. I have checked with top, it is still running, using 555Mb of virtual ram and 108Mb of ram but I cannot access it. It has done this to me 3 times now, each time I have just started from scratch, again by doing the debrick. Is there a way to make the swap area larger? Or is there a way I can get rid of everything on this MBL and only have it running SABNzb and nothing else, not even the dashboard? Like a custom firmware or something… I wish to have this drive dedicated to SABNzb and no other capabilities. Maybe transmission too but that would be it.

180 nzbs at a time, wowsers! I never have but maybe 2 or 3 at a time in the q and have had uptimes of weeks if not months without issue. I think your pushing this little box to the limit lol. It’s possible to free up a little memory by getting rid of some stuff but I still think you would run into issues. You can try making a swapfile on the datapartition and see if that helps as there is no way to make the swap partition any bigger than it already is.

This should give you like 1.5 gigs of swap as it seems to use the swap partition and the swap file

dd if=/dev/zero of=/DataVolume/swapfile bs=1M count=1024
mkswap /DataVolume/swapfile
swapon /DataVolume/swapfile

 To remove the swapfile

swapoff /DataVolume/swapfile
rm -f /DataVolume/swapfile

 Let me know if it helps any  hehe

yeah sickbeard is trying to catchup with my tv shows lol. Thanks heaps just did that, see how it goes. i have been told that swap files are very slow, but as long as i can still actually use sab, speed is not really an issue for me as i don’t sit there and wait anyway, being all automated.

Yeah it can be slow but who knows it may help out in your case. Keep me posted as I’m very curious :slight_smile:

Off to bed for the night, take care lilmick

you took the 1 off swapfile1… does that make a difference?

Nope I just figured swapfile was cleaner looking. To remove it though make sure to add the 1 in there