2018-11-15 18:41:34.034 [DEBUG] [inding.mqtt.internal.MqttItemBinding] - Publishing command OFF to cmnd/TheHouse/power
2018-11-15 18:41:37.607 [DEBUG] [inding.mqtt.internal.MqttItemBinding] - Publishing command ON to cmnd/TheHouse/power
2018-11-15 18:43:38.157 [DEBUG] [inding.mqtt.internal.MqttItemBinding] - Publishing command OFF to cmnd/TheHouse/power
2018-11-15 18:43:40.255 [DEBUG] [inding.mqtt.internal.MqttItemBinding] - Publishing command ON to cmnd/TheHouse/power
any suggestions on how I go about debugging please?
restart the OH2 service and check logs (both OH and Mosquitto) to see if there are any errors in establishing the connection between OH2 MQTTv1 binding and the Mosquitto Broker.
I assume that you are on Linux, so: /var/log/mosquitto.log by default (if I remember well).
You can change the destination in /etc/mosquitto/mosquitto.conf
Set connection_messages true in mosquitto.conf and restart the broker
well… then you need to enable it (it’s disabled by default on Win)
set in your C:\Program Files\mosquitto\mosquitto.conf (or wherever you installed the Broker)
If you used Program Files subdir, you need to run the exe as Admin to be able to write in that folder
1542314314: mosquitto version 1.5.3 starting
1542314314: Config loaded from C:\Program Files (x86)\mosquitto/mosquitto.conf.
1542314314: Opening ipv6 listen socket on port 1883.
1542314314: Opening ipv4 listen socket on port 1883.
1542314327: New connection from 192.168.1.14 on port 1883.
1542314334: New client connected from 192.168.1.14 as DiningLight1 (c1, k15, u’sonoff’).
1542314334: Will message specified (7 bytes) (r1, q1).
1542314334: tele/TheHouse/LWT
1542314334: Sending CONNACK to DiningLight1 (0, 0)
1542314334: Received PUBLISH from DiningLight1 (d0, q0, r1, m0, ‘tele/TheHouse/LWT’, … (6 bytes))
1542314334: Received PUBLISH from DiningLight1 (d0, q0, r0, m0, ‘cmnd/TheHouse/POWER’, … (0 bytes))
1542314357: Client DiningLight1 has exceeded timeout, disconnecting.
1542314357: Socket error on client DiningLight1, disconnecting.
1542314392: New connection from 192.168.1.14 on port 1883.
1542314392: New client connected from 192.168.1.14 as DiningLight1 (c1, k15, u’sonoff’).
1542314392: Will message specified (7 bytes) (r1, q1).
1542314392: tele/TheHouse/LWT
1542314392: Sending CONNACK to DiningLight1 (0, 0)
1542314415: Client DiningLight1 has exceeded timeout, disconnecting.
1542314415: Socket error on client DiningLight1, disconnecting.
1542314524: New connection from 192.168.1.14 on port 1883.
1542314524: Socket error on client , disconnecting.
1542314540: New connection from 192.168.1.14 on port 1883.
1542314540: New client connected from 192.168.1.14 as DiningLight1 (c1, k15, u’sonoff’).
1542314540: Will message specified (7 bytes) (r1, q1).
before i enable mosquito logging i couldn’t see any of my on/off commands in MQTT.fx, but after i made the changes i could.
then i realised my sonoff switch was connected to a wifi AP the other end of the house. Sonoff is now connected to the correct AP, and now all is working again.
Last night the wired connection to my powermax alarm stopped working…but after a couple or server reboots that started working again, with no change…
Last night windows did an update, not sure if its related