# Raspberry Pi 4 disconnects and cannot connect anymore

**URL:** <https://community.cumulocity.com/t/raspberry-pi-4-disconnects-and-cannot-connect-anymore/2223>\
**Category:** Forum\
**Tags:** cumulocity\
**Created:** [August 17, 2021, 1:06pm UTC](https://community.cumulocity.com/t/raspberry-pi-4-disconnects-and-cannot-connect-anymore/2223 "2021-08-17T13:06:56Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![hansboef](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/hansboef/32/1877_2.png) [@hansboef](https://community.cumulocity.com/u/hansboef)\
**Post date:** [August 17, 2021, 1:06pm UTC](https://community.cumulocity.com/t/raspberry-pi-4-disconnects-and-cannot-connect-anymore/2223/1 "2021-08-17T13:06:56Z")

</div>

I connected a Raspberry Pi 4 to Cumulocity IoT Platform without any problems following the device tutorial. After a while, the RaspPi disconnects and it seems it cannot reconnect anymore. First I thought it was because of the agent running on the RaspPi, but it seems to be running all the time. I tried with another RaspPi 4 but I have the same issue: it connects to the platform, then it disconnects and never connects again.  
Is there a way I can debug things regarding the connection? I couldn’t find anything about that.

---

<div class="post-metadata">

**Author:** ![Christian\_Guether1](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/christian_guether1/32/14848_2.png) [@Christian\_Guether1](https://community.cumulocity.com/u/Christian_Guether1)\
**Post date:** [August 18, 2021, 6:06am UTC](https://community.cumulocity.com/t/raspberry-pi-4-disconnects-and-cannot-connect-anymore/2223/2 "2021-08-18T06:06:38Z")

</div>

Hi Hans,

can you briefly describe how you connect the Raspberry Pi to Cumulocity. Do you use the Raspberry Pi agent which is described here: [https://cumulocity.com/guides/device-tutorials/raspberry-pi-4/](https://cumulocity.com/guides/device-tutorials/raspberry-pi-4/)?

Did you already have a look at the syslog: `$ tail -f /var/log/syslog`?

Best regards  
Christian

---

<div class="post-metadata">

**Author:** ![hansboef](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/hansboef/32/1877_2.png) [@hansboef](https://community.cumulocity.com/u/hansboef)\
**Post date:** [August 18, 2021, 6:48am UTC](https://community.cumulocity.com/t/raspberry-pi-4-disconnects-and-cannot-connect-anymore/2223/3 "2021-08-18T06:48:29Z")

</div>

Hi Christian, yes I used the guide you mentioned. And the syslog is not mentioning anything about the Cumulocity agent. When I use `$ /etc/init.d/cumulocity-agent start ; echo "result: $?"` I can see the agent is running.

Now when I restarted the RaspPi (again) I see this for a while: Send connection: _offlinePush connection: active, Last communication 17 Aug 2021, 12:26:00 (yesterday)_  
so something seems to work temporarily. How can I test the connection, by sending messages to and from the RaspPi? I am using the latest version of Node-RED on my RaspPi.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/flex005/user_avatar/community.cumulocity.com/system/32/31990_2.png) [@system](https://community.cumulocity.com/u/system)\
**Post date:** [November 16, 2021, 7:27am UTC](https://community.cumulocity.com/t/raspberry-pi-4-disconnects-and-cannot-connect-anymore/2223/5 "2021-11-16T07:27:45Z")

</div>

Closed on November 16, 2021, 7:27am UTC

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