12-31-2020, 07:48 PM
The session id is a static value in cfg_system and thus would always be returned but what I think is happening is the sql query is failing because the database is busy processing an update. It's due to an order of execution issue in worker.php. See the code snippet below.
The fix would be to start watchdog after the update query for "worker: ready".
If you cold revert your change to watchdog and test this fix I'd be interested in knowing the results.
-Tim
Code:
// Start watchdog monitor
sysCmd('/var/www/command/watchdog.sh > /dev/null 2>&1 &');
workerLog('worker: Watchdog started');
//
workerLog('worker: Ready');
$result = sdbquery("UPDATE cfg_system SET value='1' WHERE param='wrkready'", $dbh);
//
//
// BEGIN WORKER JOB LOOP
//
The fix would be to start watchdog after the update query for "worker: ready".
If you cold revert your change to watchdog and test this fix I'd be interested in knowing the results.
-Tim