Z2m restarts for no reason.
What happened?
Z2m restarts for no reason.
'Zigbee2MQTT server has exited unexpectedly' 'After 10s Z2m restarts!'
What did you expect to happen?
No restart.
How to reproduce it (minimal and precise)
You can't reproduce it. It happens every 4-24 hours.
Zigbee2MQTT version
2.1.3
Adapter firmware version
20250321
Adapter
Zstack, SLZB-06P7
Setup
PC, Windows 11
Debug log
I don't see any startup or shutdown sequence in that log file. Do you have the one with it?
So, the first log should have the error that caused the restart, but it doesn't appear to. That would suggest a pretty hard crash of the nodejs process. Can you check system logs, see if you can spot something around that time? If you aren't already on it, I suggest you try updating to latest LTS version of nodejs too (v22): https://nodejs.org/en/download
In my desperation, I updated the nodejs version a few days ago. You suspect a Windows or hardware problem? I will check the system log files. By the way, the last restart was a few minutes ago.
The last few lines of logging from Z2M before restart are likely only printed to the console, so you may have to catch it there so we can get more details (unless some system log can point to a failure of some kind).
In the Windows protocol there are only processor warnings. I have just ported the system to new hardware. I'm curious.
I'll take a look at the console. Thank you very.
I installed my system on a new PC. It ran for 1 day and 7 hours, then there was a restart from Z2M (17:47). The attached file is a copy directly from the console. I can't see any error. How is this possible?
I don't see any restart at 17:47 in that log.
Your mentioned before 17:37:55 and now 17:47, the two are close enough to make me wonder, can you put this crash around the same time of day every time? Or maybe it's about the runtime duration, 1d8h, 1d7h?
If a different machine is exhibiting the same behavior, you have a few avenues to explore:
- the two machines have similar-enough configurations that both are affected by the same bug
- problem with the adapter that's causing a crash
- problem with a device on the network that's causing a crash (some kind of bad behavior, spamming, corrupted data...)
If using USB mode:
- check the power saving settings of the COM port (in Device Manager), make sure the OS cannot turn it off to "save power"
- update the drivers: https://www.silabs.com/developer-tools/usb-to-uart-bridge-vcp-drivers?tab=downloads
I use the SLZB-06P7 in PoE network mode. Previously I had a Conbee2, which did not cause these problems. The new hardware is quite different from the old one and has been completely reinstalled.
I had a restart of Z2M today at 17:45. This time, both before the restart (Log1) and after the restart (Log2) there are various error messages in the log, which I unfortunately can't do anything with.
These errors should not crash Z2M, it's mostly just failed deliveries. (0x3410f4fffe61e419 is causing most of them, it's failing poll check-in.)
We're still missing the one that does unfortunately.
What's the "core firmware" version on your adapter?
First of all, thank you again for the support. I've had daily reboots for some time now, which is exhausting and annoying. Core v2.8.2.dev3 is currently installed and Zigbee is 20240716. But I've tried older versions, for example Core V 2.7.1.
Could you try connecting the SLZB in USB mode instead of network? This will rule out any network related problems.
I can implement this tomorrow with little effort.
Make sure to follow the USB-related points here beforehand.
I have now connected the SLZB-06P7 via USB. I turned off the Ethernet connection. Installed the recommended Silabs driver and turned off all power-saving features on USB. After 8 hours, at 1:59 a.m., Z2M made a restart again.
Can you check in right click on This PC > Manage > System Tools > Event Viewer > Windows Logs:
SystemlogsApplicationlogs
for each: Filter Current Logs > 1:54 AM to 2:04AM (5min before/after) > Save Filtered Log File As.
In the time from 1:54 to 2:04 there are no (!) Entries in the logs. Neither in the application log nor in the system log.
Can you use the console to start Z2M and disable the watchdog so that Z2M doesn't restart automatically on next crash? Maybe we can finally get the actual error in the console when it stops...
Please don't laugh, but Z2M is started by Homeseer for me. How do I get into the console, how do I launch it from there, and how do I turn off watchdog?