Zigbee2mqtt to broker does not work

I recently started with homeassistant, falling amidst the zwavejs change and using two instances of HA I decided to move to mqtt versions of zwave and zigbee. I had it working at some stage but it stopped and couldn’t get it working whatever I tried. I had my old rp3 box revived this have it all working again, all updated to latest version and I restored a backup to my rpi 4… All is working except for zigbee2mqtt. I see same errors as before. Broker connects and disconnects and zigbee saying can’t connect to mqtt.

Zigbee2MQTT:warn 2021-03-06 11:34:29: permit_join set to true in configuration.yaml.
Zigbee2MQTT:warn 2021-03-06 11:34:29: Allowing new devices to join.
Zigbee2MQTT:warn 2021-03-06 11:34:29: Set permit_join to false once you joined all devices.
Zigbee2MQTT:info 2021-03-06 11:34:29: Zigbee: allowing new devices to join.
Zigbee2MQTT:info 2021-03-06 11:34:29: Started frontend on port 0.0.0.0:8099
Zigbee2MQTT:info 2021-03-06 11:34:29: Connecting to MQTT server at mqtt://core-mosquitto:1883
Zigbee2MQTT:debug 2021-03-06 11:34:29: Using MQTT login with username: addons
Zigbee2MQTT:error 2021-03-06 11:34:39: Not connected to MQTT server!
Zigbee2MQTT:error 2021-03-06 11:34:49: Not connected to MQTT server!

Where does the addons use comes from?? i created this user but no luck

on the broker
1615027504: Socket error on client , disconnecting.
1615027505: New connection from 172.30.33.5 on port 1883.
1615027505: Socket error on client , disconnecting.
1615027506: New connection from 172.30.33.5 on port 1883.
1615027506: Socket error on client , disconnecting

The broker log is full with these messages

ERROR (MainThread) [supervisor.services.modules.mqtt] There is already a MQTT service in use from core_mosquitto
ERROR (MainThread) [supervisor.api.ingress] Ingress error: 400, message=‘Invalid response status’, url=URL(‘http://172.30.33.3:8099/socket.io/?EIO=4&transport=websocket&sid=LKmPNl_qFcAMYUXRAAAA’)

In the supervisor log I see these errors the last one I did also have on the rpi3 however all mqtt stuff was working.

Another thing I see on the rpi4 is ERROR: Can’t setup Home Assistant service mqtt, after restarting the broker. If I do the same on the RPI3 just runs fine.

I am really out of options, a working system on an rpi3 so not a config issue, restored to an rpi4 where everything works except for zigbee2mqtt??? any suggestions or having similar problems with mqtt on this platform?

Same issue here. After updating Mosquitto Broker to 5.1.1

I’ve found an six month old snapshot and only restore the MQTT add-on to 5.1. Then manually configure the HA MQTT integration. It works again.

1 Like

Has there been any resolution to this issue? I am having the same problem… restoring to a previous install is not ideal for me as I would lose the last few months work (6 hours every day for weeks!)

OK I see Hydreliox recommended updating only the MQTT add on… to 5.1, good idea!