-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cloud Mqtt connection failing #10698
Comments
Please, could you be so kind on completing the troubleshooting template in order to have more information so as to properly help you? Please also provide all the logs. Remember to read the Contributing Guideline and Policy. Thanks. Support InformationSee Docs for more information. |
Hi, any news on this? |
I don't think the password lenght is the issue here. Searching the changelog it seems since v9.1.0 the following two MQTT related changes have been introduced:
As your issue starts with v9.2 I suggest you try to change back the Wifi connection timeout from 200 mSec to 5000 mSec and see if it solves your issue. If soo try to lower it again (as it was way too high for most users) to find a workable solution for Adafruit MQTT. EDIT: To revert, change in file xdrv_02_mqtt.ino define MQTT_WIFI_CLIENT_TIMEOUT from 200 to 5000 |
Hi, any news on this? |
Running into the same issue when trying to connect to aws iot also |
Please, help us solving this issue you are experiencing. Can you try as Theo has explained above? |
Apologies for taking so long to respond. Life came in the way of tinkering. And the adafruit Mqtt connection is normally established in less than 1 second, so an Mqtt socket timeout of 4 secs also should not have any impact. 00:00:00 CFG: Loaded from flash at FB, Count 318 I updated this device to 9.2.0 as well, and it failed to connect. You can also see from the restart logs here that the failure happened in just over 200 milliseconds. 00:00:00.050 CFG: Loaded from flash at F9, Count 510 I have not compiled this code myself yet, so gonna do some reading and will try the changes suggested. |
I have added all of the missing data on the template. PS thanks for all the efforts in creating and maintaining this great software. |
This is the log after a restart: 00:00:00.049 CFG: Loaded from flash at FB, Count 500 |
Could the issue have been caused by this FIX in 9.1.0.1: |
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
@ascillato Sorry for the long wait, My issue was with connecting using the aws IOT, however I found the answer I was looking for. It wasn't a bug sorry. |
Great to know that now it is working for you. |
Hi. I logged this issue and it is still a problem. As per my initial description. |
@ascillato This is still an issue. |
Reopening as requested |
As said before (#10698 (comment)) execute these changes and try again. Trying to explain it (as you did before) without testing makes no sense. |
@rmoosa can you share more information about the MQTT server and any configuration you have on it? I think getting a packet capture may lead to some clues. Maybe I can attempt to reproduce.. |
@jaymemaurice it is a public Mqtt broker. I don't have control over the settings. |
@rmoosa I'm also interested to see if I can use Adafruit.IO for a specific use case |
@barbudor hi. I'm connecting to port 1883. |
OK. I'll do some tests by the end of the week and report back. |
@rmoosa I can confirm immediate connection to AIO broker in unsecure mode (1883) using latest 9.2.0.7 EDIT: the MQTT password should be your AIO key, not your account password logs :
Of course errors on subscribing on topics that do not conform to AIO standard (errors shown on AIO web site:)
And standard Tasmota messsages publications such as But as you can see the "manual" publish goes correctly in my feeds Now, need to test with TLS. May be a specific AIO mode to conform Tasmota topics to AIO standard would be interresting. |
@barbudor can you ping the io.adafruit.com server from you network. |
Located in France, ADSL access in countryside location (around 4Mbps bw) |
@barbudor my pings to that server are about 400ms. I'm going to try and recompile with new settings as previously suggested. Will test over the weekend. |
There is one recent change regarding the TCP Timeout that is used when establishing the connection with the MQTT socket I've just tested TLS. 1st time for me I tried TLS and it worked on 1st try too. So I strongly suggest that you use it too as transporting credential in clear on the Internet is not the safest. |
@barbudor i am using the correct auth details and settings. |
Downgrading may leads to unexpected behavior as flash mapping of settings have changed Can you try 9.2.0.7 fresh (serial erase and flash and reconfigure from scratch) ? Are you sure that after all those downgrades and upgrades your device still has proper access to the Internet and the DNS ? |
@barbudor thanks for that info. |
@rmoosa - did you get a chance to try again? |
Please, when you have time, tell us if you could solve your issue with the suggestions done above. |
PROBLEM DESCRIPTION
I am connecting to the adafruit.io Mqtt server. The password is 32 characters long.
Connection works perfectly on 9.1.0. But fails to connect on subsequent versions.
After connection failed on latest build, I downgraded to 9.1.0 and it connected successfully again.
Tested on 2 separate devices. Same issue.
REQUESTED INFORMATION
Make sure your have performed every step and checked the applicable boxes before submitting your issue. Thank you!
Backlog Template; Module; GPIO 255
:Backlog Rule1; Rule2; Rule3
:Status 0
:weblog
to 4 and then, when you experience your issue, provide the output of the Console log:TO REPRODUCE
Steps to reproduce the behavior:
Upgrade to latest build and connect to Mqtt server using 32 character long password.
EXPECTED BEHAVIOUR
connect successfully to Mqtt server
SCREENSHOTS
If applicable, add screenshots to help explain your problem.
ADDITIONAL CONTEXT
Add any other context about the problem here.
(Please, remember to close the issue when the problem has been addressed)
The text was updated successfully, but these errors were encountered: