Open rkoshak opened 7 years ago
Since there have never been any functional changes to the MQTT action and the last functional changes to the MQTT binding were over a year ago... I'm guessing this is something in OH2/ESH.
As a side note, the MQTT binding HAS no INFO level logging, so it can never produce any.
These two messages come from the IO transport:
MQTT Service initialization completed. Starting MQTT broker connection 'mosquitto'
One issue I see with the MQTT action is that it defines a service.pid here and is acting as if it has a configuration in the code. It has no configuration -- all config is done in the MQTT transport service.
The latest note in the community thread appears to indicate that uninstalling and then reinstalling the action fixed the problem.
@rkoshak, if you haven't tried this, can you check and report your results?
update: https://community.openhab.org/t/oh2-dont-even-try-to-connect-to-mqtt/31446/5 uninstalling and then re-installing the mqtt-action addon seems to be a viable workaround
While it's true that uninstalling the MQTT Action does permit the MQTT Binding to finish initialisation and connect to the broker, it's not a viable workaround because if the Action is reinstalled then the same issue will occur again next time OpenHAB is restarted. I'm on the SNAPSHOT build and this problem is still occurring for me, and since OpenHAB restarts several times a week, it's not feasible for me to have to manually intervene with uninstall/reinstall after every restart.
Observed the same problem on OH2.3. DeInstall/ReInstall MQTT Action did resolve the actual problem. In order to log the different DEBUG messages when starting with and without MQTT ACtion installed I did log:set DEBUG for both the Action and the Binding. When starting now with the Action installed the problem did NOT show again. No update made between. Will continue to monitor and post updates.
Anyone care to test this out? (@rkoshak @carywin @JueBag)
Sorry, but I'm presently somewhat out off service due to personell reasons. I migth answer on threads but will not touch anything more sophisticated.
I'll get back on that.
I seem to be having the same problem. OH2.3 works OK with MQTT binding alone. Adding MQTT action seems to break MQTT binding. Removing MQTT action returns system to functional state.
Any news on this issue? Having the same problems with latest OpenHAB 2.4 snapshot and MQTT 1.13 snapshot Binding and Action
Discussion on the forum is here.
I can't say exactly which build this started. But it is a problem with 2.0.0 release.
Expected Behavior
When I have both the MQTT binding and MQTT Action installed I expect to be able to publish messages through the action and publish/subscribe messages with the MQTT binding.
Current Behavior
When the MQTT Action is installed the MQTT binding generates no Info level logging including the expected:
No messages published to topics subscribed to are received by OH. No messages published by the action are received by the broker. These were confirmed using mosquitto_sub.
Putting the binding into TRACE level the only logs generated by the binding are as follows:
Uninstalling both the MQTT binding and the MQTT action and just reinstalling the MQTT binding causes the subscription Items to start receiving their messages again.
Possible Solution
Steps to Reproduce (for bugs)
Context
For some time now MQTT has been central to my HA system. When I moved to OH2 I started using the MQTT action instead of MQTT outgoing Items. It worked for many months. I don't know exactly when it stopped working but it was within the past couple of weeks.
Your Environment