Little update… upgraded the ‘flaky’ hotspot and ran an ethernet cable to it, rather than use powerline adapters. The mirror has held connection to the queue for 3 days now, which is by far a record!
Network connectivity seemed to be the issue, prompting a DNS error. Curious if the module could be a bit more resilient but perhaps that’s the nature of MQTT…? Decent home network has resolved.
Thanks for assistance.
Read the statement by Michael Teeuw here.
Posts
-
RE: MQTT server is offline
-
RE: MQTT server is offline
I can ‘force’ this error by turning off the nearest wifi access point that the mirror uses on my home network. Although the mirror associates with another AP the connection to the MQTT server is broken and will not re-establish.
This error only occurs occasionally, usually, which would make sense as the nearest access point is… ‘flaky’, shall we say (it’s a powerline adaptor type).
I am going to specify a certain (reliable) AP for the mirror to connect to. Otherwise I may try a different ssid for the second AP (keen to avoid this, though).
Thanks for help so far. -
RE: MQTT server is offline
Thanks @sdetweil . I do indeed have Pihole running on my network. Yesterday I observed the “MQTT offline” mirror notification exactly at the same time as a (successful) A and AAAA request from the mirror for the MQTT server URL.
Today, however, the notification appeared but there is no corresponding DNS request from the mirror.
This is the first module (and only device on my network) that struggles… not convinced it is DNS related.
Appreciate the help. -
RE: MQTT server is offline
Also, very occasionally, get the notification:
“MQTT Error. The MQTT client has suffered an error: Error: getaddrinfo EAI_AGAIN io.adafruit.com”Would appreciate a steer in the direction of any logs I can dig in to.
Thanks
-
MQTT server is offline
Hi there.
I am using an ESP8266 board as a door-sensor which publishes messages to my adafruit IO feed. I am then using the MMM-mqtt module by @javiergayala to subscibe to the feed and show if my door is open or closed.
This all works fine for a short time, but then I get a notification on the mirror that the “MQTT server is offline” and the module fails to receive any new published messages.
The adafruit feed is being updated fine when my garage door is opened/closed.
The only thing I can see in adafruit’s monitor screen is:2020/11/15 10:20:51AM mqttjs_aaeacdcb disconnected
And I can’t see anything in mm logs:
pi@mirror:~/MagicMirror/config $ tail -1000 ~/.pm2/logs/mm-out.log | grep mqtt [2020-11-15 10:11:54.078] [LOG] MMM-mqtt started ... [2020-11-15 10:12:07.819] [LOG] Creating new MQTT client for url: mqtts://*adafruit...* [2020-11-15 10:12:08.106] [INFO] Checking git for module: MMM-mqtt
Any ideas on what’s happening, or where I can look for a steer on what’s happening? The sensor and adafruit feed look to be working fine, just the mirror is disconnecting.
Thanks. -
RE: Adafruit IO Module
Absolutely:
module: "MMM-mqtt", position: "bottom_right", header: "Garage rear door", config: { mqttServer: "mqtts://username:key@io.adafruit.com:8883", topic: "username/feeds/feed-name", loadingText: "waiting for event...", interval: 60000, }
Obviously replacing username, key and feed-name.
I am having an issue currently with the mirror showing “MQTT server is offline” after a short time and mirror is not picking up any new messages published :(Hope that helps.
-
RE: Adafruit IO Module
Update: managed to achieve this with MMM-mqtt (lower case) module.
I think that MMM-MQTT connects with mqtt://io.adafruit.com… even if you specify 8883 port (when using SSL). With the MMM-mqtt module you can set the URL it connects with, and specify mqtts://io.adafruit.com… -
RE: Adafruit IO Module
Seconded.
Have tried with MMM-MQTT and MMM-mqtt modules, but can’t connect to my adafruitIO feeds. -
RE: MMM-Strava
Hi there. Icons. Recently updated my config to include ‘hike’ activity, and it does, but without the nice little icon beside (like the little shoe beside run activities, and bike beside cycle activities). In ‘chart’ mode. Any ideas?