Open ZWave won't start!

Many times, when I have to restart my HA system (hassio on an Intel NUC, Debian 9 stretch, Aeotec zwave stick) ZWave doesn’t start.

I have about 50 devices. Now they’re all gone.
I need help! Please?

My ozw-log file after a start and manual stop looks like this:
2018-11-27 18:19:32.311 Always, OpenZwave Version 1.4.3254 Starting Up
2018-11-27 18:19:35.493 Info, Setting Up Provided Network Key for Secure Communications
2018-11-27 18:19:35.493 Warning, Failed - Network Key Not Set
2018-11-27 18:19:35.493 Info, mgr, Added driver for controller /dev/ttyACM0
2018-11-27 18:19:35.493 Info, Opening controller /dev/ttyACM0
2018-11-27 18:19:35.493 Info, Trying to open serial port /dev/ttyACM0 (attempt 1)
2018-11-27 18:19:35.493 Info, Serial port /dev/ttyACM0 opened (attempt 1)
2018-11-27 18:19:35.494 Detail, contrlr, Queuing (Command) FUNC_ID_ZW_GET_VERSION: 0x01, 0x03, 0x00, 0x15, 0xe9
2018-11-27 18:19:35.494 Detail, contrlr, Queuing (Command) FUNC_ID_ZW_MEMORY_GET_ID: 0x01, 0x03, 0x00, 0x20, 0xdc
2018-11-27 18:19:35.494 Detail, contrlr, Queuing (Command) FUNC_ID_ZW_GET_CONTROLLER_CAPABILITIES: 0x01, 0x03, 0x00, 0x05, 0xf9
2018-11-27 18:19:35.494 Detail, contrlr, Queuing (Command) FUNC_ID_SERIAL_API_GET_CAPABILITIES: 0x01, 0x03, 0x00, 0x07, 0xfb
2018-11-27 18:19:35.494 Detail, contrlr, Queuing (Command) FUNC_ID_ZW_GET_SUC_NODE_ID: 0x01, 0x03, 0x00, 0x56, 0xaa
2018-11-27 18:19:35.494 Detail,
2018-11-27 18:19:35.494 Info, contrlr, Sending (Command) message (Callback ID=0x00, Expected Reply=0x15) - FUNC_ID_ZW_GET_VERSION: 0x01, 0x03, 0x00, 0x15, 0xe9
2018-11-27 18:19:36.494 Error, contrlr, ERROR: Dropping command, expected response not received after 1 attempt(s)
2018-11-27 18:19:36.494 Detail, contrlr, Removing current message
2018-11-27 18:19:36.494 Detail, contrlr, Notification: Notification - TimeOut
2018-11-27 18:19:36.497 Detail,
2018-11-27 18:19:36.497 Info, contrlr, Sending (Command) message (Callback ID=0x00, Expected Reply=0x20) - FUNC_ID_ZW_MEMORY_GET_ID: 0x01, 0x03, 0x00, 0x20, 0xdc
2018-11-27 18:19:37.499 Error, contrlr, ERROR: Dropping command, expected response not received after 1 attempt(s)
2018-11-27 18:19:37.500 Detail, contrlr, Removing current message
2018-11-27 18:19:37.500 Detail, contrlr, Notification: Notification - TimeOut
2018-11-27 18:19:37.500 Detail,
2018-11-27 18:19:37.500 Info, contrlr, Sending (Command) message (Callback ID=0x00, Expected Reply=0x05) - FUNC_ID_ZW_GET_CONTROLLER_CAPABILITIES: 0x01, 0x03, 0x00, 0x05, 0xf9
2018-11-27 18:19:38.502 Error, contrlr, ERROR: Dropping command, expected response not received after 1 attempt(s)
2018-11-27 18:19:38.502 Detail, contrlr, Removing current message
2018-11-27 18:19:38.502 Detail, contrlr, Notification: Notification - TimeOut
2018-11-27 18:19:38.503 Detail,
2018-11-27 18:19:38.503 Info, contrlr, Sending (Command) message (Callback ID=0x00, Expected Reply=0x07) - FUNC_ID_SERIAL_API_GET_CAPABILITIES: 0x01, 0x03, 0x00, 0x07, 0xfb
2018-11-27 18:19:39.504 Error, contrlr, ERROR: Dropping command, expected response not received after 1 attempt(s)
2018-11-27 18:19:39.504 Detail, contrlr, Removing current message
2018-11-27 18:19:39.504 Detail, contrlr, Notification: Notification - TimeOut
2018-11-27 18:19:39.504 Detail,
2018-11-27 18:19:39.504 Info, contrlr, Sending (Command) message (Callback ID=0x00, Expected Reply=0x56) - FUNC_ID_ZW_GET_SUC_NODE_ID: 0x01, 0x03, 0x00, 0x56, 0xaa
2018-11-27 18:19:40.504 Error, contrlr, ERROR: Dropping command, expected response not received after 1 attempt(s)
2018-11-27 18:19:40.504 Detail, contrlr, Removing current message
2018-11-27 18:19:40.504 Detail, contrlr, Notification: Notification - TimeOut
2018-11-27 18:24:58.772 Error, mgr, Manager::GetDriver failed - Home ID 0x00000000 is unknown
2018-11-27 18:24:58.772 Warning, Exception: Manager.cpp:373 - 100 - Invalid HomeId passed to GetDriver
2018-11-27 18:24:58.772 Info, mgr, Manager::WriteConfig failed - _homeId 0 not found
2018-11-27 18:24:59.775 Detail, Notification: DriverRemoved
2018-11-27 18:24:59.775 Always, ***************************************************************************
2018-11-27 18:24:59.776 Always, ********************* Cumulative Network Statistics *********************
2018-11-27 18:24:59.776 Always, *** General
2018-11-27 18:24:59.776 Always, Driver run time: . . . 0 days, 0 hours, 5 minutes
2018-11-27 18:24:59.776 Always, Frames processed: . . . . . . . . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, Total messages successfully received: . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, Total Messages successfully sent: . . . . . . . . . . . . 5
2018-11-27 18:24:59.776 Always, ACKs received from controller: . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, *** Errors
2018-11-27 18:24:59.776 Always, Unsolicited messages received while waiting for ACK: . . 0
2018-11-27 18:24:59.776 Always, Reads aborted due to timeouts: . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, Bad checksum errors: . . . . . . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, CANs received from controller: . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, NAKs received from controller: . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, Out of frame data flow errors: . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, Messages retransmitted: . . . . . . . . . . . . . . . . . 0
2018-11-27 18:24:59.776 Always, Messages dropped and not delivered: . . . . . . . . . . . 5
2018-11-27 18:24:59.776 Always, ***************************************************************************
2018-11-27 18:24:59.776 Warning, WARNING: Tried to write driver config with no home ID set
2018-11-27 18:25:01.779 Info, mgr, Driver for controller /dev/ttyACM0 removed

