zwave-js-ui
zwave-js-ui copied to clipboard
Docker image upgrade results in unresolved ProtocolInfo under Interview
Checklist
- [ ] I am not using Home Assistant. Or: a developer has told me to come here.
- [x] I have checked the troubleshooting section and my problem is not described there.
- [x] I have read the changelog and my problem is not mentioned there.
Deploy method
Docker
Z-Wave JS UI version
zwave-js-ui: 10.3.1.d1f0205
ZwaveJS version
zwave-js: 15.1.0
Describe the bug
A picture is worth a thousand words, so here it is..
Essentially, each time I perform a docker compose to update the image, I have to re-interview all nodes again. Otherwsise, while everything updates fine, I only see ProtocolInfo and it spins under Interview for all nodes. The issue is resolved after some time when I manually select and re-interview all nodes all over again.
To Reproduce
Update docker container to new code upon release availability. Look at the Interview column.
Expected behavior
One should have to re-interview all nodes. Something appears to be unset in the initialization of a new docker instance version of zwave-js-ui.
Additional context
No response
Post the contents of your docker compose file. Are you mapping a persistent volume/directory to the store directory?
services:
zwave-js-ui:
image: 'zwavejs/zwave-js-ui:latest'
container_name: 'zwave-js-ui'
hostname: 'zwave-js-ui'
networks:
docker_bridge:
ipv4_address: '172.16.0.1'
tty: true
stop_signal: 'SIGINT'
environment:
- SESSION_SECRET='REDACTED'
- ZWAVEJS_EXTERNAL_CONFIG='/usr/src/app/store/.config-db'
- TZ=US/Eastern
volumes:
- /docker/zwave-js-ui/files:/usr/src/app/store
devices:
- /dev/serial/by-id/usb-Silicon_Labs_CP2102N_USB_to_UART_Bridge_Controller_d89512360a55ed11b62e91131d62bc44-if00-port0:/dev/zwave
ports:
- '8091:8091' # port for web interface
- '3000:3000' # port for Z-Wave JS websocket server
restart: 'unless-stopped'
networks:
docker_bridge:
external: true
That looks fine to me. Next step would be to provide driver debug logs demonstrating the problem. https://zwave-js.github.io/zwave-js-ui/#/troubleshooting/generating-logs?id=driver-logs
I see the same issue when I just modify my docker yaml and rebuild the instance. Nothing indicative in logs.
I still had an old environmental variable:
# - ZWAVEJS_EXTERNAL_CONFIG='/usr/src/app/store/.config-db'
So. I commented it. Restarted the container and at least saw the files updating with new timestamps. However, same behaviour... every device shows up with ProtocolInfo and a spinning status bar. It is not until I highlight all device and re-interview them that this goes away.
A docker image rebuild or an upgrade should not require re-interviewing every device!
I think the problem was the ZWAVEJS_EXTERNAL_CONFIG env var, that is not needed
Even after removing it.. I see the same issue when I restart the container. It simply wants to reinterview everything and Protocol spinning continues.
On Thu, May 22, 2025 at 05:10 Daniel Lando @.***> wrote:
robertsLando left a comment (zwave-js/zwave-js-ui#4209) https://github.com/zwave-js/zwave-js-ui/issues/4209#issuecomment-2900472612
I think the problem was the ZWAVEJS_EXTERNAL_CONFIG env var, that is not needed
— Reply to this email directly, view it on GitHub https://github.com/zwave-js/zwave-js-ui/issues/4209#issuecomment-2900472612, or unsubscribe https://github.com/notifications/unsubscribe-auth/AKAGRDE4BFN4VC2YP4UKC7327WIB7AVCNFSM6AAAAAB3ZEUS5WVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDSMBQGQ3TENRRGI . You are receiving this because you authored the thread.Message ID: @.***>
@polskikrol I checked your logs and yeah I noticed that them are tucked on that interview stage but I don't see any error apparently, need to ask @AlCalzone to give a look at them. Could you also try to upgrade to latest? I know many errors have been fixed in latest versions since first v15 release
Can you share the files that are mapped in from /docker/zwave-js-ui/files?
Does the container actually have write access to those files?
Upgraded a few days ago, so here are the updated versions from the docker container:
zwave-js-ui: 10.5.1.b5cf23c
zwave-js: 15.4.2
The following is my docker file:
services:
zwave-js-ui:
image: 'zwavejs/zwave-js-ui:latest'
container_name: 'zwave-js-ui'
hostname: 'zwave-js-ui'
networks:
docker_bridge:
ipv4_address: '172.16.0.1'
environment:
- SESSION_SECRET=REDACTED'
- TZ=US/Eastern
volumes:
- /docker/zwave-js-ui/files:/usr/src/app/store
devices:
- /dev/serial/by-id/usb-Silicon_Labs_CP2102N_USB_to_UART_Bridge_Controller_REDACTED-port0:/dev/zwave
ports:
- '8091:8091' # port for web interface
- '3000:3000' # port for Z-Wave JS websocket server
restart: 'unless-stopped'
privileged: false
networks:
docker_bridge:
external: true
Checking the filesystem, cache files (I presume) are updated:
-rw-r--r-- 1 root root 272778 May 23 08:25 dfeaaacd.values.jsonl
-rw-r--r-- 1 root root 1777845 May 23 08:25 dfeaaacd.metadata.jsonl
drwxr-xr-x 11 root root 4096 May 23 08:25 .
-rw-r--r-- 1 root root 66387 May 23 08:26 dfeaaacd.jsonl
drwxr-xr-x 2 root root 4096 May 23 08:28 dfeaaacd.values.jsonl.lock
drwxr-xr-x 2 root root 4096 May 23 08:28 dfeaaacd.metadata.jsonl.lock
drwxr-xr-x 2 root root 4096 May 23 08:28 dfeaaacd.jsonl.lock
And so are the config db files:
root@kurka:/docker/zwave-js-ui/files/.config-db# ls -la
total 52
drwxr-xr-x 3 root root 4096 May 21 22:41 .
drwxr-xr-x 11 root root 4096 May 23 08:28 ..
drwxr-xr-x 365 root root 12288 May 21 22:41 devices
-rw-r--r-- 1 root root 26436 May 21 22:41 manufacturers.json
-rw-r--r-- 1 root root 6 May 21 22:41 version
Default user does appear to have filesystem access:
root@kurka:/docker/zwave-js-ui/files/.config-db# docker exec -it zwave-js-ui sh
/usr/src/app # whoami
root
/usr/src/app # ls
dist node_modules package.json server snippets store
/usr/src/app # cd store
/usr/src/app/store # ls
backups dfeaaacd.jsonl.lock nodes.json
c7aad84d.jsonl dfeaaacd.metadata.jsonl sessions
c7aad84d.metadata.jsonl dfeaaacd.metadata.jsonl.lock settings.json
c7aad84d.values.jsonl dfeaaacd.values.jsonl snippets
config dfeaaacd.values.jsonl.lock users.json
dfeaaacd.jsonl logs
/usr/src/app/store # touch test.txt
/usr/src/app/store # rm test.txt
/usr/src/app/store # cd .config-db/
/usr/src/app/store/.config-db # touch test.txt
/usr/src/app/store/.config-db # rm test.txt
Out of curiosity, does zwave-js-ui docker support running as a non-root user (I am not doing this here, but have another server with more locked down docker instances where I have a regular user created on the host and pass the UID/GID to the container.)?
/usr/src/app/store # ls
backups dfeaaacd.jsonl.lock nodes.json
c7aad84d.jsonl dfeaaacd.metadata.jsonl sessions
c7aad84d.metadata.jsonl dfeaaacd.metadata.jsonl.lock settings.json
c7aad84d.values.jsonl dfeaaacd.values.jsonl snippets
config dfeaaacd.values.jsonl.lock users.json
dfeaaacd.jsonl logs
The container seems to contain two sets of jsonl files, one for home ID c7aad84d, one for dfeaaacd. The latter one can be found on your host system, the former ones aren't there - at least you didn't mention them above.
Which home ID is the correct one? You can check that by hovering the info icon in the top bar.
Apologies on the delay, as I was in the sticks hiking and camping as I usually to do escape technology for a bit.
Here is the home ID... home hex: 0xdfeaaacd
Any idea how I would come up with 2 different home IDs? Is it generated based upon a) zwave dongle or b) first created upon docker container run or c) other? If this should be cleaned up in some fashion, do let me know.
This may be the result of using the directly connected ZWAVE controller as secondary. On the latest code release, whenenever I restart the docker container or upgrade it, the ProtocolInfo error returns. I need to manually re-interview all nodes. Anyway to load this information from file? Anyway to code some logic to auto-perform a re-interview if this is triggered?
The issue is that devices in the ProtocolInfo state are 'not ready' in HomeAssistant. So I cant start to migrate old Vera automations to HomeAssistant, as things would completely break during a power outage (as the HomeAssistant instance would reboot and end up in this funky state).
Secondary controller support is not complete yet. This includes the issue you're mentioning where the data is not restored from cache, as well as some other cases where the behavior is not spec-compliant.
This does explain your issue though.
@polskikrol do you have any sleeping / battery powered devices or are these all mains-powered?
I have two sleeping, but always pingable as they are CR battery backup w/ USB powered main. So the battery is in theory always 100%. Then I have two or three that are either pre-added and not installed yet, or just dead due to water ingress and I have been lazy to remove from Zwave network.
This issue is stale because it has been open 90 days with no activity. Remove the stale label or comment or this will be closed in 5 days. To ignore this issue entirely you can add the no-stale label
This issue can be closed as it was fixed via https://github.com/zwave-js/zwave-js/pull/7994.