cherrypy and sql query errors

Get help with all aspects of SABnzbd
Forum rules
Help us help you:
  • Are you using the latest stable version of SABnzbd? Downloads page.
  • Tell us what system you run SABnzbd on.
  • Adhere to the forum rules.
  • Do you experience problems during downloading?
    Check your connection in Status and Interface settings window.
    Use Test Server in Config > Servers.
    We will probably ask you to do a test using only basic settings.
  • Do you experience problems during repair or unpacking?
    Enable +Debug logging in the Status and Interface settings window and share the relevant parts of the log here using [ code ] sections.
Megatrond
Newbie
Newbie
Posts: 6
Joined: February 15th, 2019, 4:50 pm

cherrypy and sql query errors

Post by Megatrond »

Hi!
I have had Sabnzbd running on a windows server 2016 for a couple of years now, but after I upgraded the server to Server 2019 I am getting some weird errors that i can't find a sollution for.

The first error i am getting all the time is this one:

Traceback (most recent call last):
File "cherrypy\_cprequest.pyo", line 663, in respond
File "cherrypy\_cpreqbody.pyo", line 989, in process
File "cherrypy\_cpreqbody.pyo", line 558, in process
File "cherrypy\_cpreqbody.pyo", line 223, in process_multipart_form_data
File "cherrypy\_cpreqbody.pyo", line 215, in process_multipart
File "cherrypy\_cpreqbody.pyo", line 556, in process
File "cherrypy\_cpreqbody.pyo", line 715, in default_proc
File "cherrypy\_cpreqbody.pyo", line 729, in read_into_file
File "cherrypy\_cpreqbody.pyo", line 512, in make_file
File "tempfile.pyo", line 475, in NamedTemporaryFile
File "tempfile.pyo", line 244, in _mkstemp_inner
OSError: [Errno 2] No such file or directory: 'c:\\users\\trond\\appdata\\local\\temp\\2\\tmpbjsuir'


The second one is:

ERROR::[database:154] SQL Command Failed, see log

But here I cannot find any errors in the log, It's just the error over and over again.


