Vyos 1.5 Zigbee2MQTT container cannot open /dev/ttyACM0

Aloha,

Im trying to get a Zigbee2MQTT container running.

I used this guide.

My config in cli is:

set container name zigbee2mqtt allow-host-networks
set container name zigbee2mqtt cap-add 'net-bind-service'
set container name zigbee2mqtt cap-add 'net-raw'
set container name zigbee2mqtt cap-add 'sys-module'
set container name zigbee2mqtt image 'docker.io/koenkk/zigbee2mqtt:latest'
set container name zigbee2mqtt port admin-8080 destination '8080'
set container name zigbee2mqtt port admin-8080 listen-address '10.255.255.6'
set container name zigbee2mqtt port admin-8080 protocol 'tcp'
set container name zigbee2mqtt port admin-8080 source '8080'
set container name zigbee2mqtt restart 'on-failure'
set container name zigbee2mqtt volume conf destination '/app/data'
set container name zigbee2mqtt volume conf source '/config/zigbee2mqtt/'
set container name zigbee2mqtt volume work destination '/run/udev'
set container name zigbee2mqtt volume work source '/run/udev'

I added all these different capabilities, because I wasnt sure, what is needed.
From the guide, its needed to gave access to the USB devices whis is under:
/dev/ttyACM0

I added a configuration.yml in the config folder,
but it looks, thats still something is missing

the log says:

Using '/app/data' as data directory
Zigbee2MQTT:info  2023-12-03 18:01:57: Logging to console and directory: '/app/data/log/2023-12-03.18-01-56' filename: log.txt
Zigbee2MQTT:info  2023-12-03 18:01:57: Starting Zigbee2MQTT version 1.34.0 (commit #aae7312)
Zigbee2MQTT:info  2023-12-03 18:01:57: Starting zigbee-herdsman (0.25.0)
Zigbee2MQTT:error 2023-12-03 18:01:57: Error while starting zigbee-herdsman
Zigbee2MQTT:error 2023-12-03 18:01:57: Failed to start zigbee
Zigbee2MQTT:error 2023-12-03 18:01:57: Check https://www.zigbee2mqtt.io/guide/installation/20_zigbee2mqtt-fails-to-start.html for possible solutions
Zigbee2MQTT:error 2023-12-03 18:01:57: Exiting...
Zigbee2MQTT:error 2023-12-03 18:01:57: Error: Error while opening serialport 'Error: Error: No such file or directory, cannot open /dev/ttyACM0'
    at SerialPort.<anonymous> (/app/node_modules/zigbee-herdsman/src/adapter/deconz/driver/driver.ts:202:28)
    at SerialPort._error (/app/node_modules/@serialport/stream/dist/index.js:82:22)
    at /app/node_modules/@serialport/stream/dist/index.js:118:18

Im an old network guy, and learning everyday some more linus stuff.
Any ideas / hints, how to it could b possible to give the container access to that USB device?

Cheers
Marcel

Try to set the device:

vyos@r4# set container name c1 device MYDEVICE 
Possible completions:
   destination          Destination container device (Example: "/dev/x")
   source               Source device (Example: "/dev/x")

3 Likes

■■■■ yeah!
You made my day.
vyos is great.
It works.
Now I can get MQTT data from all remote side, which just my existing router.
Thanks a lot
Cheers
Marcel

3 Likes

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.