Auto-Start doesn't work

Feel free to talk about anything and everything in this board.
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Auto-Start doesn't work

Post by v-enom »

Hi,

i've installed Sabnzbdplus on my raspberry pi with raspbian stretch and auto start after rebooting worked fine. but now it doesn't work. i've installed a lot of other tools but i didn't made any changes in the sabznd settings. nothing that could explain whats wrong. this is the /etc/init.d/sabnzbdplus looks like

Code: Select all

USER=pi
CONFIG=
HOST=0.0.0.0
PORT=
EXTRAOPTS=
is there any log that i can post? maybe this can help: when i start 'sabnzbdplus' in terminal nothing happens. when i stop it with strg + c i have this error:
sabnzbdplus
^CTraceback (most recent call last):
File "/usr/bin/sabnzbdplus", line 57, in <module>
import cherrypy
File "/usr/share/sabnzbdplus/cherrypy/__init__.py", line 60, in <module>
import pkg_resources
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 3019, in <module>
@_call_aside
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 3003, in _call_aside
f(*args, **kwargs)
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 3032, in _initialize_master_working_set
working_set = WorkingSet._build_master()
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 646, in _build_master
ws = cls()
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 639, in __init__
self.add_entry(entry)
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 695, in add_entry
for dist in find_distributions(entry, True):
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2005, in find_on_path
path_item_entries = _by_version_descending(os.listdir(path_item))
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 1989, in _by_version_descending
return sorted(names, key=_by_version, reverse=True)
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 1987, in _by_version
return [packaging.version.parse(part) for part in parts]
File "/usr/lib/python2.7/dist-packages/pkg_resources/_vendor/packaging/version.py", line 33, in parse
return LegacyVersion(version)
File "/usr/lib/python2.7/dist-packages/pkg_resources/_vendor/packaging/version.py", line 76, in __init__
self._key = _legacy_cmpkey(self._version)
File "/usr/lib/python2.7/dist-packages/pkg_resources/_vendor/packaging/version.py", line 152, in _legacy_cmpkey
parts.append(part)
KeyboardInterrupt
User avatar
jcfp
Release Testers
Release Testers
Posts: 986
Joined: February 7th, 2008, 12:45 pm

Re: Auto-Start doesn't work

Post by jcfp »

If the application doesn't work, the init script won't be able to start it either.

How long did you let the command run in the terminal before the interrupt? Can you connect to the web interface?

Any output if you use this instead (enables debug logging):

Code: Select all

sabnzbdplus -l 2
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Re: Auto-Start doesn't work

Post by v-enom »

jcfp wrote: February 16th, 2018, 3:02 pmHow long did you let the command run in the terminal before the interrupt? Can you connect to the web interface?
A few monites. maybe 2 or 3. no i cant connect to the web interface.

When i try 'dpkg -l sabnzbdplus' i get this output

Code: Select all

iF sabnzbdplus                 2.3.2-0ubuntu1~jcf all                web-based binary newsreader with nzb support
after that i removed sabnzbdplus a after that i made also 'apt autoremove', rebootet the machine and installed sabnzbdplus again. now the output of 'dpkg -l' is

Code: Select all

ii  sabnzbdplus                 2.3.2-0ubuntu1~jcf all                web-based binary newsreader with nzb support
but the auto start still doesn't work.

sabnzbdplus -l 2 brings my the same output

Code: Select all

sabnzbdplus -l 2
Traceback (most recent call last):
  File "/usr/bin/sabnzbdplus", line 1721, in <module>
    main()
  File "/usr/bin/sabnzbdplus", line 969, in main
    res, msg = config.read_config(inifile)
  File "/usr/share/sabnzbdplus/sabnzbd/decorators.py", line 36, in call_func
    return f(*args, **kw)
  File "/usr/share/sabnzbdplus/sabnzbd/config.py", line 699, in read_config
    return _read_config(path)
  File "/usr/share/sabnzbdplus/sabnzbd/config.py", line 747, in _read_config
    CFG = configobj.ConfigObj(lines, default_encoding='cp1252', encoding='cp1252')
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1229, in __init__
    self._load(infile, configspec)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1287, in _load
    content = self._handle_bom(content)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1399, in _handle_bom
    return self._decode(infile, self.encoding)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1517, in _decode
    infile[i] = line.decode(encoding)
  File "/usr/lib/python2.7/encodings/cp1252.py", line 15, in decode
    return codecs.charmap_decode(input,errors,decoding_table)
