Skip to content

Upgrade to 0.11.0 fail to start with ZW0206 error #3984

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
liollury opened this issue Apr 12, 2025 · 5 comments
Open

Upgrade to 0.11.0 fail to start with ZW0206 error #3984

liollury opened this issue Apr 12, 2025 · 5 comments

Comments

@liollury
Copy link

Describe the issue you are experiencing

After upgrade to zwavejs 0.11.0, this error occurred. When downgrade to 0.10.0, it is fixed.
I use Razberry (maybe the oldest version, v1 I guess).

the addon fail with ZW0206 error and restart (log bellow).

I try restart host but not fix the problem. Only the home assistant partial backup with zwavejs addon v 0.10.0 fixed it.

What type of installation are you running?

Home Assistant OS

Which operating system are you running on?

Home Assistant Operating System

Which add-on are you reporting an issue with?

Z-Wave JS

What is the version of the add-on?

0.11.0

Steps to reproduce the issue

  1. With a raspberry pi 5 with a razberry v1
  2. upgrade from zwavejs 0.10.0 to 0.11.0
  3. try to run it...

System Health information

nothing

Anything in the Supervisor logs that might be useful for us?

Anything in the add-on logs that might be useful for us?

s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
cont-init: info: running /etc/cont-init.d/config.sh
[22:48:47] INFO: Both 'network_key' and 's0_legacy_key' are set and match. All ok.
[22:48:48] INFO: Soft-reset set to automatic
[22:48:48] INFO: Virtual Machine not detected, enabling soft-reset
cont-init: info: /etc/cont-init.d/config.sh exited 0
cont-init: info: running /etc/cont-init.d/structure.sh
cont-init: info: /etc/cont-init.d/structure.sh exited 0
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service legacy-services: starting
services-up: info: copying legacy longrun zwave_js (no readiness notification)
s6-rc: info: service legacy-services successfully started
[22:48:48] INFO: Successfully send discovery information to Home Assistant.
2025-04-12T20:48:49.501Z DRIVER   ███████╗        ██╗    ██╗  █████╗  ██╗   ██╗ ███████╗          ██╗ ███████╗
                                  ╚══███╔╝        ██║    ██║ ██╔══██╗ ██║   ██║ ██╔════╝          ██║ ██╔════╝
                                    ███╔╝  █████╗ ██║ █╗ ██║ ███████║ ██║   ██║ █████╗            ██║ ███████╗
                                   ███╔╝   ╚════╝ ██║███╗██║ ██╔══██║ ╚██╗ ██╔╝ ██╔══╝       ██   ██║ ╚════██║
                                  ███████╗        ╚███╔███╔╝ ██║  ██║  ╚████╔╝  ███████╗     ╚█████╔╝ ███████║
                                  ╚══════╝         ╚══╝╚══╝  ╚═╝  ╚═╝   ╚═══╝   ╚══════╝      ╚════╝  ╚══════╝
2025-04-12T20:48:49.503Z DRIVER   version 15.0.5
2025-04-12T20:48:49.503Z DRIVER   
2025-04-12T20:48:50.525Z CONFIG   version 15.0.4
2025-04-12T20:48:50.934Z CNTRLR   querying Serial API capabilities...
2025-04-12T20:48:51.085Z CNTRLR   received API capabilities:
                                    firmware version:    5.0
                                    manufacturer ID:     0x0147
                                    product type:        0x0400
                                    product ID:          0x01
                                    supported functions: 
                                    · GetSerialApiInitData (0x02)
                                    · SetApplicationNodeInformation (0x03)
                                    · ApplicationCommand (0x04)
                                    · GetControllerCapabilities (0x05)
                                    · SetSerialApiTimeouts (0x06)
                                    · GetSerialApiCapabilities (0x07)
                                    · SoftReset (0x08)
                                    · GetProtocolVersion (0x09)
                                    · SerialAPIStarted (0x0a)
                                    · SetRFReceiveMode (0x10)
                                    · UNKNOWN_FUNC_SET_SLEEP_MODE (0x11)
                                    · SendNodeInformation (0x12)
                                    · SendData (0x13)
                                    · SendDataMulticast (0x14)
                                    · GetControllerVersion (0x15)
                                    · SendDataAbort (0x16)
                                    · FUNC_ID_ZW_R_F_POWER_LEVEL_SET (0x17)
                                    · UNKNOWN_FUNC_SEND_DATA_META (0x18)
                                    · FUNC_ID_ZW_GET_RANDOM (0x1c)
                                    · GetControllerId (0x20)
                                    · UNKNOWN_FUNC_MEMORY_GET_BYTE (0x21)
                                    · UNKNOWN_FUNC_MEMORY_PUT_BYTE (0x22)
                                    · UNKNOWN_FUNC_MEMORY_GET_BUFFER (0x23)
                                    · UNKNOWN_FUNC_MEMORY_PUT_BUFFER (0x24)
                                    · EnterBootloader (0x27)
                                    · UNKNOWN_FUNC_UNKNOWN_0x28 (0x28)
                                    · GetNVMId (0x29)
                                    · ExtNVMReadLongBuffer (0x2a)
                                    · ExtNVMWriteLongBuffer (0x2b)
                                    · ExtNVMReadLongByte (0x2c)
                                    · ExtExtWriteLongByte (0x2d)
                                    · GetNodeProtocolInfo (0x41)
                                    · HardReset (0x42)
                                    · FUNC_ID_ZW_REPLICATION_COMMAND_COMPLETE (0x44)
                                    · FUNC_ID_ZW_REPLICATION_SEND_DATA (0x45)
                                    · AssignReturnRoute (0x46)
                                    · DeleteReturnRoute (0x47)
                                    · RequestNodeNeighborUpdate (0x48)
                                    · ApplicationUpdateRequest (0x49)
                                    · AddNodeToNetwork (0x4a)
                                    · RemoveNodeFromNetwork (0x4b)
                                    · AddControllerAndAssignPrimary (0x4c)
                                    · AddPrimaryController (0x4d)
                                    · SetLearnMode (0x50)
                                    · AssignSUCReturnRoute (0x51)
                                    · RequestNetworkUpdate (0x53)
                                    · SetSUCNodeId (0x54)
                                    · DeleteSUCReturnRoute (0x55)
                                    · GetSUCNodeId (0x56)
                                    · SendSUCNodeId (0x57)
                                    · ExploreRequestInclusion (0x5e)
                                    · RequestNodeInfo (0x60)
                                    · RemoveFailedNode (0x61)
                                    · IsFailedNode (0x62)
                                    · ReplaceFailedNode (0x63)
                                    · UNKNOWN_FUNC_UNKNOWN_0x66 (0x66)
                                    · UNKNOWN_FUNC_UNKNOWN_0x67 (0x67)
                                    · FirmwareUpdateNVM (0x78)
                                    · GetRoutingInfo (0x80)
                                    · LockUnlockLastRoute (0x90)
                                    · GetPriorityRoute (0x92)
                                    · SetPriorityRoute (0x93)
                                    · UNKNOWN_FUNC_UNKNOWN_0x98 (0x98)
                                    · undefined (0xb4)
                                    · EnableWatchdog500 (0xb6)
                                    · DisableWatchdog500 (0xb7)
                                    · KickWatchdog500 (0xb8)
                                    · UNKNOWN_FUNC_UNKNOWN_0xB9 (0xb9)
                                    · UNKNOWN_FUNC_RF_POWERLEVEL_GET (0xba)
                                    · GetLibrary (0xbd)
                                    · SendTestFrame (0xbe)
                                    · GetProtocolStatus (0xbf)
                                    · StartWatchdog (0xd2)
                                    · StopWatchdog (0xd3)
                                    · SetMaximumRoutingAttempts (0xd4)
                                    · undefined (0xef)
                                    · Proprietary_F2 (0xf2)
                                    · Proprietary_F4 (0xf4)
2025-04-12T20:48:51.086Z CNTRLR   querying additional controller information...
2025-04-12T20:48:51.151Z CNTRLR   received additional controller information:
                                    Z-Wave API version:         5 (legacy)
                                    Z-Wave chip type:           ZW050x
                                    node type                   Controller
                                    controller role:            primary
                                    controller is the SIS:      true
                                    controller supports timers: false
                                    Z-Wave Classic nodes:       1, 8, 9, 11, 19, 20, 27, 28, 32, 40, 46, 47, 50,
                                   55, 56, 60, 62, 82, 84, 85, 89, 91
2025-04-12T20:48:51.152Z CNTRLR   querying version info...
2025-04-12T20:48:51.160Z CNTRLR   received version info:
                                    controller type: Static Controller
                                    library version: Z-Wave 3.99
2025-04-12T20:48:51.161Z CNTRLR   querying protocol version info...
2025-04-12T20:48:51.165Z CNTRLR   received protocol version info:
                                    protocol type:             Z-Wave
                                    protocol version:          3.99.0
