Announcement

Collapse
No announcement yet.

Plugin loses broker hostname "occassionally"

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Plugin loses broker hostname "occassionally"

    I have been using mcsMQTT for quite a while without issue. Recently it has started blowing up my Homeseer logs with an error that it cannot find the Broker:

    "StartMQTT Client attempt Failed to Broker 1server.domain.com No such host is known Line 0 No such host is known"

    It appears that something has prepended a "1" to the hostname and then the MQTT connection fails (i.e. the hostname is server.domain.com but the error is 1server.domain.com)

    This goes on for about a minute every couple of days (maybe, not exactly sure of the interval), with hundreds of connection attempts per second for that minute. After a minute of this behaviour everything appears to go back to normal. I haven't figured out a pattern as to when it will occur, and I don't know what could be setting it off. I continue to see MQTT messages after the log storm so either it resets itself or continued to work in the background while the storm is occurring.

    Any pointers on where I should be looking?

    HS4 Pro Edition 4.1.12.0 (Windows)
    mcsMQTT v.5.3.0.4

    #2
    The 1 is part of the error message and not part of the address. It is broker #1 that is loosing the connection. It is not that the address is 1server.domain.com.

    Every 10 seconds mcsMQTT looks at the port 1883 socket status and when it becomes disconnected from the broker it will attempt to connect again. The message seems to indicate that the broker has gone offline or the router is no longer able to complete the route.

    You can automate the detection with trigger on the connect device if you enabled statistics to be includes as HS devices. I should filter output to the log as a storm does not help much. There is not much else that you can do with the plugin itself since it keeps trying every 10 seconds. I would employ network monitoring techniques watch the connection to the broker.

    Comment


      #3
      Turns out my Mosquitto broker updated to 2.0 which now requires a config file, so the broker was effectively broken. Thus ends my experiment with Watchtower for automatic docker updating. Now I have broker checks added to check_mk and Prometheus for faster notification in the future. Chalking it up to a learning opportunity. Thanks for the quick reply and the awesome plugin,

      Comment

      Working...
      X