# MQTT connection to AWS IoT Core disconnecting and not reconnecting without restarting flows

**URL:** <https://discourse.nodered.org/t/mqtt-connection-to-aws-iot-core-disconnecting-and-not-reconnecting-without-restarting-flows/57166>\
**Category:** General\
**Tags:** mqtt\
**Created:** [24 January 2022 19:33 UTC](https://discourse.nodered.org/t/mqtt-connection-to-aws-iot-core-disconnecting-and-not-reconnecting-without-restarting-flows/57166 "2022-01-24T19:33:03Z")\
**Posts on this page:** 3\
**Page:** 2

<div class="post-metadata">

**Author:** ![Nirodam](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/nirodam/32/67063_2.png) [@Nirodam](https://discourse.nodered.org/u/Nirodam)\
**Post date:** [7 February 2022 20:49 UTC](https://discourse.nodered.org/t/mqtt-connection-to-aws-iot-core-disconnecting-and-not-reconnecting-without-restarting-flows/57166/21 "2022-02-07T20:49:18Z")

</div>

Also to note, with the two test I have running with only changing the listed items...

1. An MQTT connection to AWS with "Use clean session" turned off
2. Another MQTT connection to AWS with the "Keep Alive" set to 30 and mqttReconnectTime set to 45000 in the settings.

Both have remained connected since the 2nd of February. The first had one period of disconnect on the 4th, but reconnected 15 seconds later.

I am still monitoring for the issue to happen again.

---

<div class="post-metadata">

**Author:** ![Nirodam](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/nirodam/32/67063_2.png) [@Nirodam](https://discourse.nodered.org/u/Nirodam)\
**Post date:** [10 February 2022 15:11 UTC](https://discourse.nodered.org/t/mqtt-connection-to-aws-iot-core-disconnecting-and-not-reconnecting-without-restarting-flows/57166/22 "2022-02-10T15:11:13Z")

</div>

Quick update.

It seems that setting the MQTT connection to AWS with "Use clean session" turned off is working without the prior issues occurring.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [11 April 2022 15:11 UTC](https://discourse.nodered.org/t/mqtt-connection-to-aws-iot-core-disconnecting-and-not-reconnecting-without-restarting-flows/57166/23 "2022-04-11T15:11:32Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.

[Previous page](https://discourse.nodered.org/t/mqtt-connection-to-aws-iot-core-disconnecting-and-not-reconnecting-without-restarting-flows/57166.md?page=1)
