MQTT connecting to client but not sending or receiving messages

I recently added the Mosquitto MQTT to Hassio on a Raspberry Pi, but am having issues sending and receiving messages.

In the Mosquitto broker log it shows a new client is connecting:

[INFO] Setup mosquitto configuration
[WARN] SSL not enabled - No valid certs found!
[INFO] No local user available
[INFO] Initialize Hass.io Add-on services
[INFO] Initialize Home Assistant discovery
[INFO] Start Mosquitto daemon
1558466318: mosquitto version 1.5.6 starting
1558466318: Config loaded from /etc/mosquitto.conf.
1558466318: |-- *** auth-plug: startup
1558466318: Opening ipv4 listen socket on port 1883.
1558466318: Opening ipv6 listen socket on port 1883.
1558466318: Opening websockets listen socket on port 1884.
1558466318: Warning: Mosquitto should not be run as root/administrator.
1558466320: New connection from 172.30.32.1 on port 1883.
1558466321: Socket error on client <unknown>, disconnecting.
1558466321: New connection from 172.30.32.1 on port 1883.
[INFO] found homeassistant on local database
1558466322: New client connected from 172.30.32.1 as 00abb435-82ca-4beb-9642-590b277fbd45 (c1, k60, u'homeassistant').
1558466327: New connection from 192.168.86.210 on port 1883.
1558466327: New client connected from 192.168.86.210 as mqtt_58683912.95bce8 (c1, k60).
1558466337: New connection from 172.30.32.1 on port 1883.
1558466337: New client connected from 172.30.32.1 as mosqsub|56-core-ssh (c1, k60).
1558466353: New connection from 172.30.32.1 on port 1883.
1558466353: New client connected from 172.30.32.1 as mosqpub|57-core-ssh (c1, k60).
1558466353: Client mosqpub|57-core-ssh disconnected.

In terminal, I published an example message with debug enabled:

core-ssh:~# mosquitto_pub -h 192.168.86.210 -t home-assistant/switch/1/on -m "Switch is ON" -d
Client mosqpub|57-core-ssh sending CONNECT
Client mosqpub|57-core-ssh received CONNACK (0)
Client mosqpub|57-core-ssh sending PUBLISH (d0, q0, r0, m1, 'home-assistant/switch/1/on', ... (12 bytes))
Client mosqpub|57-core-ssh sending DISCONNECT

Also in the terminal I am subscribed to that topic with debug enabled:

core-ssh:~# mosquitto_sub -h 192.168.86.210 -v -t "home-assistant/#" -d
Client mosqsub|56-core-ssh sending CONNECT
Client mosqsub|56-core-ssh received CONNACK (0)
Client mosqsub|56-core-ssh sending SUBSCRIBE (Mid: 1, Topic: home-assistant/#, QoS: 0)
Client mosqsub|56-core-ssh received SUBACK
Subscribed (mid: 1): 128

According to the example here MQTT Testing, the message should appear on the bus. I haven’t been able to figure out why my setup isn’t working. Any help would be greatly appreciated, thank you.

Shaun

Hi,

I think I have the same issue! Did you find a solution? I have my questions and logs here