OH3 MQTT changing broker information

  • Platform information:
    • Hardware: CPUArchitecture/RAM/storage Pi
    • OS: what OS is used and which version
    • Java Runtime Environment: which java platform is used and what version
    • openHAB version: 3
  • Issue of the topic: please be detailed explaining your issue
  • Please post configurations (if applicable):
    • Items configuration related to the issue
    • Sitemap configuration related to the issue
    • Rules code related to the issue
    • Services configuration related to the issue
  • If logs where generated please post these here using code fences:

Yesterday I started seeing MQTT disconnections in the log. I spent several hours trying to resolve what I thought was as mosquitto problem but the issue is in OH3. For some reason it is creating another broker which is unable to connect to mosquitto. The ‘real’ broker is still connected but the errors were throwing me.

2021-02-09 19:37:51.212 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to ‘192.168.0.211’ with clientid MQTT2
2021-02-09 19:38:45.398 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to ‘192.168.0.211’. Next attempt in 60000ms
2021-02-09 19:38:45.444 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to ‘192.168.0.211’ with clientid 6eb41d88-5355-488a-b66f-65ac21309720

The new broker is unable to connect and floods the log. I’ve removed the settings in MQTT.cfg in case that was causing an issue.but it still happens. The broker is a ‘systemBroker’ and reappears in the Inbox if I delete it.
How can I get rid of it?

What happens if you go into the System Broker settings, remove all the text in all the fields, and then save?

Not possible to save because it gives validation errors for fields which need information

Does this help?

It appears to be the ‘System Broker’ which can’t connect. I’m not sure what its function is (other than clutter the inbox and spam the log).

Removing the text in the Settings part rather than the Things stops the error - apart from an error on startup because it’s not configured. Got to ask why it’s there. Rich Koshak in a post somewhere says it’s something to do with the (now obsolete) internal broker.

Well, I mean

:wink:

Correct. Seems to have been an oversight, and should have been removed when the internal broker was also removed! Strange that the System Broker tries to set itself up for some, but not for others - you’re not the first with this issue, as you’ve seen, but I don’t see the same at all. What are you running openHAB 3 on?

It’s on a Raspberry Pi with the broker on a Synology NAS. I upgraded to OH3 on Sunday (with some issues which I eventually resolved).
It ran fine until about 6pm yesterday evening when it suddenly started to throw the error.

I have the same issue. Always have.
I have my MQTT broker running on my OH2 setup on another PI.
OH3 connects to this broker.

this is my current log file

2021-02-10 14:10:02.845 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:11:02.851 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:11:02.859 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:12:02.866 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:12:02.878 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:13:02.884 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:13:02.895 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:14:02.905 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:14:02.917 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:15:02.927 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:15:02.937 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:16:02.940 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:16:02.959 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:17:02.971 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:17:02.983 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:18:02.990 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:18:03.002 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:19:03.008 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:19:03.019 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:20:03.030 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:20:03.043 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:21:03.063 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:21:03.073 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:22:03.083 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:22:03.106 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:23:03.110 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:23:03.119 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:24:03.122 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:24:03.135 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:25:03.146 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:25:03.155 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:26:03.161 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:26:03.174 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:27:03.180 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:27:03.188 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:28:03.192 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:28:03.204 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:29:03.210 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:29:03.219 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:30:03.225 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:30:03.254 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:31:03.257 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:31:03.269 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:32:03.280 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:32:03.290 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

2021-02-10 14:33:03.293 [INFO ] [.reconnect.PeriodicReconnectStrategy] - Try to restore connection to '192.168.0.143'. Next attempt in 60000ms

2021-02-10 14:33:03.305 [INFO ] [.transport.mqtt.MqttBrokerConnection] - Starting MQTT broker connection to '192.168.0.143' with clientid 5e6cf4d0-58a4-43b5-ab05-1301c31c511c

Do you happen to know wether an IssueReport was filed on that already?
Looking at my test-system I see a similar thing. It used to be connected to an external broker via a Broker Thing. This broker was shutdown and a broker on another external device was started. I created a new Broker Thing which is working, however now I’m getting the above posted messages every minute which are coming from a System Broker (never created!) using the settings of the shutdown broker connection. This System Broker appears in the Inbox, no matter if removed directly or after creating a Thing from it, it will reappear after the next Scan or Restart.

No idea - I’ve never had the problem, so never looked. Did you upgrade to OH3, or start completely fresh?

On my test-system it was an Upgrade.

Yeah, mine was a clean install. Would be interesting to see if those who have this issue are all upgrades. Had you ever used the inbuilt openHAB MQTT broker in your OH2 setup?

No!

Me neither – always used mosquitto

And to confirm - yours was an upgrade from OH2 too not a clean install of OH3?

Yes upgrade from OH2