#Zigbee2MQTT "watchdog" not working (TubesZB). [SOLVED!]

1 messages ยท Page 1 of 1 (latest)

coarse tusk
#

So, this morning I noted that Zigbee2MQTT was stopped. I checked the log and found that at 3:30am there were a series of errors:

[2025-01-08 03:29:54] error:     zh:zstack:znp: Socket error Error: connect EHOSTUNREACH 192.168.77.234:6638
[2025-01-08 03:29:54] error:     z2m: Error while starting zigbee-herdsman
[2025-01-08 03:29:54] error:     z2m: Failed to start zigbee-herdsman
[2025-01-08 03:29:54] error:     z2m: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start_crashes-runtime.html for possible solutions
[2025-01-08 03:29:54] error:     z2m: Exiting...
[2025-01-08 03:29:54] error:     z2m: Error: Error while opening socket
    at Socket.<anonymous> (/app/node_modules/.pnpm/zigbee-herdsman@3.2.1/node_modules/zigbee-herdsman/src/adapter/z-stack/znp/znp.ts:158:24)
    at Socket.emit (node:events:530:35)
    at emitErrorNT (node:internal/streams/destroy:170:8)
    at emitErrorCloseNT (node:internal/streams/destroy:129:3)
    at processTicksAndRejections (node:internal/process/task_queues:90:21)
[03:29:54] INFO: Preparing to start...
[03:29:54] INFO: Socat not enabled
[03:29:54] INFO: Starting Zigbee2MQTT...
Starting Zigbee2MQTT without watchdog.

These events repeat in the log six times. So, I then clicked the "start" button for the add-on and the service started right up. ๐Ÿค”

The weird thing is this repeating part:

[08:10:30] INFO: Preparing to start...
[08:10:30] INFO: Socat not enabled
[08:10:30] INFO: Starting Zigbee2MQTT...
Starting Zigbee2MQTT without watchdog.

Starting without Watchdog..? ๐Ÿคทโ€โ™‚๏ธ

As you can see in the screen shot, I do have the "watchdog" switch turned on.

#

[UPDATE] So I wrote this up this morning but hadn't sent it yet as I was still looking into it. I then discovered there are essentially two watchdog functions for Zigbee2MQTT!

  • One is for the add-on itself (the one shown in the original screen shot)
  • One is a separate watchdog function that causes Zigbee2MQTT to try to reconnect the dongle
#

The add-on watchdog was enable, but the application watchdog was not enabled.

#

To enable the application watchdog, You have to go to "configuration" then click the button named Show unused optional configuration options shown here:

#

it then changes to displ;ay like this with the word "watchdog" in the field:

#

you then have to select the field and type the word default like this:

#

then click save and click "restart" so zigbee2mqtt restarts. When it does the log should show:

#

In my case, since my router had an update applied overnight at 3:30am, it made it so the TubesZB was unreachable for about 5 minutes. Since I didn't have this "internal" watchdog setup, when the TubesZB wasn't able to be reached after 6 attempts, it gave up and stopped!

#

So, by adding this, I hope that in the future the Zigbee2MQTT will continue to try over and over to reconnect to the dongle until it comes back up. ๐Ÿ‘๐Ÿ™‚

#

Zigbee2MQTT "watchdog" not working (TubesZB). [SOLVED!]

vital ridge
#

LordOfLevels you ROCK!! I've been having the exact same problem WITHOUT finding a fix. I added the default and rebooted. It took a while to find my coordinator but it is now up and running. Now I can finally add my MQTT devices to my dashboards. Thanks so much for this YOU MADE MY DAY!!!

coarse tusk
#

For what it's worth, I haven't had the Zigbee2MQTT stop working since I've applied these changes ๐Ÿ™‚