Page 1 of 1

ERROR: SQL Command Failed, see log: OperationalError: database or disk is full

Posted: February 12th, 2018, 7:48 am
by rorrantia
Hello, been using SABnzb for a while on a QNAP 453 mini, without incident but suddenly started getting this error message:
SQL Command Failed, see log
.
My Discs are NOT full and all the files are set to 777.

When i checked my logs I get the following:

Code: Select all

2018-02-10 08:43:00,452::INFO::[database:155] SQL: SELECT * FROM history WHERE name LIKE ? ORDER BY completed desc LIMIT ?, ?
2018-02-10 08:43:00,452::INFO::[database:156] Arguments: ('%%', 0, 1000000)
2018-02-10 08:43:00,453::INFO::[database:157] Traceback: 
Traceback (most recent call last):
  File "/share/CACHEDEV1_DATA/.qpkg/SABnzbdplus/SABnzbdplus/sabnzbd/database.py", line 125, in execute
    self.c.execute(command, args)
OperationalError: database or disk is full
2018-02-10 08:43:21,725::ERROR::[database:154] SQL Command Failed, see log
2018-02-10 08:43:21,726::INFO::[database:155] SQL: SELECT * FROM history WHERE name LIKE ? ORDER BY completed desc LIMIT ?, ?
2018-02-10 08:43:21,726::INFO::[database:156] Arguments: ('%%', 0, 1000000)
2018-02-10 08:43:21,727::INFO::[database:157] Traceback: 
Traceback (most recent call last):
  File "/share/CACHEDEV1_DATA/.qpkg/SABnzbdplus/SABnzbdplus/sabnzbd/database.py", line 125, in execute
    self.c.execute(command, args)
OperationalError: database or disk is full
2018-02-10 08:43:21,902::ERROR::[database:154] SQL Command Failed, see log
2018-02-10 08:43:21,903::INFO::[database:155] SQL: SELECT * FROM history WHERE name LIKE ? ORDER BY completed desc LIMIT ?, ?
2018-02-10 08:43:21,903::INFO::[database:156] Arguments: ('%%', 0, 1000000)
2018-02-10 08:43:21,904::INFO::[database:157] Traceback: 
Traceback (most recent call last):
  File "/share/CACHEDEV1_DATA/.qpkg/SABnzbdplus/SABnzbdplus/sabnzbd/database.py", line 125, in execute
    self.c.execute(command, args) 
Thank you in advanced for any help provided.

Re: ERROR: SQL Command Failed, see log

Posted: February 12th, 2018, 9:01 am
by sander
/share/CACHEDEV1_DATA/... ... what kind of disk is that? A NAS?

Re: ERROR: SQL Command Failed, see log

Posted: February 12th, 2018, 9:29 am
by rorrantia
sander wrote: February 12th, 2018, 9:01 am /share/CACHEDEV1_DATA/... ... what kind of disk is that? A NAS?
Yes it is a QNAP 453 Mini running Raid 5

Re: ERROR: SQL Command Failed, see log

Posted: February 12th, 2018, 9:44 am
by sander
rorrantia wrote: February 12th, 2018, 9:29 am
sander wrote: February 12th, 2018, 9:01 am /share/CACHEDEV1_DATA/... ... what kind of disk is that? A NAS?
Yes it is a QNAP 453 Mini running Raid 5
Ah, I see.

It's best practise to put SAB's Incomplete and the 'system' directory on a local disk. Otherwise you can expect problems, like you're experiencing now; if there is a glitch in the NAS connection, all kinds of things can happen.

Re: ERROR: SQL Command Failed, see log

Posted: February 12th, 2018, 10:05 am
by OneCD
CACHEDEV1_DATA is QNAP’s name for the first array. It’s where all data is stored. There’s no-where else to put it. ;)

Re: ERROR: SQL Command Failed, see log

Posted: February 12th, 2018, 10:08 am
by sander
OneCD wrote: February 12th, 2018, 10:05 am CACHEDEV1_DATA is QNAP’s name for the first array. It’s where all data is stored. There’s no-where else to put it. ;)
Do you mean SABnzbd is running on that NAS? So the disk is local?

Re: ERROR: SQL Command Failed, see log

Posted: February 12th, 2018, 10:10 am
by OneCD
If by local you mean not remote, then yes.

Re: ERROR: SQL Command Failed, see log

Posted: February 12th, 2018, 10:20 am
by rorrantia
sander wrote: February 12th, 2018, 10:08 am
OneCD wrote: February 12th, 2018, 10:05 am CACHEDEV1_DATA is QNAP’s name for the first array. It’s where all data is stored. There’s no-where else to put it. ;)
Do you mean SABnzbd is running on that NAS? So the disk is local?
Yes it is running on the NAS, it is local.

Re: ERROR: SQL Command Failed, see log: OperationalError: database or disk is full

Posted: February 12th, 2018, 10:27 am
by sander
If you google "OperationalError: database or disk is full", there are a lot of useful links, especially in combination with QNAP

And I would check the size of 'history.db' and the other files in the admin folder.

Re: ERROR: SQL Command Failed, see log: OperationalError: database or disk is full

Posted: February 12th, 2018, 11:11 am
by rorrantia
sander wrote: February 12th, 2018, 10:27 am If you google "OperationalError: database or disk is full", there are a lot of useful links, especially in combination with QNAP

And I would check the size of 'history.db' and the other files in the admin folder.
Thank you for all your help sander and thanks to OneCD on both forums :) It is very much appreciated!
It seems fixed for now, had to do a drastic fix but seems to be working correctly...
Will have to wait and see if it is working after a while and a few files.
But for now what I did was delete the history1.db found in

Code: Select all

/share/CACHEDEV1_DATA/.qpkg/SABnzbdplus/config/admin
and reinstalled SABnzb using the GREAT Sherpa script that OneCD has made for QNAP

Code: Select all

https://forum.qnap.com/viewtopic.php?f=320&t=132373
.
Sure you loose the history found on SABnzb, but I at least do not need it.
Have tested a few files and no error, so it might be a DB corruption of some sort? Will post back if it works on a longer term for others who might have the same problems.

Re: ERROR: SQL Command Failed, see log: OperationalError: database or disk is full

Posted: February 12th, 2018, 11:31 am
by sander
But for now what I did was delete the history1.db found in
Ah, yes, good one.

Before deleting, did you check the size of history1.db ?
and reinstalled SABnzb
No need for that; SABnzbd can start without history1.db ... it will create a fresh one.

Re: ERROR: SQL Command Failed, see log: OperationalError: database or disk is full

Posted: February 14th, 2018, 3:25 am
by macvirii
I had the same problem, actually my history1.db was only 1.023kb
My problem derived from tmpfs /temp/ full (it seems it was a Radarr update unsuccessful that filled the partition.
After deleting both backup and update (with winscp) , my SABnzb started working again.

Re: ERROR: SQL Command Failed, see log: OperationalError: database or disk is full

Posted: February 14th, 2018, 3:37 am
by sander
macvirii wrote: February 14th, 2018, 3:25 am I had the same problem, actually my history1.db was only 1.023kb
My problem derived from tmpfs /temp/ full (it seems it was a Radarr update unsuccessful that filled the partition.
After deleting both backup and update (with winscp) , my SABnzb started working again.
Yep, full temp is one of the reasons for sqlite to fail.

Thanks for your post.