SABnzdb not turning on after upgrade

Status
Not open for further replies.

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
I was getting the error "Trying to fetch NZB from...." on my version 1.0 of SABnzdb, so I decided to upgrade to 1.02. After clicking on upgrade from the installed plugins menu it said installed successfully, but the button says off. Clicking on it to turn it back on doesn't help.
Code:
root@sabnzbd_1:/ # service sabnzbd start
Starting sabnzbd.
root@sabnzbd_1:/ # service sabnzbd stop
sabnzbd not running? (check /var/run/sabnzbd/sabnzbd.pid).

doesn't help. Any thoughts on what to do to fix it would be appreciated.
 

maglin

Patron
Joined
Jun 20, 2015
Messages
299
You need to change the ownership of your sabnzbd folder. It's probably something like root:wheel At The Moment. Go to the directory above sabnzbd and run
chown (user):(group) sabnzbd
Without parentheses. Mine is media user and media group so I run

chown media:media sabnzbd

I'm 95% sure that is your problem. The sabnzbd user doesn't have write privilege to that directory anymore.


Sent from my iPhone using Tapatalk
 

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
Didn't help. If I do
Code:
service sabnzbd restart
it says
Code:
sabnzbd not running? (check /var/run/sabnzbd/sabnzbd.pid).
 

brando56894

Wizard
Joined
Feb 15, 2014
Messages
1,537
Try and run it manually and see if it spits out any errors regarding why it won't start. Have you checked the logs?
 

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
the nginx error log shows
Code:
[emerg] 8622#0: open() "/usr/local/etc/nginx/mime.types" failed (2: No such file or directory) in /usr/local/etc/nginx/nginx.conf:18

and when restarting sabnzbd
Code:
service sabnzbd restart
sabnzbd not running? (check /var/run/sabnzbd/sabnzbd.pid).
Starting sabnzbd.
 

brando56894

Wizard
Joined
Feb 15, 2014
Messages
1,537
Well the first issue is you're missing the MIME types file, but that's unrelated to SABnzbd since it uses its own web server. I meant check the log for SABnzbd, I forget the location and can't tell you since I'm not using BSD at the moment.

Also when I said "try to start it manually" I meant execute SABnzbd.py not just reload the service file ;-)

Sent from my Nexus 6 using Tapatalk
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
As stated, nginx is unrelated.

I don't recommend you just try running the SABnzbd.py file, unless you are running them as the proper user (default media) and with the flags in the init script (/usr/local/etc/rc.d/sabnzbd)
If running 'service sabnzbd start' then 'service sabnzbd status' shows the service is off then you want to check your sabnzbd logs for the error in /var/db/sabnzbd
If that shows the service is working, then your problem is the FreeNAS WebUI interfacing with the plugin's middleware layer. I suggest you try restarting the jail and see if it stil does not work.
 

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
Service is off after running start then status.
The sabnzbd.error.log:
Code:
Exception in thread CP WSGIServer Thread-47:
Traceback (most recent call last):
  File "/usr/pbi/sabnzbd-amd64/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1295, in run
    conn.communicate()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1212, in communicate
    req.simple_response("408 Request Timeout")
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 612, in simple_response
    self.wfile.sendall("".join(buf))
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1126, in sendall
    return self._safe_call(False, super(SSL_fileobject, self).sendall, *args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1078, in _safe_call
    return call(*args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 748, in sendall
    bytes_sent = self.send(data)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1129, in send
    return self._safe_call(False, super(SSL_fileobject, self).send, *args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1108, in _safe_call
    raise FatalSSLAlert(*e.args)
FatalSSLAlert: [('SSL routines', 'SSL23_WRITE', 'ssl handshake failure')]

sabnzbd.log
Code:
Traceback (most recent call last):
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbdplus/cherrypy/process/servers.py", line 206, in _start_http_thread
    self.httpserver.start()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbdplus/cherrypy/wsgiserver/wsgiserver2.py", line 1965, in start
    self.bind(af, socktype, proto)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbdplus/cherrypy/wsgiserver/wsgiserver2.py", line 2019, in bind
    self.socket = self.ssl_adapter.bind(self.socket)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbdplus/cherrypy/wsgiserver/ssl_pyopenssl.py", line 180, in bind
    self.context = self.get_context()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbdplus/cherrypy/wsgiserver/ssl_pyopenssl.py", line 193, in get_context
    c.use_privatekey_file(self.private_key)
  File "/usr/pbi/sabnzbd-amd64/lib/python2.7/site-packages/OpenSSL/SSL.py", line 655, in use_privatekey_file
    keyfile = _path_string(keyfile)
  File "/usr/pbi/sabnzbd-amd64/lib/python2.7/site-packages/OpenSSL/_util.py", line 86, in path_string
    return s.encode(sys.getfilesystemencoding())
TypeError: encode() argument 1 must be string, not None

2016-05-26 17:31:33,188::INFO::[_cplogging:216] [26/May/2016:17:31:33] ENGINE Bus STOPPING
2016-05-26 17:31:33,188::INFO::[_cplogging:216] [26/May/2016:17:31:33] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 9090)) already shut down
2016-05-26 17:31:33,190::INFO::[_cplogging:216] [26/May/2016:17:31:33] ENGINE HTTP Server cherrypy._cpwsgi_server.CPWSGIServer(('0.0.0.0', 8080)) shut down
2016-05-26 17:31:33,191::INFO::[_cplogging:216] [26/May/2016:17:31:33] ENGINE Stopped thread '_TimeoutMonitor'.
2016-05-26 17:31:33,191::INFO::[_cplogging:216] [26/May/2016:17:31:33] ENGINE Bus STOPPED
2016-05-26 17:31:33,191::INFO::[_cplogging:216] [26/May/2016:17:31:33] ENGINE Bus EXITING
2016-05-26 17:31:33,191::INFO::[_cplogging:216] [26/May/2016:17:31:33] ENGINE Bus EXITED
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I'd post your logs on the sabnzbd forum or github. it looks like it might be related to SSL not working for some reason, so you could try editing your config file in /var/db/sabnzbd and disable SSL then try starting it
 

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
Joshua,
I also tried to start over with a new jail sabnzbd_2 and added the same storage as the original, so I skipped the mkdir -p .... as they already exist. Sabnzbd works but the webUI for sickrage and couchpotato don't load. http://x.x.x.x:8081/sickrage/home/
gives the error
page isn’t working
ERR_TOO_MANY_REDIRECT.
http://x.x.x.x:5050/couchpotato
refused to connect.
ERR_CONNECTION_REFUSED
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
did you already configure sickrage and couchpotato to use those webroots? if you saved your /var/db/(sickrage|couchpotato) directories then the setting would still be there.
 

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
deleted sabnzbd plugin and reinstalled the older version 0.7.2 into my original jail and now it's working. Must be an issue with the 1.02 of sabnzbd.
 

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
1) I am able to delete the sabnzbd plugin and install 1.01 to the jail and it works but 1.02 doesn't. Not sure why.
2) My original issue with the sabnzbd message "Trying to fetch NZB from...." I'm thinking might be an ssl certificate issue from my searching. That msg goes away using another nzb provider but not on my nZEDb indexer. I have no idea how to fix this.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
1) I am able to delete the sabnzbd plugin and install 1.01 to the jail and it works but 1.02 doesn't. Not sure why.
2) My original issue with the sabnzbd message "Trying to fetch NZB from...." I'm thinking might be an ssl certificate issue from my searching. That msg goes away using another nzb provider but not on my nZEDb indexer. I have no idea how to fix this.
did you check the sabnzbd's logs why it's not starting?

I'll upgrade to 1.0.2 now and post if I hit an issue.
EDIT
It worked as expected.
 
Last edited:

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
I tried to delete the sabnzbd plugin from my jail and install 1.02. It won't start.
The error log for sabnzbd is
Code:
Exception in thread CP WSGIServer Thread-46:
Traceback (most recent call last):
  File "/usr/pbi/sabnzbd-amd64/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1295, in run
    conn.communicate()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1212, in communicate
    req.simple_response("408 Request Timeout")
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 612, in simple_response
    self.wfile.sendall("".join(buf))
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1126, in sendall
    return self._safe_call(False, super(SSL_fileobject, self).sendall, *args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1078, in _safe_call
    return call(*args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 748, in sendall
    bytes_sent = self.send(data)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1129, in send
    return self._safe_call(False, super(SSL_fileobject, self).send, *args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1108, in _safe_call
    raise FatalSSLAlert(*e.args)
FatalSSLAlert: [('SSL routines', 'SSL23_WRITE', 'ssl handshake failure')]
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I tried to delete the sabnzbd plugin from my jail and install 1.02. It won't start.
The error log for sabnzbd is
Code:
Exception in thread CP WSGIServer Thread-46:
Traceback (most recent call last):
  File "/usr/pbi/sabnzbd-amd64/lib/python2.7/threading.py", line 810, in __bootstrap_inner
    self.run()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1295, in run
    conn.communicate()
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1212, in communicate
    req.simple_response("408 Request Timeout")
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 612, in simple_response
    self.wfile.sendall("".join(buf))
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1126, in sendall
    return self._safe_call(False, super(SSL_fileobject, self).sendall, *args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1078, in _safe_call
    return call(*args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 748, in sendall
    bytes_sent = self.send(data)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1129, in send
    return self._safe_call(False, super(SSL_fileobject, self).send, *args, **kwargs)
  File "/usr/pbi/sabnzbd-amd64/share/sabnzbd/SABnzbd/cherrypy/wsgiserver/__init__.py", line 1108, in _safe_call
    raise FatalSSLAlert(*e.args)
FatalSSLAlert: [('SSL routines', 'SSL23_WRITE', 'ssl handshake failure')]
Did you have HTTPS enabled for sabnzbd? Looks like your errors might be related to that and you might want to try disabling it in your /var/db/sabnzbd/sabnzbd.ini

Does a fresh install of sabnzbd v1.0.2 in new jail work as expected?
 

NasKar

Guru
Joined
Jan 8, 2016
Messages
739
Did you have HTTPS enabled for sabnzbd? Looks like your errors might be related to that and you might want to try disabling it in your /var/db/sabnzbd/sabnzbd.ini

Does a fresh install of sabnzbd v1.0.2 in new jail work as expected?
I created a new jail and reinstalled the plugins and used the same storage location for the jail and it all works. Crazy how minor tweaks mess up the entire thing :). The 'Trying to fetch ...' error was caused by my nZEDb server as it's not a problem since I reinstalled it (using Ubuntu on another computer) as I'm still working out issue with the freenas version. Am I correct in my understanding that the only piece of my local setup (not accessible from internet) that should use ssl is the setup of my news provider in sabnzbd, and using of port 9090 would only help if it were accessible from the internet? Thanks for you expertise as usual.
 

Joshua Parker Ruehlig

Hall of Famer
Joined
Dec 5, 2011
Messages
5,949
I created a new jail and reinstalled the plugins and used the same storage location for the jail and it all works. Crazy how minor tweaks mess up the entire thing :). The 'Trying to fetch ...' error was caused by my nZEDb server as it's not a problem since I reinstalled it (using Ubuntu on another computer) as I'm still working out issue with the freenas version. Am I correct in my understanding that the only piece of my local setup (not accessible from internet) that should use ssl is the setup of my news provider in sabnzbd, and using of port 9090 would only help if it were accessible from the internet? Thanks for you expertise as usual.
yeah, I would only use SSL to connect to my usenet server (in my case UsenetServer). If you are connecting to sabnzbd/nZEDb from outside your LAN using a port forward, instead of a VPN, I recommend a setting up SSL for nginx/sabnzbd/nginx to proxy to sabnzbd, just so your passwords aren't sniffed.
 
Status
Not open for further replies.
Top