UnicodeDecodeError: 'charmap' codec can't decode byte 0x90 in position 428: character maps to <undefined>
User avatar
sander
Release Testers
Release Testers
Posts: 8811
Joined: January 22nd, 2008, 2:22 pm

Re: Auto-Start doesn't work

Post by sander »

My guess: your sabnzbd.ini is corrupt. Delete/move it, and try again
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Re: Auto-Start doesn't work

Post by v-enom »

Doesn't work. Start the program manually results in this error:

Code: Select all

sabnzbdplus
Traceback (most recent call last):
  File "/usr/bin/sabnzbdplus", line 1721, in <module>
    main()
  File "/usr/bin/sabnzbdplus", line 969, in main
    res, msg = config.read_config(inifile)
  File "/usr/share/sabnzbdplus/sabnzbd/decorators.py", line 36, in call_func
    return f(*args, **kw)
  File "/usr/share/sabnzbdplus/sabnzbd/config.py", line 699, in read_config
    return _read_config(path)
  File "/usr/share/sabnzbdplus/sabnzbd/config.py", line 747, in _read_config
    CFG = configobj.ConfigObj(lines, default_encoding='cp1252', encoding='cp1252')
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1229, in __init__
    self._load(infile, configspec)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1287, in _load
    content = self._handle_bom(content)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1399, in _handle_bom
    return self._decode(infile, self.encoding)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1517, in _decode
    infile[i] = line.decode(encoding)
  File "/usr/lib/python2.7/encodings/cp1252.py", line 15, in decode
    return codecs.charmap_decode(input,errors,decoding_table)
UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d in position 2: character maps to <undefined>
User avatar
sander
Release Testers
Release Testers
Posts: 8811
Joined: January 22nd, 2008, 2:22 pm

Re: Auto-Start doesn't work

Post by sander »

To be sure:

Code: Select all

sabnzbdplus -l2 -f blabla.ini

... what does that give?
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Re: Auto-Start doesn't work

Post by v-enom »

Code: Select all