2025-04-12T20:48:51.166Z CNTRLR   querying controller capabilities...
2025-04-12T20:48:51.171Z CNTRLR   received controller capabilities:
                                    controller role:      Primary
                                    is the SUC:           true
                                    started this network: true
                                    SIS is present:       false
                                    was real primary:     true
2025-04-12T20:48:51.172Z CNTRLR   supported Z-Wave features: 
2025-04-12T20:48:51.173Z CNTRLR   Performing soft reset...
2025-04-12T20:48:51.177Z CNTRLR   Waiting for the controller to reconnect...
2025-04-12T20:48:52.678Z CNTRLR   Waiting for the Serial API to start...
2025-04-12T20:48:57.680Z CNTRLR   Did not receive notification that Serial API has started, checking if it respo
                                  nds...
2025-04-12T20:48:57.687Z CNTRLR   Serial API responded
2025-04-12T20:48:57.688Z CNTRLR   querying controller IDs...
2025-04-12T20:48:57.693Z CNTRLR   Serial API restarted unexpectedly.
2025-04-12T20:48:57.693Z CNTRLR   Currently active command will be retried...
ZWaveError: The Serial API restarted unexpectedly (ZW0206)
    at Driver.handleSerialAPIStartedUnexpectedly (file:///usr/src/node_modules/zwave-js/src/lib/driver/Driver.ts:5007:7)
    at Driver.handleRequest (file:///usr/src/node_modules/zwave-js/src/lib/driver/Driver.ts:5569:19)
    at Driver.handleUnsolicitedMessage (file:///usr/src/node_modules/zwave-js/src/lib/driver/Driver.ts:4957:16)
    at Driver.serialport_onData (file:///usr/src/node_modules/zwave-js/src/lib/driver/Driver.ts:3989:14)
    at runNextTicks (node:internal/process/task_queues:65:5)
    at processImmediate (node:internal/timers:459:9)
[20:48:57] WARNING: Halt add-on
s6-rc: info: service legacy-services: stopping
s6-rc: info: service legacy-services successfully stopped
s6-rc: info: service legacy-cont-init: stopping
s6-rc: info: service legacy-cont-init successfully stopped
s6-rc: info: service fix-attrs: stopping
s6-rc: info: service fix-attrs successfully stopped
s6-rc: info: service s6rc-oneshot-runner: stopping
s6-rc: info: service s6rc-oneshot-runner successfully stopped
s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
cont-init: info: running /etc/cont-init.d/config.sh
[22:49:28] INFO: Both 'network_key' and 's0_legacy_key' are set and match. All ok.
[22:49:28] INFO: Soft-reset set to automatic
[22:49:28] INFO: Virtual Machine not detected, enabling soft-reset
cont-init: info: /etc/cont-init.d/config.sh exited 0
cont-init: info: running /etc/cont-init.d/structure.sh
cont-init: info: /etc/cont-init.d/structure.sh exited 0
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service legacy-services: starting
services-up: info: copying legacy longrun zwave_js (no readiness notification)
s6-rc: info: service legacy-services successfully started
[22:49:28] INFO: Successfully send discovery information to Home Assistant.

Additional information

No response

@liollury liollury changed the title Upgrade to 0.11.0 fail to start Upgrade to 0.11.0 fail to start with ZW0206 error Apr 12, 2025
@AlCalzone
Copy link
Contributor

Try disabling soft-reset in the addon options.

@liollury
Copy link
Author

Hmm, that seems to fix it. It's magic, this option already existed in version 0.10.0. Can you explain me what it is and why it fixes my problem?

@AlCalzone
Copy link
Contributor

Can you explain me what it is and why it fixes my problem?

I'm not 100% sure because your Z-Wave log is not on debug level, but it looks like this is the case:

  • Z-Wave JS restarts the stick
  • The stick takes a while to reboot
  • Z-Wave JS starts polling the stick to see if it restarted already, because the restart notification is not received within 5s
  • the stick responds, Z-Wave JS considers the restart to be complete
  • immediately after, the restart notification is received. Z-Wave JS considers this an unexpected restart, failing the current command.

TL;DR: An odd timing issue

@liollury
Copy link
Author

Thanks @AlCalzone.
Do you want me to open a ticket on the zwavejs repository ?

@AlCalzone
Copy link
Contributor

That would be good. I have one of those, so I might even be able to reproduce it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants