just did today the apt-upgrade and I saw that Mosquitto was upgraded to the version 1.5.
However, MQTT stopped working. Looking at the mosquitto.log it was the following information:
1527548294: mosquitto version 1.5 starting
1527548294: Config loaded from /etc/mosquitto/mosquitto.conf.
1527548294: Opening ipv4 listen socket on port 1883.
1527548294: Opening ipv4 listen socket on port 1883.
1527548294: Error: Address already in use
I tried to stop the service, rebooted the raspberry pi, but it didn’t work.
After commenting the lines, I could see that the connection from the devices to mosquitto were done, but MQTT is not listening to the commands, nothing is working…
I did that, # listener 1883.0.0.0 (just typed wrong).
When I take out the comment the devices doesn’t connect.
Looking at the log, I can see that the devices are connecting but mqtt is not listening to the port 13
1527624926: New connection from 192.168.0.18 on port 1883.
1527624926: New client connected from 192.168.0.18 as DVES_A5E292 (c1, k15, u’openhabian’).
1527624953: New connection from 192.168.0.16 on port 1883.
1527624953: New client connected from 192.168.0.16 as DVES_0741B21 (c1, k15, u’openhabian’).
1527624968: New connection from 192.168.0.21 on port 1883.
1527624968: New client connected from 192.168.0.21 as DVES_A7A901 (c1, k15, u’openhabian’).
1527625003: New connection from 192.168.0.22 on port 1883.
1527625003: New client connected from 192.168.0.22 as DVES_A74C9F (c1, k15, u’openhabian’).
1527625009: New connection from 127.0.0.1 on port 1883.
1527625009: New client connected from 127.0.0.1 as openHAB2 (c1, k60, u’openhabian’).
1527625461: Client openHAB2 disconnected.
1527625545: Client DVES_0741B21 has exceeded timeout, disconnecting.
1527625545: Socket error on client DVES_0741B21, disconnecting.
1527625549: New connection from 192.168.0.16 on port 1883.
1527625549: New client connected from 192.168.0.16 as DVES_0741B21 (c1, k15, u’openhabian’).
yeah. i forgot to tell you to use sudo
(I always sudo su first :))
so… the Mosquitto MQTT Broker is up and running and listening to 1833.
You also have 1 client connected
Try to debug the OH2 connection
see troubleshooting section on MQTT Binding (v1.11) Getting Started 101
So you used this or commented this out with # ?
I am struggling with the same issue
EDIT: I got the connection from my phone (Owntracks) by commenting out the following
#include_dir /etc/mosquitto/conf.d
in
/etc/mosquitto/mosquitto.conf
and mosquitto still reports to listen on port 1883 (I don’t have listen in the config above).
And openhab is obviously connecting:
New client connected from 127.0.0.1 as openHAB (c1, k60, u'mosquitto').
but I get no updates in OH
EDIT 2:
I restarted mqtt transport and mqtt binding from karaf.
It seemed to have solved the issue.
The root cause (using another config than before) is still unknown.