sabnzbdplus -l2 -f blabla.ini
2018-02-17 21:12:35,489::INFO::[sabnzbdplus:1136] --------------------------------
2018-02-17 21:12:35,496::INFO::[sabnzbdplus:1137] sabnzbdplus-2.3.2 (rev=1cac5799eb3f74f2e39942453b7b244fb0366e9a)
2018-02-17 21:12:35,502::INFO::[sabnzbdplus:1138] Full executable path = /usr/bin/sabnzbdplus
2018-02-17 21:12:35,509::INFO::[sabnzbdplus:1148] Platform = posix
2018-02-17 21:12:35,518::INFO::[sabnzbdplus:1149] Python-version = 2.7.13 (default, Nov 24 2017, 17:33:09) 
[GCC 6.3.0 20170516]
2018-02-17 21:12:35,526::INFO::[sabnzbdplus:1150] Arguments = /usr/bin/sabnzbdplus -l2 -f blabla.ini
2018-02-17 21:12:35,534::INFO::[sabnzbdplus:1155] Preferred encoding = UTF-8
2018-02-17 21:12:35,540::INFO::[sabnzbdplus:1165] SSL version = OpenSSL 1.1.0f  25 May 2017
2018-02-17 21:12:35,550::DEBUG::[sabnzbdplus:1179] Available certificates: {'x509': 0, 'x509_ca': 0, 'crl': 0}
2018-02-17 21:12:35,558::DEBUG::[sabnzbdplus:1186] My local IPv4 address = 192.168.10.23
2018-02-17 21:12:36,066::DEBUG::[sabnzbdplus:1192] My public IPv4 address = 93.192.248.221
2018-02-17 21:12:36,073::DEBUG::[sabnzbdplus:1200] Could not determine my IPv6 address
2018-02-17 21:12:36,511::DEBUG::[sabnzbdplus:1206] CPU Pystone available performance = 2752
2018-02-17 21:12:36,519::DEBUG::[sabnzbdplus:1211] CPU model = ARMv6-compatible processor rev 7 (v6l)
2018-02-17 21:12:36,526::INFO::[sabnzbdplus:1213] Read INI file /home/pi/blabla.ini
2018-02-17 21:12:36,537::DEBUG::[misc:1592] Applying permissions 0755 (octal) to /home/pi/Downloads/incomplete
2018-02-17 21:12:37,606::DEBUG::[__init__:971] [sabnzbd.check_old_queue] Loading data for queue9.sab from /home/pi/admin/queue9.sab
2018-02-17 21:12:37,615::INFO::[__init__:974] [sabnzbd.check_old_queue] /home/pi/admin/queue9.sab missing
2018-02-17 21:12:37,623::DEBUG::[__init__:971] [sabnzbd.check_old_queue] Loading data for queue8.sab from /home/pi/admin/queue8.sab
2018-02-17 21:12:37,631::INFO::[__init__:974] [sabnzbd.check_old_queue] /home/pi/admin/queue8.sab missing
2018-02-17 21:12:37,639::DEBUG::[__init__:971] [sabnzbd.check_old_queue] Loading data for queue7.sab from /home/pi/admin/queue7.sab
2018-02-17 21:12:37,647::INFO::[__init__:974] [sabnzbd.check_old_queue] /home/pi/admin/queue7.sab missing
2018-02-17 21:12:37,796::INFO::[config:853] Writing settings to INI file /home/pi/blabla.ini
2018-02-17 21:12:38,096::DEBUG::[__init__:971] [sabnzbd.rss.__init__] Loading data for rss_data.sab from /home/pi/admin/rss_data.sab
2018-02-17 21:12:38,104::INFO::[__init__:974] [sabnzbd.rss.__init__] /home/pi/admin/rss_data.sab missing
2018-02-17 21:12:38,113::DEBUG::[__init__:971] [sabnzbd.bpsmeter.read] Loading data for totals10.sab from /home/pi/admin/totals10.sab
2018-02-17 21:12:38,120::INFO::[__init__:974] [sabnzbd.bpsmeter.read] /home/pi/admin/totals10.sab missing
2018-02-17 21:12:38,128::DEBUG::[__init__:971] [sabnzbd.bpsmeter.read] Loading data for totals9.sab from /home/pi/admin/totals9.sab
2018-02-17 21:12:38,136::INFO::[__init__:974] [sabnzbd.bpsmeter.read] /home/pi/admin/totals9.sab missing
2018-02-17 21:12:38,142::DEBUG::[bpsmeter:148] Setting default BPS meter values
2018-02-17 21:12:39,191::DEBUG::[downloader:163] Initializing downloader/decoder
2018-02-17 21:12:39,206::INFO::[postproc:100] Loading postproc queue
2018-02-17 21:12:39,215::DEBUG::[__init__:971] [sabnzbd.postproc.load] Loading data for postproc2.sab from /home/pi/admin/postproc2.sab
2018-02-17 21:12:39,222::INFO::[__init__:974] [sabnzbd.postproc.load] /home/pi/admin/postproc2.sab missing
2018-02-17 21:12:39,233::DEBUG::[__init__:971] [sabnzbd.nzbqueue.read_queue] Loading data for queue10.sab from /home/pi/admin/queue10.sab
2018-02-17 21:12:39,240::INFO::[__init__:974] [sabnzbd.nzbqueue.read_queue] /home/pi/admin/queue10.sab missing
2018-02-17 21:12:39,382::INFO::[config:853] Writing settings to INI file /home/pi/blabla.ini
2018-02-17 21:12:39,667::DEBUG::[__init__:971] [sabnzbd.dirscanner.__init__] Loading data for watched_data2.sab from /home/pi/admin/watched_data2.sab
2018-02-17 21:12:39,675::INFO::[__init__:974] [sabnzbd.dirscanner.__init__] /home/pi/admin/watched_data2.sab missing
2018-02-17 21:12:39,686::DEBUG::[__init__:971] [sabnzbd.rating.__init__] Loading data for Rating.sab from /home/pi/admin/Rating.sab
2018-02-17 21:12:39,693::INFO::[__init__:974] [sabnzbd.rating.__init__] /home/pi/admin/Rating.sab missing
2018-02-17 21:12:39,705::DEBUG::[scheduler:180] Scheduling RSS interval task every 60 min (delay=46)
2018-02-17 21:12:39,712::INFO::[scheduler:197] Setting schedule for midnight BPS reset
2018-02-17 21:12:39,720::DEBUG::[__init__:587] PAUSED_ALL inactive
2018-02-17 21:12:39,726::INFO::[__init__:345] All processes started
2018-02-17 21:12:39,733::INFO::[sabnzbdplus:281] Web dir is /usr/share/sabnzbdplus/interfaces/Glitter
2018-02-17 21:12:39,745::INFO::[sabnzbdplus:281] Web dir is /usr/share/sabnzbdplus/interfaces/Config
2018-02-17 21:12:39,881::INFO::[config:853] Writing settings to INI file /home/pi/blabla.ini
2018-02-17 21:12:40,338::INFO::[sabnzbdplus:392] SABYenc module (v3.3.2)... found!
2018-02-17 21:12:40,345::INFO::[sabnzbdplus:409] Cryptography module (v1.7.1)... found!
2018-02-17 21:12:40,352::INFO::[sabnzbdplus:414] par2 binary... found (/usr/bin/par2)
2018-02-17 21:12:40,358::INFO::[sabnzbdplus:424] UNRAR binary... found (/usr/bin/unrar)
2018-02-17 21:12:40,364::INFO::[sabnzbdplus:432] UNRAR binary version 5.30
2018-02-17 21:12:40,371::INFO::[sabnzbdplus:437] unzip binary... found (/usr/bin/unzip)
2018-02-17 21:12:40,377::INFO::[sabnzbdplus:442] 7za binary... found (/usr/bin/7za)
2018-02-17 21:12:40,384::INFO::[sabnzbdplus:448] nice binary... found (/usr/bin/nice)
2018-02-17 21:12:40,390::INFO::[sabnzbdplus:452] ionice binary... found (/usr/bin/ionice)
2018-02-17 21:12:40,418::INFO::[sabnzbdplus:1368] Starting web-interface on 127.0.0.1:8080
2018-02-17 21:12:40,425::INFO::[_cplogging:219] [17/Feb/2018:21:12:40] ENGINE Bus STARTING
2018-02-17 21:12:49,226::INFO::[_cplogging:219] [17/Feb/2018:21:12:49] ENGINE Serving on http://127.0.0.1:8080
2018-02-17 21:12:49,236::INFO::[_cplogging:219] [17/Feb/2018:21:12:49] ENGINE Bus STARTED
2018-02-17 21:12:49,242::INFO::[sabnzbdplus:1406] Starting sabnzbdplus-2.3.2
2018-02-17 21:12:49,248::DEBUG::[__init__:356] Starting postprocessor
2018-02-17 21:12:49,256::DEBUG::[__init__:359] Starting assembler
2018-02-17 21:12:49,291::DEBUG::[__init__:362] Starting downloader
2018-02-17 21:12:49,327::DEBUG::[scheduler:209] Starting scheduler
2018-02-17 21:12:49,349::DEBUG::[__init__:367] Starting dirscanner
2018-02-17 21:12:49,367::DEBUG::[__init__:372] Starting urlgrabber
2018-02-17 21:12:49,362::INFO::[dirscanner:330] Dirscanner starting up
2018-02-17 21:12:49,391::INFO::[urlgrabber:81] URLGrabber starting up
2018-02-17 21:12:49,395::INFO::[panic:209] Launching browser with http://127.0.0.1:8080/sabnzbd
2018-02-17 21:12:49,410::DEBUG::[misc:653] Version check disabled by Debian/Ubuntu packaging
2018-02-17 21:12:49,416::INFO::[zconfig:77] Bonjour/ZeroConfig does not support "localhost"
2018-02-17 21:12:49,468::DEBUG::[__init__:1177] Test IPv6: Cannot reach IPv6 test host. Disabling IPv6
2018-02-17 21:12:49,475::DEBUG::[downloader:395] External IPv6 test result: False
2018-02-17 21:12:49,684::INFO::[postproc:187] Completed Download Folder /home/pi/Downloads/complete is not on FAT
2018-02-17 21:12:49,913::DEBUG::[downloader:411] SSL verification test: True
User avatar
sander
Release Testers
Release Testers
Posts: 8811
Joined: January 22nd, 2008, 2:22 pm

