Page 1 of 1

Error: mainworker seems to have ended or hung unexpectedly

Posted: Friday 04 October 2024 19:09
by Robert28
Hi all,

since the latest beta release Domoticz crashes:

Code: Select all

2024-10-04 10:40:24.232  Error: mainworker seems to have ended or hung unexpectedly (last update 301.000000 seconds ago)
2024-10-04 10:40:24.235  Error: Domoticz(1644587) is exiting due to watchdog triggered...
2024-10-04 10:40:24.255  Error: Failed to start gdb, will use backtrace() for printing stack frame

2024-10-04 10:40:25.233  Status: Closing application!...
2024-10-04 10:40:25.233  Status: Stopping worker...
2024-10-04 10:40:25.233  Status: RxQueue: queue worker stopped...
2024-10-04 10:40:25.733  Status: WebServer(HTTP) stopped
2024-10-04 10:40:26.234  Status: WebServer(SSL) stopped
2024-10-04 10:40:26.237  Status: TCPServer: shared server stopped
2024-10-04 10:40:26.237  Status: Stopping all hardware...
2024-10-04 10:40:26.238  Status: Open Weather Map: Worker stopped...
2024-10-04 10:40:26.238  Status: Buienradar: Worker stopped...
2024-10-04 10:40:26.239  Status: Z-WaveJS-MQTT: Worker stopped...
2024-10-04 11:16:16.705  Status: Domoticz V2024.7 (build 16268) (c)2012-2024 GizMoCuz 
Anyone already a starting point where to look? :idea: :?:

Domoticz: V2024.7 (build 16268)
Platform is Fedora 40 x86_64

BR,
Robert

Re: Error: mainworker seems to have ended or hung unexpectedly

Posted: Friday 04 October 2024 19:19
by waltervl
Revert back to previous beta.....

And check in GitHub what the latest changes are and if they could have impact on your environment.

Re: Error: mainworker seems to have ended or hung unexpectedly

Posted: Sunday 06 October 2024 19:31
by Robert28
Hmmm... I did... no solution, also the latest August release crashes...Obviously related to a system update... :(

Re: Error: mainworker seems to have ended or hung unexpectedly

Posted: Sunday 06 October 2024 20:15
by waltervl
Or power supply issue, or sd card issue.

Re: Error: mainworker seems to have ended or hung unexpectedly

Posted: Sunday 06 October 2024 20:18
by Robert28
Domoticz is not running at a Raspberry Pi, but on a x86_64 system, so no SD card (HDD Smart is ok).

Re: Error: mainworker seems to have ended or hung unexpectedly

Posted: Tuesday 08 October 2024 16:47
by waltervl
Perhaps run Domoticz in a docker container. x86_64 is built on an Ubuntu environment ubuntu-latest (currently ubuntu-24.04) so there could be some mismatch with Fedora

Re: Error: mainworker seems to have ended or hung unexpectedly

Posted: Sunday 13 October 2024 19:54
by Robert28
Hmm, I not a big fan of containers...

At this moment I suspecting the rtl_433 receivers, I have two of those one for 433 MHz and one for 868 MHz, especially the 868 gives time outs, changing the receivers does also change these time outs... (so not hardware related)... no clue..

Re: Error: mainworker seems to have ended or hung unexpectedly

Posted: Monday 14 October 2024 18:59
by Robert28
Another step, it seems to occur after Domoticz get's (for some reason) no information from rtl_433, resets the device and than 5 minutes later the watchdog is triggered:

Code: Select all

2024-10-14 03:45:04.578  Error: Rx433MHz hardware (28) nothing received for more than 1 Hour!....
2024-10-14 03:45:05.578  Error: Restarting: Rx433MHz
2024-10-14 03:50:05.218  Error: mainworker seems to have ended or hung unexpectedly (last update 301.000000 seconds ago)
2024-10-14 03:50:05.223  Error: Domoticz(1491206) is exiting due to watchdog triggered...
2024-10-14 03:50:05.246  Error: Failed to start gdb, will use backtrace() for printing stack frame
2024-10-14 10:15:10.802  Error: Rx433MHz hardware (28) nothing received for more than 1 Hour!....
2024-10-14 10:15:11.802  Error: Restarting: Rx433MHz
2024-10-14 10:20:11.519  Error: mainworker seems to have ended or hung unexpectedly (last update 301.000000 seconds ago)
2024-10-14 10:20:11.526  Error: Failed to start gdb, will use backtrace() for printing stack frame
(Note: I have a script running that detect that Domoticz has crashed and restarts Domoticz automatically).

Anyone a suggestion?