Sabnzbd has worked like a charm until i upgraded to 2019, but now is only half-working i feel. Sometimes it works, sometimes it errors out and nothing gets downloaded. It is seriously frustrating :(

Any thoughts?

Megatrond
Newbie
Newbie
Posts: 6
Joined: February 15th, 2019, 4:50 pm

Re: cherrypy and sql query errors

Post by Megatrond »

And also, I cannot remember having problems before i installed Ombi if this helps...

User avatar
sander
Release Testers
Release Testers
Posts: 7119
Joined: January 22nd, 2008, 2:22 pm

Re: cherrypy and sql query errors

Post by sander »

Can you read from here: viewtopic.php?t=22877#p112847

Also after a Windows Update. Solved by a Windows Reboot.

Megatrond
Newbie
Newbie
Posts: 6
Joined: February 15th, 2019, 4:50 pm

Re: cherrypy and sql query errors

Post by Megatrond »

The computer has been restarted multiple times since these problems started :(

User avatar
safihre
Administrator
Administrator
Posts: 3871
Joined: April 30th, 2015, 7:35 am
Location: Switzerland
Contact:

Re: cherrypy and sql query errors

Post by safihre »

I would suggest to backup your sabnzbd.ini, and then reinstall sabnzbd. Also make sure to remove the admin directory.
You could also backup history.db to keep your history, this should work.
If you like our support, check our special newsserver deal or donate at: https://sabnzbd.org/donate

Megatrond
Newbie
Newbie
Posts: 6
Joined: February 15th, 2019, 4:50 pm

Re: cherrypy and sql query errors

Post by Megatrond »

safihre wrote:
February 16th, 2019, 6:27 am
I would suggest to backup your sabnzbd.ini, and then reinstall sabnzbd. Also make sure to remove the admin directory.
You could also backup history.db to keep your history, this should work.
I tried this, and it worked for about a day. Looks like I might need to reboot the server about once a day to avoid this problem :(

User avatar
safihre
Administrator
Administrator
Posts: 3871
Joined: April 30th, 2015, 7:35 am
Location: Switzerland
Contact:

Re: cherrypy and sql query errors

Post by safihre »

Maybe a permissions problem? Or does the system have enough space left on the drive?
Or probably a virusscanner..
If you like our support, check our special newsserver deal or donate at: https://sabnzbd.org/donate

Megatrond
Newbie
Newbie
Posts: 6
Joined: February 15th, 2019, 4:50 pm

Re: cherrypy and sql query errors

Post by Megatrond »

Permissions are okey, this problem is only intermittent. There is no permission issues as i can see. Both the physical hd that the vm's are running on, and the virtual disks have at least 50+ GB free space at all time. And when it comes to virus scanners, i only run the windows defender on my servers. When i restart the computer, the progam downloads the files perfectly :(

User avatar
safihre
Administrator
Administrator
Posts: 3871
Joined: April 30th, 2015, 7:35 am
Location: Switzerland
Contact:

Re: cherrypy and sql query errors

Post by safihre »

The error is from a core Python function to create a temporary file, which should never fail in regular setups.
It has occurred more often on VM's where the disk access was somehow delayed, which messes up the timings.
Also for SABnzbd code we have to do all kind of tricks because on VM's sometimes when we send a delete-file command, the file only gets deleted a whole second later for some reason.
In any case: is there some other thing that could be messing with C:/temp? Like cleaning software?
If you like our support, check our special newsserver deal or donate at: https://sabnzbd.org/donate

Megatrond
Newbie
Newbie
Posts: 6
Joined: February 15th, 2019, 4:50 pm

Re: cherrypy and sql query errors

Post by Megatrond »

I will take a closer look, thanks for your input. Now I at least know more where to look for the problem. I will come back and post the fix if I can find it. Might be useful for other users as well.

kvoorhees
Newbie
Newbie
Posts: 2
Joined: March 7th, 2019, 8:45 am

Re: cherrypy and sql query errors

Post by kvoorhees »

This is literally the exact same situation I am in, minus the VM. Stand alone Windows 2016 installation, running great for years. Upgraded to Windows 2019 and I have the exact same experience. Reinstalling or rebooting makes it go away (with successful downloads) and then 12-24 hours later I start getting same errors as OP.

NunyaBzness
Newbie
Newbie
Posts: 16
Joined: April 24th, 2017, 10:23 am

Re: cherrypy and sql query errors

Post by NunyaBzness »

kvoorhees wrote:
March 7th, 2019, 8:47 am
This is literally the exact same situation I am in, minus the VM. Stand alone Windows 2016 installation, running great for years. Upgraded to Windows 2019 and I have the exact same experience. Reinstalling or rebooting makes it go away (with successful downloads) and then 12-24 hours later I start getting same errors as OP.
Another "me too" post. Server 2019 clean install VM. In an attempt to address the timing/delay issue (as much as possible), I moved the boot drive to SSD. No changes in behavior. Please advise if there is additional information you'd like to receive.

User avatar
safihre
Administrator
Administrator
Posts: 3871
Joined: April 30th, 2015, 7:35 am
Location: Switzerland
Contact:

Re: cherrypy and sql query errors

Post by safihre »

There is a tiny tiny chance this will be fixed in Python 2.7.16 that will be part of SABnzbd 2.3.8.
No clue really why Windows is suddenly blocking this...
If you like our support, check our special newsserver deal or donate at: https://sabnzbd.org/donate

NunyaBzness
Newbie
Newbie
Posts: 16
Joined: April 24th, 2017, 10:23 am

Re: cherrypy and sql query errors

Post by NunyaBzness »

Server 2019 is built on top of the Windows 10 version 1809 feature baseline (less Edge/Windows Store), so testing on that platform may help reveal any issues. There are also a number of additional changes versus Server 2016, but there doesn't seem to be anything obvious that would vary in the simple VM implementation that are apparently in use in this thread.

In my case, the 2019 VM is still running on top of a 2016 based Hyper-V.

kvoorhees
Newbie
Newbie
Posts: 2
Joined: March 7th, 2019, 8:45 am

Re: cherrypy and sql query errors

Post by kvoorhees »

I don't think it is a 2019 issue specifically to be honest. I had a similar experience after upgrading from 2012 to 2016 years ago. Unfortunately it persisted until I wiped the box clean and installed the OS fresh. I am very much hoping it doesn't come to that this time. I actually wiped my install of SABNzbd yesterday. Deleted everything in appdata and program files and installed fresh. Worked great and downloaded a bunch of stuff, an hour ago, same error.


2019-03-08 11:11:27,948::ERROR::[_cplogging:219] [08/Mar/2019:11:11:27] HTTP
Traceback (most recent call last):
File "cherrypy\_cprequest.pyo", line 663, in respond
File "cherrypy\_cpreqbody.pyo", line 989, in process
File "cherrypy\_cpreqbody.pyo", line 558, in process
File "cherrypy\_cpreqbody.pyo", line 223, in process_multipart_form_data
File "cherrypy\_cpreqbody.pyo", line 215, in process_multipart
File "cherrypy\_cpreqbody.pyo", line 556, in process
File "cherrypy\_cpreqbody.pyo", line 715, in default_proc
File "cherrypy\_cpreqbody.pyo", line 729, in read_into_file
File "cherrypy\_cpreqbody.pyo", line 512, in make_file
File "tempfile.pyo", line 475, in NamedTemporaryFile
File "tempfile.pyo", line 244, in _mkstemp_inner
OSError: [Errno 2] No such file or directory: 'c:\\users\\kenny\\appdata\\local\\temp\\2\\tmpftvrva'



2019-03-08 11:26:58,640::ERROR::[_cplogging:219] [08/Mar/2019:11:26:58] HTTP
Traceback (most recent call last):
File "cherrypy\_cprequest.pyo", line 663, in respond
File "cherrypy\_cpreqbody.pyo", line 989, in process
File "cherrypy\_cpreqbody.pyo", line 558, in process
File "cherrypy\_cpreqbody.pyo", line 223, in process_multipart_form_data
File "cherrypy\_cpreqbody.pyo", line 215, in process_multipart
File "cherrypy\_cpreqbody.pyo", line 556, in process
File "cherrypy\_cpreqbody.pyo", line 715, in default_proc
File "cherrypy\_cpreqbody.pyo", line 729, in read_into_file
File "cherrypy\_cpreqbody.pyo", line 512, in make_file
File "tempfile.pyo", line 463, in NamedTemporaryFile
File "tempfile.pyo", line 275, in gettempdir
File "tempfile.pyo", line 217, in _get_default_tempdir
IOError: [Errno 2] No usable temporary directory found in ['C:\\Users\\kenny\\AppData\\Local\\Temp\\2', 'C:\\Users\\kenny\\AppData\\Local\\Temp\\2', 'c:\\temp', 'c:\\tmp', '\\temp', '\\tmp', 'C:\\Program Files\\SABnzbd']

I am giving 2.3.8 Beta 1 a try based on the above comments.

Post Reply