Re: Auto-Start doesn't work

Post by sander »

So ... No more errors, right?

If you agree, I repeat my hypothesis: corruption in your sabnzbd.ini. Remove it, and you should be OK.
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Re: Auto-Start doesn't work

Post by v-enom »

no more errors. the web interface was not available.
If you agree, I repeat my hypothesis: corruption in your sabnzbd.ini. Remove it, and you should be OK.
i already tried this, doesn't work. when i restart sabnzbd after deletig the ini i have this error:

Code: Select all

sabnzbdplus
Traceback (most recent call last):
  File "/usr/bin/sabnzbdplus", line 1721, in <module>
    main()
  File "/usr/bin/sabnzbdplus", line 969, in main
    res, msg = config.read_config(inifile)
  File "/usr/share/sabnzbdplus/sabnzbd/decorators.py", line 36, in call_func
    return f(*args, **kw)
  File "/usr/share/sabnzbdplus/sabnzbd/config.py", line 699, in read_config
    return _read_config(path)
  File "/usr/share/sabnzbdplus/sabnzbd/config.py", line 747, in _read_config
    CFG = configobj.ConfigObj(lines, default_encoding='cp1252', encoding='cp1252')
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1229, in __init__
    self._load(infile, configspec)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1287, in _load
    content = self._handle_bom(content)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1399, in _handle_bom
    return self._decode(infile, self.encoding)
  File "/usr/lib/python2.7/dist-packages/configobj.py", line 1517, in _decode
    infile[i] = line.decode(encoding)
  File "/usr/lib/python2.7/encodings/cp1252.py", line 15, in decode
