Zigbee2mqtt not loading / config problems

Hi

so i have looked at Youtube.
I have looked at Google.
I have looked in the forums.
I can not find anything that helps me with my problem, so now i will try my luck here.

I have a clean install of Home assistant on a RPI4
only addons is bookstack, check home assistant, Mosquito, Node-Red, Samba, SSH & Web terminal, TasmoAdmin, Zigbee2mqtt.

i have a Sonoff USB dongle plus that i flashed after instructions from digiblur DIY’s video.

my problem is that when i try to configure zigbee2mqtt from the addon configuration page it seems to not save it correctly,
if i check the configuration.yaml via samba in the config/zigbee2mqtt folder they are not the same.

also.
when starting the zigbee2mqtt web gui it says loading, please wait. (for ever).
under settings the settings do not match what is in the config files.

what am i doing wrong ?

Sharing your attempted configuration would help spot your problem.

config from the addon page!!

data_path: /config/zigbee2mqtt
external_converters: []
devices: devices.yaml
groups: groups.yaml
homeassistant: true
permit_join: false
mqtt:
  base_topic: zigbee2mqtt
serial:
  port: >-
    /dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_32015794c019ec11924e77e5f01c6278-if00-port0
advanced:
  log_level: warn
  pan_id: 6754
  channel: 13
  network_key:
    - 9
    - 3
    - 5
    - 11
    - 1
    - 15
    - 7
    - 13
    - 8
    - 2
    - 0
    - 6
    - 4
    - 13
    - 12
    - 10
  availability_blocklist: []
  availability_passlist: []
device_options: {}
blocklist: []
passlist: []
queue: {}
frontend:
  port: 8099
experimental: {}
availability: false
socat:
  enabled: false
  master: pty,raw,echo=0,link=/tmp/ttyZ2M,mode=777
  slave: tcp-listen:8485,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5
  options: '-d -d'
  log: false

config from the samba share
(it generates it’s own password and user)

{
  "external_converters": [],
  "devices": [
    "devices.yaml"
  ],
  "groups": [
    "groups.yaml"
  ],
  "homeassistant": true,
  "permit_join": false,
  "mqtt": {
    "base_topic": "zigbee2mqtt",
    "user": "addons",
    "password": "iT5kutieRohf7Oyo7Foh2yoht6lohco9poof6poCah2aqu5maaque7itheiv0eeb",
    "server": "mqtt://core-mosquitto:1883"
  },
  "serial": {
    "port": "/dev/serial/by-id/usb-ITead_Sonoff_Zigbee_3.0_USB_Dongle_Plus_32015794c019ec11924e77e5f01c6278-if00-port0"
  },
  "advanced": {
    "log_level": "warn",
    "pan_id": 6754,
    "channel": 13,
    "network_key": [
      9,
      3,
      5,
      11,
      1,
      15,
      7,
      13,
      8,
      2,
      0,
      6,
      4,
      13,
      12,
      10
    ],
    "availability_blocklist": [],
    "availability_passlist": []
  },
  "device_options": {},
  "blocklist": [],
  "passlist": [],
  "queue": {},
  "frontend": {
    "port": 8099
  },
  "experimental": {},
  "availability": false
}

i have a user in Home Assistant called mqtt-user

i have tried adding
server: mqtt://192.168.30.4:1883
user: mqtt-user
password: xxxxxxxx

but then i get errors in the main log

The only difference between your configuration and mine (apart from the network key and adaptor serial port) is that I have this:

mqtt:
  base_topic: zigbee2mqtt
  user: myuser
  password: mypassword

Try dropping the server and only specifying the user and password like I have. e.g.

data_path: /config/zigbee2mqtt
external_converters: []
devices: devices.yaml
groups: groups.yaml
homeassistant: true
permit_join: false
mqtt:
  base_topic: zigbee2mqtt
  user: mqtt-user
  password: xxxxxxxx
serial: ...etc

If that does not work, try quoting your username as it has a dash in it. 'mqtt-user'

Nope. Still complaints over server settings.

[s6-init] making user provided files available at /var/run/s6/etc...exited 0.
[s6-init] ensuring user provided files have correct perms...exited 0.
[fix-attrs.d] applying ownership & permissions fixes...
[fix-attrs.d] done.
[cont-init.d] executing container initialization scripts...
[cont-init.d] socat.sh: executing... 
[09:18:59] INFO: Socat not enabled, marking service as down
[cont-init.d] socat.sh: exited 0.
[cont-init.d] zigbee2mqtt.sh: executing... 
[09:19:00] INFO: MQTT available, fetching server detail ...
[09:19:00] INFO: MQTT server settings not configured, trying to auto-discovering ...
[09:19:01] INFO: Configuring 'mqtt://core-mosquitto:1883' mqtt server
[09:19:01] WARNING: Data path /config/zigbee2mqtt not found
[09:19:02] INFO: Adjusting Zigbee2mqtt core yaml config with add-on quirks ...
[09:19:02] INFO: Adjusting Zigbee2mqtt core yaml config with add-on quirks ...
[cont-init.d] zigbee2mqtt.sh: exited 0.
[cont-init.d] done.
[services.d] starting services
[services.d] done.
[09:19:03] INFO: Handing over control to Zigbee2mqtt Core ...
> [email protected] start
> node index.js
Zigbee2MQTT:warn  2021-12-31 09:19:30: Using experimental new availability feature

I reinstalled mosquito and z2m, No configuration done exept user and password in both addons. Now user is mqttuser to make it simple.

I tried tid now

base_topic: zigbee2mqtt
  server: 'mqtt://core-mosquitto:1883'
  user: mqttuser
  password: XXXX

And got this

[09:30:42] INFO: Socat not enabled, marking service as down [cont-init.d] socat.sh: exited 0. [cont-init.d] zigbee2mqtt.sh: executing... [09:30:43] INFO: MQTT available, fetching server detail ... [09:30:44] INFO: Previous config file found, checking backup [09:30:44] INFO: Creating backup config in '/config/zigbee2mqtt/.configuration.yaml.bk' [09:30:44] INFO: Adjusting Zigbee2mqtt core yaml config with add-on quirks ... [cont-init.d] zigbee2mqtt.sh: exited 0. [cont-init.d] done. [services.d] starting services [services.d] done. [09:30:45] INFO: Handing over control to Zigbee2mqtt Core ...

A step in the right direktion. But it still loads for ever :-(. Guess i am going with ZHA :disappointed:

So !
i think i found the problem

i think this one is broken!
[ttps://github.com/Koenkk/zigbee2mqtt.io

when using this one it works

1 Like