Error: mainworker seems to have ended or hung unexpectedly

Please use template to report bugs and problems. Post here your questions when not sure where else to post
Only for bugs in the Domoticz application! other problems go in different subforums!

Moderators: leecollings, remb0

Forum rules
Before posting here, make sure you are on the latest Beta or Stable version.
If you have problems related to the web gui, clear your browser cache + appcache first.

Use the following template when posting here:

Version: xxxx
Platform: xxxx
Plugin/Hardware: xxxx
Description:
.....

If you are having problems with scripts/blockly, always post the script (in a spoiler or code tag) or screenshots of your blockly

If you are replying, please do not quote images/code from the first post

Please mark your topic as Solved when the problem is solved.
Post Reply
Robert28
Posts: 21
Joined: Friday 05 January 2018 20:09
Target OS: Linux
Domoticz version: 2024.4
Contact:

Error: mainworker seems to have ended or hung unexpectedly

Post 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
User avatar
waltervl
Posts: 5904
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

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

Post 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.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Robert28
Posts: 21
Joined: Friday 05 January 2018 20:09
Target OS: Linux
Domoticz version: 2024.4
Contact:

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

Post by Robert28 »

Hmmm... I did... no solution, also the latest August release crashes...Obviously related to a system update... :(
User avatar
waltervl
Posts: 5904
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

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

Post by waltervl »

Or power supply issue, or sd card issue.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Robert28
Posts: 21
Joined: Friday 05 January 2018 20:09
Target OS: Linux
Domoticz version: 2024.4
Contact:

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

Post by Robert28 »

Domoticz is not running at a Raspberry Pi, but on a x86_64 system, so no SD card (HDD Smart is ok).
User avatar
waltervl
Posts: 5904
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

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

Post 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
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Robert28
Posts: 21
Joined: Friday 05 January 2018 20:09
Target OS: Linux
Domoticz version: 2024.4
Contact:

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

Post 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..
Robert28
Posts: 21
Joined: Friday 05 January 2018 20:09
Target OS: Linux
Domoticz version: 2024.4
Contact:

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

Post 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?
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest