Page 1 of 1

ZWave-JS-UI needs restart for domoticz to see the devices

Posted: Saturday 15 October 2022 11:57
by OlivierFR
Hi,
I have successfully switched from OZW to Zwave-JS-UI since a few months.
It works fine except in this scenario:
When Domoticz is restarted, the Zwave devices are not getting updated and the commands to ZWave devices are not working.

In the Domoticz log there is no entry from Zwave devices at all.
In order to get it work again, I need to restart the Zwave-JS-UI container.
Then in the Domoticz log I see all the discovery messages from MQTT and after this I see the values being updated regularly and the commands work again.

Is there a setting that allows Domoticz to communicate with the Zwave devices after a restart without having to restart the ZWave-JS-UI container (maybe in the ZWave-JS-UI settings, like MQTT retain ?).

Is anyone having the same issue?

Thanks.

Re: ZWave-JS-UI needs restart for domoticz to see the devices

Posted: Saturday 15 October 2022 13:00
by ksacca
Hi OliverFR,

Domoticz expects to receive the device configuration over mqtt when restarting. This is sent when you restart zwavejs (or if you save settings). That's why it starts to work. You can enable retained discovery messages in zwavejs ui, and domoticz will receive it from your broker on restart. With this option enabled, the configuration messages are permanently stored in your broker, and domoticz will receive them immediately when it connects over mqtt (so on restart, on enabling hardware, ...).
zwavejsui.JPG
zwavejsui.JPG (24.66 KiB) Viewed 1357 times

Re: ZWave-JS-UI needs restart for domoticz to see the devices

Posted: Sunday 16 October 2022 11:46
by OlivierFR
Great!
I tried and it works as expcted.

I followed the wiki which shows retained discovery to be off. I wasn't sure if it would have any negative effect to turn it on.

Thanks!

Re: ZWave-JS-UI needs restart for domoticz to see the devices

Posted: Sunday 18 December 2022 11:10
by solarboy
I had the same issue and was happy to find this solution. I also have another question; what is the easiest way to restart zwavejsUI when it's in a docker ? I can't see it listed as a "service" that I can restart.

Re: ZWave-JS-UI needs restart for domoticz to see the devices

Posted: Sunday 18 December 2022 21:34
by ksacca
A container is actually a virtual machine with it's own OS, so it is indeed not a service.
You can list all your active containers using:

Code: Select all

docker container ls
This will list all running containers. Find the name of your container and issue the following command to completely restart it.

Code: Select all

docker restart <container name>
You can also use this to see the name of your containers and the memory and cpu usage.

Code: Select all

docker stats
But what I actually is is Portainer. This is a visual interface to add and manage your containers.