msamiryusuf
(Mohammad Samir Yusuf)
November 9, 2016, 12:35pm
1
WE were working in the mqtt.cg to chnge the url from openhab to mysensor and now this error comes even we returend every thing back to normal
the error message as below
03:51:54.616 [INFO ] [t.mqtt.internal.MqttBrokerConnection] - Starting connection helper to periodically try restore connection to broker 'openhab’
03:52:01.758 [INFO ] [t.mqtt.internal.MqttBrokerConnection] - Starting MQTT broker connection 'mysensor’
03:52:02.387 [ERROR] [t.mqtt.internal.MqttBrokerConnection] - MQTT connection to broker was lost
Connection lost (32109) - java.io.EOFException
at org.eclipse.paho.client.mqttv3.internal.CommsReceiver.run(CommsReceiver.java:146)[199:org.eclipse.paho.client.mqttv3:1.0.2]
at java.lang.Thread.run(Thread.java:745)[:1.8.0_65]
Caused by: java.io.EOFException
at java.io.DataInputStream.readByte(DataInputStream.java:267)[:1.8.0_65]
at org.eclipse.paho.client.mqttv3.internal.wire.MqttInputStream.readMqttWireMessage(MqttInputStream.java:65)[199:org.eclipse.paho.client.mqttv3:1.0.2]
at org.eclipse.paho.client.mqttv3.internal.CommsReceiver.run(CommsReceiver.java:107)[199:org.eclipse.paho.client.mqttv3:1.0.2]
… 1 more
03:52:02.398 [ERROR] [t.mqtt.internal.MqttBrokerConnection] - MQTT connection to ‘mysensor’ was lost: Connection lost : ReasonCode 32109 : Cause : null
03:52:02.405 [INFO ] [t.mqtt.internal.MqttBrokerConnection] - Starting connection helper to periodically try restore connection to broker ‘mysensor’
please assist us
Rob_Pope
(Rob Pope)
November 9, 2016, 12:56pm
2
Are you running OH2? If so check this post
@Rob_Pope I had a similar problem in the past… It was due to OpenHab 2 loading up the default mqtt.cfg config file (with the sample <broker> name)… it was my mistake since I removed the comments from the lines without adjusting the broker name… After I fixed the mistake, the <broker> info still remained (as a second broker) in OH2 “internal database” (I don’t know how to call it :)) and was causing errors because all other parameters for <broker> were null.
Try to check with the Karaf Console …
3 Likes
gr1nch
(Kiat Huang)
July 17, 2018, 10:45pm
3
That was a very helpful post and answer - following it fixed the same problem for me ( error in the log files). Also as an OH newbie, first time using the Karaf console, which will no doubt come in handy for other things.
openhab2
(Gadget Guy)
December 28, 2018, 5:24pm
4
Thanks! this helped me after removing the 2.4 mqtt binding and reverting to the 1.x binding and some other failed configuration attempts which left me with duplicate config as shown below
----------------------------------------------------------------
Pid: org.openhab.mqtt
BundleLocation: mvn:org.openhab.io/org.openhab.io.transport.mqtt/1.13.0
Properties:
broker.clientId = openHAB
broker.pwd = openhabian
broker.retain = true
broker.url = tcp://localhost:1883
broker.user = openhabian
mosquitto.clientId = openHAB
mosquitto.pwd = openhabian
mosquitto.qos = 1
mosquitto.retain = true
mosquitto.url = tcp://localhost:1883
mosquitto.user = openhabian
service.pid = org.openhab.mqtt
----------------------------------------------------------------
To delete, I had to use the --force flag which seemed to do it. followed by a restart of openhab2
openhab> config:delete org.openhab.mqtt
This config is being edited. Cancel / update first, or use the --force option
openhab> config:delete org.openhab.mqtt --force