IoT Connection missing CONNACK [PCAP]

0

Hello,

We're connecting to AWS IoT via an LTE connection, but have occasionally noticed some odd behavior. The device has an LTE data connection, and attempts to connect to IoT Core. However, the Core never seems to accept the connection, and I can't see anything in CloudWatch related to this connection.

The observed sequence is:

  1. Device sends a CONNECT request to IoT Core
  2. IoT Core sends a TCP ACK packet, acknowledging the request

I'd expect the sequence to go something like this:

  1. Device sends a CONNECT request to IoT Core
  2. IoT Core sends a TCP ACK packet, acknowledging the request
  3. IoT Core sends a CONNACK packet back

I have a PCAP file of the network transfers if that's useful. I can't figure out how to attach it to this, so here's a snapshot: Missing CONNACK

Note: the IP address 4.3.2.1 is simply a placeholder for our AWS IoT Core IP.

I am confident that the credentials work, as this does not always happen. The same device can connect with the same credentials at a later time. I just don't know why this sort of behavior occurs.

I've tried searching in the CloudWatch logs for the source IP address and deviceId, but there are no results for either, which is disappointing. Thank you, Jonathan

已提問 3 個月前檢視次數 343 次
2 個答案
0

Hello,

That port in the screenshot is not accurate - the actual port in use is 8883. The provider we are using has a translation service for ports and IPs, which is why this looks the way it does.

Thank you, Jonathan

已回答 3 個月前
  • OK. What error does your client report? Are you saying it works most of the time for all your devices, with just occasional connection problems? Do your CloudWatch metrics report any errors or throttles described here: https://docs.aws.amazon.com/iot/latest/developerguide/metrics_dimensions.html#message-broker-metrics

  • There is no error per se, the connection just gets stuck in limbo (no message is received after the TCP ACK). So the application logic tries to connect again. EDIT: Also, I checked the metrics report and there are no throttles or errors around connect in the last week.

0

Hi. I think your connection attempt isn't getting far enough to reach AWS IoT Core, hence no logs in CloudWatch. Port 1883 isn't supported: https://docs.aws.amazon.com/iot/latest/developerguide/protocols.html.

profile pictureAWS
專家
Greg_B
已回答 3 個月前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南