[Bug]: MQTT disconnects, node resets Wi-Fi and becomes unreachable until rebooted #5203
Replies: 4 comments 6 replies
-
According the library's docs, the default keepalive is 15 seconds which seems reasonable https://pubsubclient.knolleary.net/api |
Beta Was this translation helpful? Give feedback.
-
I believe I found the problem Wi-Fi network it was connected to is /22 network (netmask 255.255.252.0) I tried with static IP and manual config of netmask, problem still existed. I changed the network to /24 (255.255.255.0) and the problem went away |
Beta Was this translation helpful? Give feedback.
-
Just thinking - we added some code recently that modified behavior for private networks. I don't think it would cause these issues, but just so we can double check - could you provide the IP address of the MQTT server and the client? |
Beta Was this translation helpful? Give feedback.
-
Meshtastic Firmware 2.5.15.79da236 Alpha was released with fixes for Wi-Fi connectivity (#5387). |
Beta Was this translation helpful? Give feedback.
-
Category
WiFi, Other
Hardware
Heltec V3, Other
Firmware Version
2.5.6d55c08d
Description
MQTT and Wi-Fi are configured via the Android app.
Connects fine on boot and runs fine with MQTT traffic flowing, after about 40min - 60min serial connection shows "Failed to contact MQTT server directly"
After 5 retries to contact MQTT node reconnects Wi-Fi but becomes unresponsive on app and on network.
Only reboot fixes the issue for another 40-60min
Tried firmware 2.5.6, 2.5.8, 2.5.9
Tried local MQTT and cloud MQTT brokers
Tried different Wi-Fi router with only 2.4GHz active and HT20 set
Same issue on Heltec v3 and LilyGo T-Lora T3-S3
Local broker logs show "client timeout, closing connection"
Suspect it's an MQTT Keepalive issue and then becomes a Wi-Fi issue when it tries to reconnect, please check
Relevant log output
Beta Was this translation helpful? Give feedback.
All reactions