Tons of errors and random disconnection of HA server

I run HA on a Raspberry 4, with SSD (Startech adapter and Kingston SSD) and get tons of errors and random disconnection (no access to Lovelace). I also tried with SD card and nothing changes.
It all started upgrading from 10.2 to the latest version of HA. At the same time I started to have interruptions in my home network. So, I decided to get rid of my Xiaomi mesh routers and got a UBNT AmpliFi Instant HD router with mesh satellite which is awesome. But I still have random disconnections of HA.

Then, I started from scratch and do a fresh install of HA. But the issues haven’t disappeared.
Sometimes everything works perfect and other times, I can’t connect. Sometimes duckdns access would work instead of local LAN, and sometimes neither would work).
Other strange behavior I encountered is slowness. After activating a Shelly switch, for example, it would prompt me with: error calling service turn on… but after, let’s say 15 seconds, it will execute the command and activate the switch… (In my Shelly app everything works fine). All these symptoms are random.

When I can’t connect mobile app would say Websocket disconnected.
Ping to HA’s IP keeps working even when HA’s is unresponsive.
I suspect the problem may be in my network but don’t know where to start and what to try first.

I appreciate your help and insights, because I ran out of solutions. :sob:

First time posting in the forum so hoping this might help you!

I have the same setup Raspberry Pi 4, recently upgraded from SD to SSD (Kingston with Startech cable). After the upgrade I was a bit disappointed as things seemed unstable. I have a slightly strange network setup as my Draytek router load balances 4G and ADSL connections.

Anyway, after trying many things including removing addons, I recalled Mark Watt Tech’s video pointing out the Home Assistant Cloud sometimes needed reconnecting after an SSD upgrade. I use Home Assistant Cloud with Alexa integration. It seemed to be connected but I logged out and in again and everything seems to have stabalised. My guess is that the Cloud was constantly trying to get state updates sent too/from Alexa and essentially spamming my network with traffic. That’s just a guess though as I’m no expert.

So if you’re a HA Cloud user, try logging out and in again.

Hi fenty17, thank you for your input. I don’t use the HA cloud.

Ah well. Was worth a shot. What about InfluxDB or other database addons? I disabled/removed InfluxDB as part of my troubleshooting too.

Might be worth disabling some addons one by one to see if any of them are causing the issue.

Yes fenty17, I disabled the addons related to external access (duckdns, mariadb, nginx proxy manager) and now local access has been restablished. Will have to check which one is the faulty one.
Thanks for pointing me in that direction.

1 Like