Pi4 Freezing with HA consuming memory

I’m running home assistant on a pi4 and today it was locked up, so I rebooted it. This happens on occasion and it’s normally no big deal. However, I cannot get home assistant to start again without hanging the pi. I can watch in htop as python3 -m homeassistant --config /config goes from 0 - 73% memory. Then the whole machine is unresponsive and I have to pull the power. This happens in about 5 minutes time. During this time, the front end is unaccessible.

If I kill this process, before the machine locks up, it restarts and will lockup again within 5 minutes. How can I troubleshoot this if I can’t even get to the front end to try killing certain integrations?

I’d love some help with this. I’m still in the same spot with no real clue what happened. I haven’t been able to get HA to start long enough to get into the GUI and I’m not sure how I can disable various pieces now that it’s not all in configuration.yaml.

I’ve been meaning to move from my pi4 to a nuc setup with Ubuntu on it, but I was waiting to do that until the open zwave changes hit because I figure that’ll be a lot of work anyway. Maybe this is a sign, but the pi seems to be fine when I kill the container service. I can’t figure out how to start the container back though without just rebooting.

I’m seeing tons of lines in my log related to the unifi controller when I put the log level to INFO:

2020-07-15 17:23:20 INFO (MainThread) [homeassistant.helpers.entity_registry] Registered new device_tracker.unifi entity: device_tracker.unifi

500+ rows and that’s when my memory and CPU is jumping like crazy. If I let it keep going, it locks up.

How can I kill the UniFi integration?

You can remove it in

Configuration -> Integrations. (or manually edit .storage/core.config_entries – make a backup first)

It should perform better in 0.113

Thanks!

I deleted the lines in the file related to the Unifi integration, rebooted the pi and I can actually interact with the GUI now.