Connection Reset when using iot_hub_client (IoT Plug and Play)

Karim Walid Abdelazim Elhammady 16 Reputation points
2022-04-19T04:39:47.847+00:00

Hello,

I am using the SAMV71Q19B board to connect to the IoT hub using the iot_hub_client (https://github.com/azure-rtos/netxduo/blob/master/addons/azure_iot/docs/azure_rtos_iot_hub_client.md). I am connecting to the hub through an IoT edge device. I am sending some telemetry messages to the hub. The device connects to the hub without any issues and start sending telemetry messages. However, after an hour I receive a FIN ACK from the server , then the board send an encrypted alert followed by a FIN ACK, which reset the connection.

The board never reconnect again. Does anyone know the reason for this behavior?

One other thing, this issue happens almost at the same timestamp in wireshark in each trial.

I have attached below a screenshot of the wireshark capture.

Thanks,
Karim

194058-microsoftteams-image.png

Azure IoT Edge
Azure IoT Edge
An Azure service that is used to deploy cloud workloads to run on internet of things (IoT) edge devices via standard containers.
576 questions
Azure RTOS
Azure RTOS
An Azure embedded development suite including a small but powerful operating system for resource-constrained devices.
333 questions
Azure IoT Plug and Play
Azure IoT Plug and Play
A Microsoft technology based on an open modeling language that enables developers to connect internet of things (IoT) devices to the cloud without having to write any code.
18 questions
Azure IoT Hub
Azure IoT Hub
An Azure service that enables bidirectional communication between internet of things (IoT) devices and applications.
1,205 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Bo Chen 596 Reputation points Microsoft Employee
    2022-04-27T00:05:27.51+00:00

    Hi @Karim Walid Abdelazim Elhammady Yes, the timeout for connection is 1 hour by default here. You may redefine NX_AZURE_IOT_HUB_CLIENT_TOKEN_CONNECTION_TIMEOUT to extend the connection timeout. Thanks.

    1 person found this answer helpful.
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.