This is the old XigmaNAS forum in read only mode,
it will taken offline by the end of march 2021!



I like to aks Users and Admins to rewrite/take over important post from here into the new fresh main forum!
Its not possible for us to export from here and import it to the main forum!

[HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Jails with XigmaNAS
Forum rules
Set-Up GuideFAQsForum Rules
Post Reply
jasch
experienced User
experienced User
Posts: 136
Joined: 25 Jun 2012 10:25
Location: Germany
Status: Offline

[HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by jasch »

Attention Updated for Nas4free 9.3
fixed some typos
changes pkg_add to pkg install

This Howto is intended to show, how to install and Update Sabnzbd inside a Jail.
First of all a big Thx to alexey123 for his Help, and for all other where i borrowed some sentences.

Prerequisites:

You need to have a fully working jail , to do it , please read the excelent Wiki article: "http://wiki.nas4free.org/doku.php?id=do ... owto:jails"

or use fsbruva excelent TheBrig jail manager: viewtopic.php?f=79&t=3894

and create a Jail, i call it Sabnzbd (in this Howto i refer to TheBrig created Jails), and stop it.

Before we are going to our Jail u have to create your download Folders on your storage.

I this example i create a main Folder Download.(my Storage Mount in this example is called Data)
Inside we create 5 Folders.

Backup (optional)
Complete
Conf(i recommend this because so we have our config external and even of N4F new install all is safe)
Incomplete
Scripts(optional)

Code: Select all

mkdir /mnt/Data/Download
mkdir /mnt/Data/Download/Backup
mkdir /mnt/Data/Download/Complete
mkdir /mnt/Data/Download/Conf
mkdir /mnt/Data/Download/Incomplete
mkdir /mnt/Data/Download/Scripts
After we created this Folder we must create a similar Folder in our Jail Mount Dir

Code: Select all

mkdir /mnt/"Path to your Sabnzbdjail"/mnt/Download
Now we need to Mount our Folder inside our Jail over fstab

add

Code: Select all

/mnt/Data/Download /mnt/"Path to your SabnzbdJail/mnt/Download nullfs rw 0 0
to your Jail config under fstab and start your jail.

Now its time to go to our Jail.

Code: Select all

 jexec "Sabnzbd JID" csh
root@Sabnzbd:/ #  
First of all we need to install some Packages we need for Sabnzbd

Code: Select all

pkg install python27 py27-sqlite3 unzip py27-yenc py27-cheetah py27-openssl py27-feedparser py27-utils unrar par2cmdline
Now we install SAbnzbd ( i recommed going to sabnzbd soundforge site and check for newest version and copy link from there)

Code: Select all

cd tmp
fetch "http://sourceforge.net/projects/sabnzbdplus/files/sabnzbdplus/0.7.16/SABnzbd-0.7.20-src.tar.gz"
tar -xzf SABnzbd-0.7.20-src.tar.gz
rm SABnzbd-0.7.20-src.tar.gz
mv SABnzbd-0.7.20 Sabnzbd
mv Sabnzbd /usr/local/share/
Now we need to change /usr/local/share/Sabnzbd/SABnzbd.py

Code: Select all

ee  /usr/local/share/Sabnzbd/SABnzbd.py
and on the first line, change #!/usr/bin/python to #!/usr/local/bin/python2.7

Attention, at the moment there is a bug(or feature) with phython 2.79 and untrusted ssl certificates.

add this to SABnzbd.py to sort it out until a better way is found(Sabnzb 8 will have it).
(u can also disbale it globally but this would be an security risk)

Code: Select all

opt_out_of_certificate_verification = True
if opt_out_of_certificate_verification:
    try:
        import ssl
        ssl._create_default_https_context = ssl._create_unverified_context
    except:
        pass


Now we create Sabnzbd start stop script.

Code: Select all

touch /etc/rc.d/sabnzbd
ee /etc/rc.d/sabnzbd
and paste this in

Code: Select all

  #!/bin/sh
    #
    # PROVIDE: sabnzbd
    # REQUIRE: NETWORKING DAEMON
    # KEYWORD: shutdown
    #
    # Add the following lines to /etc/rc.conf.local or /etc/rc.conf
    # to enable this service:
    #
    #sabnzbd_enable="YES"
    #
    # It is recommended not to run SABnzbd as root. Add the following
    # lines to /etc/rc.conf.local or /etc/rc.conf to run the daemon
    # with the credentials of user 'john'
    # user 'john'

    sabnzbd_enable=${sabnzbd_enable-"NO"}
    sabnzbd_user=root
    sabnzbd_PATH="/usr/local/share/Sabnzbd/SABnzbd.py"
    sabnzbd_conf="/mnt/Download/Conf/sabnzbd.ini"
    sabnzbd_IP=""
    sabnzbd_PORT="8085"
    #sabnzbd_pass=""
    #sabnzbd_APIKEY=""

    . /etc/rc.subr

    name=sabnzbd
    rcvar=`set_rcvar`

    start_cmd=sabnzbd_start
    stop_cmd=sabnzbd_stop

    sabnzbd_start() {
        PATH=$PATH:/usr/local/bin:/usr/local/sbin; export PATH
        checkyesno sabnzbd_enable && su ${sabnzbd_user} -c "$sabnzbd_PATH --daemon -d -f  $sabnzbd_conf" -s $sabnzbd_IP:$sabnzbd_PORT
    }

    sabnzbd_stop() {
        sabnzbd_pid=`ps -U ${sabnzbd_user} | grep "python.*SABnzbd.py.*--daemon" | grep -v 'grep' | awk '{print $1}'`
        checkyesno sabnzbd_enable && if [ -n "${sabnzbd_pid}" ]; then kill ${sabnzbd_pid}; fi
    }

    load_rc_config ${name}
    run_rc_command "$1"

You need to change
sabnzbd_conf="/mnt/Data/Download/Conf/sabnzbd.ini"
sabnzbd_PORT="8085"
to your needs(the Rest of the Parametes is not needed)
save it.

We need to make executable

Code: Select all

chmod 755 /etc/rc.d/sabnzbd
Add the following lines to /etc/rc.conf

Code: Select all

    
sabnzbd_enable="YES"


This autostarts Sabnzbd with Jailstart

Now we should be able to start and stop Sabnzbd

Code: Select all

/etc/rc.d/sabnzbd start
SAbnzbd should now be reachable ander "your Jailip:sabnzbd_port"

Code: Select all

/etc/rc.d/sabnzbd stop
to stop SAbnzbd


When u start Sabnzbd first time(after Wizard) you need to assign your Folders under Settings Folders
Temp Download Folder incomplete...
Finished Folder Complete...

I hope this will Help some of you to get it running

Updating Sabnzbd is easy, go inside your Jail stop Sabnzbd and just install new version
(since we made our config file external in conf Folder our settings are all preserved)

Code: Select all

/etc/rc.d/sabnzbd stop
cd tmp
rm -rf /usr/local/share/Sabnzbd 
fetch "http://sourceforge.net/projects/sabnzbdplus/files/sabnzbdplus/new Version"
tar -xzf new Version.tar.gz
rm new Version.tar.gz
mv new Version Sabnzbd
mv Sabnzbd /usr/local/share/
change /usr/local/share/Sabnzbd/SABnzbd.py

Code: Select all

ee  /usr/local/share/Sabnzbd/SABnzbd.py
and on the first line, change #!/usr/bin/python to #!/usr/local/bin/python2.7

Start Sabnzbd

Code: Select all

/etc/rc.d/sabnzbd start
Thats all
Last edited by jasch on 22 Feb 2015 18:31, edited 13 times in total.
XigmaNAS 12.0.0.4 (6625)@PROXMOX 5.V - Supermicro X8DTH-6F | 2x Xeon L5640 | 96GB ECC | LSI 9210-8i|LSI 9500-8e|LSI 9201-16i | 40GBe IB Mellanox |

User avatar
alexey123
Moderator
Moderator
Posts: 1469
Joined: 19 Aug 2012 08:22
Location: Israel, Karmiel
Contact:
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by alexey123 »

I think /etc/rc.d/sabnzbd must be executable
Last edited by alexey123 on 01 Oct 2013 11:30, edited 1 time in total.
Home12.1.0.4 - Ingva (revision 7091)/ x64-embedded on AMD A8-7600 Radeon R7 A88XM-PLUS/ 16G RAM / UPS Ippon Back Power Pro 600
Lab 12.1.0.4 - Ingva (revision 7091) /x64-embedded on Intel(R) Core(TM) i3-3220 CPU @ 3.30GHz / H61M-DS2 / 4G RAM / UPS Ippon Back Power Pro 600

jasch
experienced User
experienced User
Posts: 136
Joined: 25 Jun 2012 10:25
Location: Germany
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by jasch »

you right , done
XigmaNAS 12.0.0.4 (6625)@PROXMOX 5.V - Supermicro X8DTH-6F | 2x Xeon L5640 | 96GB ECC | LSI 9210-8i|LSI 9500-8e|LSI 9201-16i | 40GBe IB Mellanox |

User avatar
rpj
Starter
Starter
Posts: 20
Joined: 26 Jun 2012 16:36
Location: Ile de France, France
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by rpj »

Thanks for your nice guide to install Sabnzbd+ . :D



My system is i386, full install version 9.1.0.1 - Sandstorm (revision 847)

Jail has been created in "The Brig" and named Sabnzbd and do not know which flavor of Freebsd has to choose as there are three choices.I have blindly chosen: FreeBSD-i386-9.1-RELEASE-base.txz & FreeBSD-i386-9.1-RELEASE-src.txz, on the jail creating page of "the brig", without knowing what I do is correct.
Last edited by rpj on 31 Oct 2013 12:05, edited 1 time in total.
11.1.0.2 - Atomics x64-embedded sur AMD Athlon(tm) 64 Processor 3200+ :D

jasch
experienced User
experienced User
Posts: 136
Joined: 25 Jun 2012 10:25
Location: Germany
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by jasch »

Thx
I changed the Foldernames and updated to py27.
For the Jailflavor
x86 u only need RELEASE-base
x64 RELEASE-base and lib32
XigmaNAS 12.0.0.4 (6625)@PROXMOX 5.V - Supermicro X8DTH-6F | 2x Xeon L5640 | 96GB ECC | LSI 9210-8i|LSI 9500-8e|LSI 9201-16i | 40GBe IB Mellanox |

plukkie
NewUser
NewUser
Posts: 2
Joined: 10 Nov 2013 13:01
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by plukkie »

I just installed sabnzbd with no error's only when i tryed to start sabnzbd for the first time from command prompt it says that i have to enable sabnzbd_enable="YES" to start sabnzbd.

so i did it, then it started but i can't surf to the sabnzbd openings page.

how can i find out what could be wrong ?

[solution]
choice a ip adres that you where not using in your network.
i choiced 192.168.1.2, but there was a wifi ap on the same ip adres so that was the problem.
now i changed it in 192.168.1.5 and it run's just great.
Last edited by plukkie on 10 Nov 2013 13:50, edited 1 time in total.

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4865
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by raulfg3 »

if you forget to enable sabnzbd_enable="YES" , perhaps forget other things, revise your steps or do a new install
12.1.0.4 - Ingva (revision 7743) on SUPERMICRO X8SIL-F 8GB of ECC RAM, 11x3TB disk in 1 vdev = Vpool = 32TB Raw size , so 29TB usable size (I Have other NAS as Backup)

Wiki
Last changes

HP T510

plukkie
NewUser
NewUser
Posts: 2
Joined: 10 Nov 2013 13:01
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by plukkie »

Now we need to Mount our Folder inside our Jail over fstab

add

Code: Select all
/mnt/Data/Download /mnt/"Path to your SabnzbdJail/mnt/Download nullfs rw 0 0
how do i alter this, it look like i have somthing wrong.

my datadrive is on /mnt/DataDiskUFS/Download
and my jail is on /mnt/DataDiskUFS/Jail/SABnzbd

should it look like this
/mnt/DataDiskUFS/Download /mnt/DataDiskUFS/Jail/SABnzbd/Download nullfs rw 0 0

or more like
/mnt/DataDiskUFS/Download /mnt/DataDiskUFS/Jail/SABnzbd/mnt/Download nullfs rw 0 0

User avatar
raulfg3
Site Admin
Site Admin
Posts: 4865
Joined: 22 Jun 2012 22:13
Location: Madrid (ESPAÑA)
Contact:
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by raulfg3 »

plukkie wrote:or more like
/mnt/DataDiskUFS/Download /mnt/DataDiskUFS/Jail/SABnzbd/mnt/Download nullfs rw 0 0
like this, but remember that folder Download must exist on /mnt/DataDiskUFS/Jail/SABnzbd/mnt/

so create first prior to mount

Code: Select all

mkdir /mnt/DataDiskUFS/Jail/SABnzbd/mnt/Download 
from outside your jail

or

Code: Select all

mkdir /mnt/Download 
from inside your jail
12.1.0.4 - Ingva (revision 7743) on SUPERMICRO X8SIL-F 8GB of ECC RAM, 11x3TB disk in 1 vdev = Vpool = 32TB Raw size , so 29TB usable size (I Have other NAS as Backup)

Wiki
Last changes

HP T510

Dexter
NewUser
NewUser
Posts: 6
Joined: 04 Aug 2012 22:53
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by Dexter »

After my recent upgrade I couldn't use my old Sabnzbd install so I used your guide to install with the jail + TheBrig. Everything worked flawless but I just can't reach the WebGui for SAB from my computer. It seems the install went flawless, ini files and all are created but thats it. The process is running btw.

EDIT: Port was 8080. Dont know why because I had 8085 in the sabnzbd.ini

laster13
PowerUser
PowerUser
Posts: 995
Joined: 01 Jun 2013 19:15
Location: France-Marseille
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by laster13 »

change #!/usr/bin/python to #!/usr/local/bin/python
Now it's

Code: Select all

change #!/usr/bin/python to #!/usr/local/bin/python2.7

handersen21
NewUser
NewUser
Posts: 1
Joined: 28 May 2014 17:32
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by handersen21 »

Hi

cannot start sabnzbd from the script

runs fine if I start the .py file /usr/local/share/SABnzbd/SABnzbd.py start

I have checked and rechecked and cannot figure where the problem with

Thanks

User avatar
rpj
Starter
Starter
Posts: 20
Joined: 26 Jun 2012 16:36
Location: Ile de France, France
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by rpj »

Thanks to "laster13". I was having hard time after update of SABnzbd it did not start and it retuns saying each time 'command not found'. It is infact I have to make a change #!/usr/bin/python to #!/usr/local/bin/python2.7. And every thing went smooth.
Thanks again Laster 13.
11.1.0.2 - Atomics x64-embedded sur AMD Athlon(tm) 64 Processor 3200+ :D

rhettabutler
NewUser
NewUser
Posts: 4
Joined: 06 Mar 2014 15:32
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by rhettabutler »

I can get this installed in jail, access webgui, configure folders in webgui, autostart with nas, no problems at all.

When I try to install SickBeard it never starts. It will get past vacuum cache.db but then it hangs up afterwards when looking for.
Should I try to not put Sickbeard in extensions folder inside of Jail? Would like to figure out what I am doing wrong...any help appreciated.

NVM...I have it working now. I created wrong folder structure.

solkku
Starter
Starter
Posts: 17
Joined: 31 Jul 2014 19:20
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by solkku »

I tried getting it to work as well, but as Dexter pointed out, the port needed to be 8080 for me too for some reason. I just changed it to 8080 in "/etc/rc.d/sabnzbd" and voila!

The port 8085 (or 8089 as I tested) didn't work, which is weird. I wonder if there's another setting somewhere pointing it to the port 8080 than in "/etc/rc.d/sabnzbd", thus creating a conflict in ports... :roll:
OS: ESXi 6, NAS4Free 10.2.0.2 Embedded as VM
Motherboard: Supermicro X10SLH-F
CPU: Intel Xeon E3-1231v3
RAM: 16GB Kingston DDR3 ECC (2 x 8GB)
Boot Drive: 16GB SanDisk Cruzer Fit Ultra USB 3.0
Storage: 3 x 3TB WD Red (RaidZ-1) for NAS4Free storage, 2 x 120GB Kingston HyperX Fury SSD for VM storage
PSU: CoolerMaster GM Series 450W
Case: Fractal Design Node 804
Other: IBM M1015 SAS card

PnavE_81
NewUser
NewUser
Posts: 3
Joined: 12 Jan 2015 20:32
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by PnavE_81 »

handersen21 wrote:Hi

cannot start sabnzbd from the script

runs fine if I start the .py file /usr/local/share/SABnzbd/SABnzbd.py start

I have checked and rechecked and cannot figure where the problem with

Thanks
same here...
I think I did everything as said in the instruction. I also did this.
change #!/usr/bin/python to #!/usr/local/bin/python2.7

but after:

Code: Select all

/etc/rc.d/sabnzbd start
I get this:

Code: Select all

ps: empty file: Invalid argument
Cannot 'start' sabnzbd. Set sabnzbd_enable to YES in /etc/rc.conf or use 'onestart' instead of 'start'.

laster13
PowerUser
PowerUser
Posts: 995
Joined: 01 Jun 2013 19:15
Location: France-Marseille
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by laster13 »

Hi

Post your /etc/rc.d/sabnzbd

And check your /etc/rc.conf with sabnzbd_enable="YES"

PnavE_81
NewUser
NewUser
Posts: 3
Joined: 12 Jan 2015 20:32
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by PnavE_81 »

Code: Select all

  #!/bin/sh
    
#
    
# PROVIDE: sabnzbd
    
# REQUIRE: NETWORKING DAEMON
    
# KEYWORD: shutdown
    
#
    
# Add the following lines to /etc/rc.conf.local or /etc/rc.conf
    
# to enable this service:
    
#
    
#sabnzbd_enable="YES"
    
#
    
# It is recommended not to run SABnzbd as root. Add the following
    
# lines to /etc/rc.conf.local or /etc/rc.conf to run the daemon
    
# with the credentials of user 'john'
    
# user 'john'

    
sabnzbd_enable=${sabnzbd_enable-"NO"}
    
sabnzbd_user=root
    
sabnzbd_PATH="/usr/local/share/SABnzbd/SABnzbd.py"
    sabnzbd_conf="/mnt/Download/Conf/sabnzbd.ini"
    
sabnzbd_IP=""
    
sabnzbd_PORT="8080"
    
#sabnzbd_pass=""
    
#sabnzbd_APIKEY=""



. /etc/rc.subr

    

name=sabnzbd
    
rcvar=`set_rcvar`

    

start_cmd=sabnzbd_start
    
stop_cmd=sabnzbd_stop

    

sabnzbd_start() {
        
	PATH=$PATH:/usr/local/bin:/usr/local/sbin; export PATH

        checkyesno sabnzbd_enable && su ${sabnzbd_user} -c "$sabnzbd_PATH --daemon -d -f  $sabnzbd_conf" -s $sabnzbd_IP:$sabnzbd_PORT
    
}

    

sabnzbd_stop() {

        sabnzbd_pid=`ps -U ${sabnzbd_user} | grep "python.*SABnzbd.py.*--daemon" | grep -v 'grep' | awk '{print $1}'`

        checkyesno sabnzbd_enable && if [ -n "${sabnzbd_pid}" ]; then kill ${sabnzbd_pid}; fi
    }

    
load_rc_config ${name}
    
run_rc_command "$1"

I copied it from this thread and only changed the port number like others said

laster13
PowerUser
PowerUser
Posts: 995
Joined: 01 Jun 2013 19:15
Location: France-Marseille
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by laster13 »

I wrote a howto for french community. It works

viewtopic.php?f=94&t=6885

Try it

PnavE_81
NewUser
NewUser
Posts: 3
Joined: 12 Jan 2015 20:32
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by PnavE_81 »

thanks...I got Sabnzbd and sickbeard running now
now it's time to do some configuration

antking3806
NewUser
NewUser
Posts: 7
Joined: 26 Jan 2015 15:29
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail

Post by antking3806 »

I got Sabanzbd running thanks to this Howto but I can't get sickbeard/sickrage working.

Captain Ron
NewUser
NewUser
Posts: 14
Joined: 03 Jul 2012 19:33
Location: Boston, MA, USA
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by Captain Ron »

Hey guys, I just followed these instructions. I have SABnzbd running. But I can't seem to be able to download anything. I am fairly certain that this is a permissions issue. Anyone able to lend a hand?
Breaker: NAS4Free 11.0.0.4r3330 x64-full
Intel Celeron G1850 @ 2.90GHz, Supermicro X10SLM-F
16 GB ECC RAM
Intel PCI-E GigE Card & Dual Onboard Intel GigE
16GB SanDisk Ultra USB 3.0 Flash Drive
4 x Western Digital Red 3TB HDD (ZFS Storage/Share)
Antec Performance One P180 Silver

Captain Ron
NewUser
NewUser
Posts: 14
Joined: 03 Jul 2012 19:33
Location: Boston, MA, USA
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by Captain Ron »

Never mind, it appears I am dumb. I was testing on an old set of files that were missing. I think it is working now. False alarm.
Breaker: NAS4Free 11.0.0.4r3330 x64-full
Intel Celeron G1850 @ 2.90GHz, Supermicro X10SLM-F
16 GB ECC RAM
Intel PCI-E GigE Card & Dual Onboard Intel GigE
16GB SanDisk Ultra USB 3.0 Flash Drive
4 x Western Digital Red 3TB HDD (ZFS Storage/Share)
Antec Performance One P180 Silver

User avatar
Barnabas
NewUser
NewUser
Posts: 5
Joined: 13 Apr 2014 06:52
Location: Atlanta, GA
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by Barnabas »

I have followed the above steps, but i cannot get this to work.

When I run /etc/rd.d/sabnzbd start I get

eval: /usr/local/share/SABnzbd/SABnzbd.py --daemon -d -f /mnt/Download/Conf/sabnzbd.ini: not found
eval: :8085: not found

I have changed the location of the ini file to sever different locations with no change.

I think there is some type of permission problem with the script.

Edit: runs fine if I start the .py file /usr/local/share/SABnzbd/SABnzbd.py start but not from the script

Update: I finally got this working by creating a new jail and installing Sabnzbdplus from ports. :P Working great so far.
My NAS
9.2.0.1.972, Fractal Node 304, ASRock C2550D4I, Crucial 16GB ECC, 3x WD Red 3Tb raidZ1

Jlaidlaw86
NewUser
NewUser
Posts: 2
Joined: 11 Jul 2015 06:58
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by Jlaidlaw86 »

I followed the instructions above and I rechecked my work several times. However, when I try sabnzbd start i get "command not found"

What is causing this?

Jlaidlaw86
NewUser
NewUser
Posts: 2
Joined: 11 Jul 2015 06:58
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by Jlaidlaw86 »

Ive been working on this for the last 2 days. I already abandoned a different method in hopes that the process on this thread would fix me problems.

If anyone is out there I sure could use the help

AvanCade
NewUser
NewUser
Posts: 1
Joined: 23 Sep 2015 18:19
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by AvanCade »

Works! Thanks!

Please note that the manual doesn't work on Nas4Free 10. I got miscellaneous. So for everyone struggeling, make sure you use the N4F version as mentioned.

NukeNuke
NewUser
NewUser
Posts: 5
Joined: 16 Jul 2012 17:05
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by NukeNuke »

You can use sabnzbd (sabnzbdplus) in a jail on NAS4Free 10.2.0.2 (revision 1906) embedded.

Use the extension "TheBrig" announced here.

Please test your setting in a VM before use in production!

If your jail is running, you can install sabnzbdplus with this:

Code: Select all

root@host# jls #find JailID of desired Jail
root@host# jexec [JailID] csh
root@jail# pkg
root@jail# pkg install sabnzbdplus
To access mounts on host machine in the jail, you can use

Code: Select all

root@host# mount_nullfs /dir/on/host/data /dir/of/jail/on/host/data
.

Greeting

nvader
NewUser
NewUser
Posts: 3
Joined: 14 Feb 2016 05:00
Status: Offline

Re: [HOWTO] install Sabnzbd inside a Jail | Updated 9.3

Post by nvader »

I modified the /etc/rc.d/sabnzbd script to work for me. (running 10x)
follow all the other directions listed in the OP
then
chmod +x /usr/local/share/SABnzbd/SABnzbd.py
then use this code below in your script
then ./etc/rc.d/sabnzbd start

Code: Select all

#!/bin/sh
    #
    # PROVIDE: sabnzbd
    # REQUIRE: NETWORKING DAEMON
    # KEYWORD: shutdown
    #
    # Add the following lines to /etc/rc.conf.local or /etc/rc.conf
    # to enable this service:
    #
    #sabnzbd_enable="YES"
    #

    sabnzbd_enable=yes
    sabnzbd_user=root
    sabnzbd_PATH=/usr/local/share/SABnzbd/SABnzbd.py
    sabnzbd_conf=/mnt/Download/Conf/sabnzbd.ini
    sabnzbd_IP=<your jails IP> (no brackets)
    sabnzbd_PORT=8080

if [ $1 == "start" ]; then
        PATH=$PATH:/usr/local/bin:/usr/local/sbin:/usr/local/share/SABnzbd; export PATH
        su ${sabnzbd_user} -c "$sabnzbd_PATH --daemon -d -f $sabnzbd_conf -s $sabnzbd_IP:$sabnzbd_PORT"
fi

if [ $1 == "stop" ]; then
 sabnzbd_pid=`ps -U ${sabnzbd_user} | grep "python.*SABnzbd.py.*--daemon" | grep -v 'grep' | awk '{print $1}'`
        if [ -n "${sabnzbd_pid}" ]; then kill ${sabnzbd_pid}; fi
fi

Post Reply

Return to “Jails”