Your controller isn’t responding, are you using HASS.io?

Yes, I am
On an Intel i5 NUC, Debian 9 stretch, aeotec controller

You’ll need to find the proper tty interface your Zwave stick is connected to, I am not sure how to do that in HASS.io but I believe it’s on the docs page. Then update your config with the correct /dev/ttyACM0 or /dev/tty/AMA0

It’s on /dev/ttyACM0
It has been there the whole time, also when it worked. Could it be a faulty stick?

I have had the same thing and no amount "hassio ha restart"s would solve the problem . Had to power down my Raspberry Pi (hence power down the USB stick) to do a hard reboot. No idea why. Maybe the stick has to reboot???

I’ve just tried that. shutdown, unplugging, waiting, power up.
Now it seems to work a bit better. Althogh there are quite a few devices that can’t be found.

@helgemor - I have a similar setup and similar problems. Sometimes I have to restart HA twice before it triggers the OZW startup. today i upgraded to the latest version and zwave won’t start at all.

Regarding the stick, there are times when the device is there in /dev but the driver isn’t actually able to talk to the stick. This shows up with errors like you posted. The next time that this happens, look in the output of dmesg or in syslog for any additional information about the USB device disconnecting. If it has disconnected, you’ll have to remove it and reinsert it, and then you’ll have to restart HA.

You don’t need to restart the box itself - USB devices are hotplug, so removing and reinserting the stick will trigger udev to reattach the device.

When I restart HA, I pay attention to the OZW_Log.txt file, which should immediately start scrolling info about polling all of the devices in your network. If this doesn’t happen, OZW didn’t start, and I bounce HA a second time. I also run hourly backups of the HA config dir, particularly because OZW has no qualms about clobbering the zw*.xml files when the topology changes, and wreaking havoc on a running system.

I have the same problems with mine Intel Nuc. Hope that a solution comes soon because now I can do nothing with my z-wave stuff.

I know that this might happen if you perform a bad shutdown of the system. I caused this for my system when I took the power while it was running. I tried to reboot the system and change usb ports for the z-stick but with no success. The solution for me was to simply recreate the docker container for the openzwave and then it booted up just fine.