User avatar
sander
Release Testers
Release Testers
Posts: 8811
Joined: January 22nd, 2008, 2:22 pm

Re: Auto-Start doesn't work

Post by sander »

How do you delete the sabnzbd.ini?

Afterwards, can you prove it's gone?
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Re: Auto-Start doesn't work

Post by v-enom »

Code: Select all

rm sabnzbd.ini
and i checked that with ls and the ini wasn't there. so i'm sure the ini was deleted?
User avatar
sander
Release Testers
Release Testers
Posts: 8811
Joined: January 22nd, 2008, 2:22 pm

Re: Auto-Start doesn't work

Post by sander »

v-enom wrote: February 19th, 2018, 2:49 pm

Code: Select all

rm sabnzbd.ini
and i checked that with ls and the ini wasn't there. so i'm sure the ini was deleted?
No, that's incorrect. And that rm command will give you an error, doesn't it. The sabnzbd.ini is in ~/.sabnzbd/sabnzbd.ini

So

Code: Select all

rm ~/.sabnzbd/sabnzbd.ini
(FWIW: Documented in https://sabnzbd.org/wiki/advanced/directory-setup )
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Re: Auto-Start doesn't work

Post by v-enom »

of course i changed the direciry before i removed the ini. the ini isn't there, i checked it with ls -l in ~/.sabnzbd.
User avatar
sander
Release Testers
Release Testers
Posts: 8811
Joined: January 22nd, 2008, 2:22 pm

Re: Auto-Start doesn't work

Post by sander »

Then I'm out of advice.
v-enom
Newbie
Newbie
Posts: 30
Joined: April 6th, 2013, 7:21 am

Re: Auto-Start doesn't work

Post by v-enom »

i think i've found the problem. i didn't realise that jdownloader was running and auto started because i didn't use a hdmi cable and didn't connect to the running vnc server. i know thta jdownloader needs a lot of ressources. now, after disable the auto start of jdownloader sabnzbd is running after reboot. maybe the problem was there was not enough ressources left to start sabnzbd?

i will not use the auto start for jdownloader, but sometimes i will need the program and i think both programs doesn't work good when running together. is there an easy way to disable the sabnzbd auto start using ssh?
Post Reply