Author Topic: Worker Error: "Exec Database Error: SQL logic error or missing database(1)"  (Read 10071 times)

Achilles

  • Sr. Member
  • ****
  • Posts: 25
Problem:
worker took all jobs and failed them rapidly. Other workers don't have the problem. In the workerlog you see errors like this one:

Code: [Select]
Exec Database Error: SQL logic error or missing database(1)
SELECT job_id, subjob_id FROM assignment

Connecting to the qube mysql database with qube_readonly from worker host is possible.

Cause:
unkkown, maybe data corruption because of a forced shutdown.

Solution:
* uninstall all qube packages
* remove /var/spool/qube
* remove /usr/local/pfx
* install qube packages
* start qube worker

Enviroment:
Linux CentOS 5, Qube Worker 6.0-1

jburk

  • Administrator
  • *****
  • Posts: 493
Each worker maintains its own state in a local copy of an sqlite database.  It's named worker5.jnl, and is located in /var/spool/qube on linux and OSX, and it c:\programdata\pfx\qube in later versions of Windows.

it's likely that this is the corrupt database that's causing this error; the good news is that it's easy to fix.

Code: [Select]
$QBDIR/utils/upgrade_worker --reset
will produce output something like:

journal: /var/spool/qube/worker5.jnl
[Jan 4, 2011 13:50:54] jburk-17-mbpro : resetting the database.
removing journal: /var/spool/qube/worker5.jnl
Exec Database Error: no such table: tableversion(1)
SELECT version FROM tableversion
[Jan 4, 2011 13:50:54] jburk-17-mbpro : detecting current storage state...
[Jan 4, 2011 13:50:54] jburk-17-mbpro : constructing primary storage structure - version: 6
[Jan 4, 2011 13:50:55] jburk-17-mbpro : current storage version: 6