Mosquitto MQTT broker unable to connect to Home Assistant

Hi all,

I recently installed HA operating system onto a mini PC. I then went ahead and installed mosquitto broker add-on and started the program; green dot shown. It was automatically dectected and shown in settings, integrations however when I click configure and submit I receive a message ‘failed to connect’.

image

HA version as below,

  • Core 2023.11.1
  • Supervisor 2023.10.1
  • Operating System 11.1
  • Frontend 20231030.1

Mosquitto version: 6.3.1

Configuration YAML

logins: []
require_certificate: false
certfile: fullchain.pem
keyfile: privkey.pem
customize:
  active: false
  folder: mosquitto

Logfile

s6-rc: info: service s6rc-oneshot-runner: starting
s6-rc: info: service s6rc-oneshot-runner successfully started
s6-rc: info: service fix-attrs: starting
s6-rc: info: service fix-attrs successfully started
s6-rc: info: service legacy-cont-init: starting
cont-init: info: running /etc/cont-init.d/mosquitto.sh
[19:56:58] INFO: SSL is not enabled
cont-init: info: /etc/cont-init.d/mosquitto.sh exited 0
cont-init: info: running /etc/cont-init.d/nginx.sh
cont-init: info: /etc/cont-init.d/nginx.sh exited 0
s6-rc: info: service legacy-cont-init successfully started
s6-rc: info: service legacy-services: starting
services-up: info: copying legacy longrun mosquitto (no readiness notification)
services-up: info: copying legacy longrun nginx (no readiness notification)
[19:56:59] INFO: Starting NGINX for authentication handling...
s6-rc: info: service legacy-services successfully started
[19:56:59] INFO: Starting mosquitto MQTT broker...
2023-11-06 19:56:59: Warning: Mosquitto should not be run as root/administrator.
2023-11-06 19:56:59: mosquitto version 2.0.17 starting
2023-11-06 19:56:59: Config loaded from /etc/mosquitto/mosquitto.conf.
2023-11-06 19:56:59: Loading plugin: /usr/share/mosquitto/go-auth.so
2023-11-06 19:56:59:  ├── Username/password checking enabled.
2023-11-06 19:56:59:  ├── TLS-PSK checking enabled.
2023-11-06 19:56:59:  └── Extended authentication not enabled.
2023-11-06 19:56:59: Opening ipv4 listen socket on port 1883.
2023-11-06 19:56:59: Opening ipv6 listen socket on port 1883.
2023-11-06 19:56:59: Opening websockets listen socket on port 1884.
2023-11-06 19:56:59: mosquitto version 2.0.17 running
2023-11-06 19:56:59: New connection from 127.0.0.1:59444 on port 1883.
2023-11-06 19:56:59: Client <unknown> disconnected due to protocol error.
[19:57:00] INFO: Successfully send discovery information to Home Assistant.
[19:57:00] INFO: Successfully send service information to the Supervisor.

I wonder if the issue is something to do with this statement - ‘Client disconnected due to protocol error’?

I’ve looked through many other posts but not able to get to the bottom of this. Appreciate any advice.

thanks

1 Like