I have been struggling with this all day and I’m really getting nowhere, although I’m understanding the problem, I just don’t know how to fix it.
I have found countless references and just about every time people talk about blowing out the system and starting again (uninstalling and reinstalling) and while I’ve done that with MQTT, I haven’t done it to HA itself.
I’m using Home Assistant in the Synology Package which is basically a HassIO / HassOS with the add-on packages.
The only packages I’ve added on are File Editor, MQTT, and TasmoAdmin.
I have uninstalled and reinstalled MQTT numerous times (at least 6). I have had login as []
and also included users and passwords. I have tried it with anonymous set to True and False, always restarting MQTT, often restarting HA as well. The MQTT installation itself doesn’t seem to be the problem, all my devices are seeing each other and talking (I can view everything perfectly in MQTT Explorer).
What is not happening though, is Home Assistant can’t use MQTT.
MQTT logs:
[17:16:47] INFO: Setup mosquitto configuration
[17:16:47] WARNING: SSL not enabled - No valid certs found!
[17:16:47] INFO: No local user available
[17:16:47] INFO: Initialize Hass.io Add-on services
[17:16:47] INFO: Initialize Home Assistant discovery
[17:16:48] INFO: Start Mosquitto daemon
1591946208: mosquitto version 1.6.3 starting
1591946208: Config loaded from /etc/mosquitto.conf.
1591946208: Loading plugin: /usr/share/mosquitto/auth-plug.so
1591946208: |-- *** auth-plug: startup
1591946208: ├── Username/password checking enabled.
1591946208: ├── TLS-PSK checking enabled.
1591946208: └── Extended authentication not enabled.
1591946208: Opening ipv4 listen socket on port 1883.
1591946208: Opening ipv6 listen socket on port 1883.
1591946208: Opening websockets listen socket on port 1884.
1591946208: Warning: Mosquitto should not be run as root/administrator.
1591946208: New connection from 172.30.32.1 on port 1883.
[INFO] found madmqtt on Home Assistant
1591946209: New client connected from 172.30.32.1 as mqtt-explorer-61cfc303 (p2, c1, k60, u'madmqtt').
1591946213: New connection from 172.30.32.1 on port 1883.
1591946213: New client connected from 172.30.32.1 as DVES_428AAA (p2, c1, k30, u'madmqtt').
1591946213: New connection from 172.30.32.1 on port 1883.
1591946213: New client connected from 172.30.32.1 as DVES_CA6F7B (p2, c1, k30, u'madmqtt').
1591946230: New connection from 172.30.32.1 on port 1883.
[WARN] Not found homeassistant on local database
1591946230: Socket error on client <unknown>, disconnecting.
1591946350: New connection from 172.30.32.1 on port 1883.
1591946350: Socket error on client <unknown>, disconnecting.
1591946470: New connection from 172.30.32.1 on port 1883.
1591946470: Socket error on client <unknown>, disconnecting.
1591946507: New connection from 172.30.32.1 on port 1883.
1591946507: Socket error on client <unknown>, disconnecting.
1591946508: New connection from 172.30.32.1 on port 1883.
1591946508: Socket error on client <unknown>, disconnecting.
1591946510: New connection from 172.30.32.1 on port 1883.
1591946511: Socket error on client <unknown>, disconnecting.
1591946515: New connection from 172.30.32.1 on port 1883.
1591946515: Socket error on client <unknown>, disconnecting.
1591946523: New connection from 172.30.32.1 on port 1883.
1591946523: Socket error on client <unknown>, disconnecting.
1591946539: New connection from 172.30.32.1 on port 1883.
[WARN] Not found homeassistant on local database
1591946539: Socket error on client <unknown>, disconnecting.
As can be seen, other things are interacting with the broker, just not HA.
Developer Tools Logs
2020-06-12 17:21:47 ERROR (Thread-5) [homeassistant.components.mqtt] Unable to connect to the MQTT broker: Connection Refused: not authorised.
2020-06-12 17:21:47 WARNING (Thread-5) [homeassistant.components.mqtt] Disconnected from MQTT server (5)
2020-06-12 17:21:48 ERROR (Thread-5) [homeassistant.components.mqtt] Unable to connect to the MQTT broker: Connection Refused: not authorised.
2020-06-12 17:21:48 WARNING (Thread-5) [homeassistant.components.mqtt] Disconnected from MQTT server (5)
2020-06-12 17:21:51 ERROR (Thread-5) [homeassistant.components.mqtt] Unable to connect to the MQTT broker: Connection Refused: not authorised.
2020-06-12 17:21:51 WARNING (Thread-5) [homeassistant.components.mqtt] Disconnected from MQTT server (5)
configuration.yaml
is basically blank, and nothing to do with MQTT
# Configure a default setup of Home Assistant (frontend, api, etc)
default_config:
# Text to speech
tts:
- platform: google_translate
# All these files are empty
group: !include groups.yaml
automation: !include automations.yaml
script: !include scripts.yaml
scene: !include scenes.yaml
switch:
- platform: orvibo
switches:
- host: 192.168.1.82
mac: ac:cf:23:****
name: "Room1"
- host: 192.168.1.81
mac: ac:cf:23:24***
name: "Room2"
I’m drawing a blank, any help appreciated
edit: this is my MQTT config from the Supervisor > MQTT > Configuration
logins: []
anonymous: true
customize:
active: false
folder: mosquitto
certfile: fullchain.pem
keyfile: privkey.pem
require_certificate: false
As mentioned, I have tried this with logins provided (for madmqtt
and others) and with anonymous true and false