Home Assistant just stops working!

@bruin we have to find common denominator between us.
Setup: Rpi4 with SSD, always latest updates and sqlite. Wired lan connection to google nest wifi network

EDIT: this is not happening always :frowning:
Also noticed just now, that around time it happens my binary _ping router sensor is Disconnected for 5 minutes:

Sensor config:

binary_sensor:
  - platform: ping
    host: 192.168.1.1
    count: 5 #Default value
    scan_interval: 300 #Default value 5mins. The ping binary sensor will poll the devices every 30 seconds.
    name: Ping router

Edit: had two stops in 12 hours :-(. This time ping binary sensor was not disconnected

I have same problem. I have rpi 4 with ssd and maria db. It started with rpi3+ and ssd. I upgraded pi to 4 as i thought the ethernet was broken. I reinstalled it and i have the problem. I tried ethernet, wifi, static IP. It reoccurs twice a day. It seems like disk disconnects, coz i can access everything whatā€™s kept in memory, but i canā€™t access anything which needs access to the disk. Iā€™ll try to find a ram log add-on to see whats going on.

O.k. so searching for whatā€™s been common between all of us having this issue:
RPI 4 with SSD (DB could be sqlite or maria)
Also I am booting from SSD. meaning: I am NOT using SD+SSD where /data has been moved to SSD. As @cogneato suggested in discord booting from SSD has more issues.

More information about my setup and problem. @tLuQo @bruin @Enforcerke @Daniel_Lim @DaHai Can you find anything, that matches?
All it started after newest updates on June 13.
From hardware perspective: I have RPI4 model B 4GB ram (official power supply) with SSD and a first generation Conbee.
Always installing latest stable OS and Core versions
My addons:
AppDaemon 4,Duck DNS,File editor,Mosquitto broker,Plex Media Server,Portainer,SQLite Web,SSH & Web Terminal (Itā€™s not running),Samba share,Terminal & SSH,deCONZ

Especialy interested if anyone else having Plex Media Server, as another suggestion from @cogneato in Discord was that Plex may be an issue in there

Same at my setup: RPi4 8GB RAM, Booting HassOS from SSD
Addons: File editor, ESPHome, FluxDB, SSH & Web Terminal

When it freezes at first some sensors stay unchanged then some web doesnā€™t respond anymore and later I lose connection to the complete home assistant server.

2 Likes

I disabled ble tracking in home assistant as well as i upgraded the core to latest version and itā€™s still running since then (1 and half day so far). I also disabled ma xmas timer since the switch is off. Iā€™ll see how it goes further.

So how is it going?
For me it stopps once a week for past few weeks. And usually on Same days Thursday - Friday. Really strange

Iā€™m getting similar problems. Every now and then, sometimes daily, sometimes every few days. I cant canā€™t access HA via the ip address. Out of curiosity, next time this happens to someone else, rather than turning the Pi off and on again, can you try restarting your router instead and let me know if you are able to get back in. While still really annoying this works for me.

Im using a pi 4 and its connected directly to the router via lan

It got back after few days so i downgraded host OS to version 5.4 ā€¦ it works like a charm now.

Thanks

But with recent supervisor updates this work around is getting off the table
See this GitHub discussion from there https://github.com/home-assistant/operating-system/issues/1119#issuecomment-932370780

Got the same issue here.
PI3B+, latest version of HA + HAOS.
Until about 1 month it was happening daily; then I updated the system and all the addons, removed InfluxDB which I though it may lead to instabilities and it seems it solved.

It was not totally solved because I had the system stuck in this situation about 3 times during this last month, however the occurrencies were reduced.
Still when it happens itā€™s really uncomfortable since there is no clue on what it caused.

I have the same problem. I have the latest version of HA + HAOS on PI3B+.
It goes offline whenever Iā€™m compiling a new ESPHome device.
I then have to cut the power and cool it down then power it and wait about 15 minutes for it to boot.

An SSD and a UPS is a must for a Raspberry Pi based Home Assistant OS server.

Also, does anyone know how to shut down the Raspberry Pi running the Home Assistant OS from ssh?
I would like to try to gracefully shut it down from ssh to avoid corruption when the front end becomes unresponsive but I can not find this information anywhere. I think the whole docker thing is a complication when trying to shut the system down with ssh. I should be able to do this because when the system becomes unresponsive, the gui still shows the HAOS logo and displays an error message like connection problem or something.

Since my last message, I tried to compile again 2 more times. Both time it crashed and became unresponsive for about 15~20 minutes.

Which made me think that it might be an over-heating issue. So I tried another time using a handheld blower to blow air towards the cpu to keep it cool when compiling and it didnā€™t crash this time.

I will now use the systemmonitor add-on/platform to have a better understanding of whatā€™s going on. However, I believe there is something else with the OS that causes high cpu usage or temperatures. Iā€™m not used to the docker environment but I will try to find out what causes high cpu/temperature so it might take some time.

Maybe pi3B+ simply isnā€™t enough for a server like this.

For anyone without a heatsink, I would suggest a hard downclock and more power:

Pi 3+/4

arm_freq=1200
over_voltage=1

Pi 3

arm_freq=1000
over_voltage=1

If you are still having freezing with a heatsink, there may be other factors at play, these may still help though.

Also check the voltage on GPIO VCC, should be at least 4.8V, 5.0 preferred

Also, seems ridiculous but putting your RPi sideways gains a couple of Ā°C

This ā€œHA just stops workingā€ issue is happening to me as well. It began a couple of months ago I think, and HA stops working about once a week - usually between midnight and 6 am. Because the log starts afresh on a reboot, is there any way of capturing the log so that I can see what might be causing this?

I have a 4GB RPi4 with an SSD (booting from the SSD).

Iā€™ve noticed that on a couple of occasions at least, Iā€™ve had to reboot twice to get a fully working system. After the first reboot, the system at first starts working, but will then lock up after an hour or two (and the RPi4 becomes very warm). A second reboot, and itā€™s OK (for the next week or so).

System Health

version core-2021.9.6
installation_type Home Assistant OS
dev false
hassio true
docker true
user root
virtualenv false
python_version 3.9.6
os_name Linux
os_version 5.10.17-v8
arch aarch64
timezone Europe/Amsterdam
Home Assistant Community Store
GitHub API ok
Github API Calls Remaining 4932
Installed Version 1.15.2
Stage running
Available Repositories 942
Installed Repositories 11
Home Assistant Cloud
logged_in true
subscription_expiration 19 October 2021, 2:00
relayer_connected true
remote_enabled false
remote_connected false
alexa_enabled true
google_enabled true
can_reach_cert_server ok
can_reach_cloud_auth ok
can_reach_cloud ok
Home Assistant Supervisor
host_os Home Assistant OS 6.4
update_channel stable
supervisor_version supervisor-2021.10.0
docker_version 20.10.7
disk_total 109.3 GB
disk_used 20.6 GB
healthy true
supported true
board rpi4-64
supervisor_api ok
version_api ok
installed_addons File editor (5.3.3), Samba share (9.5.1), InfluxDB (4.2.1), Terminal & SSH (9.2.1), Grafana (7.2.0), Z-Wave JS to MQTT (0.26.0), TimescaleDB (1.1.6), DSMR Reader (0.6.0)
Lovelace
dashboards 2
resources 8
views 4
mode storage

I fixed my freeze and stopping problems by installing an Ice Tower Cooler.

This is how my Pi 3B+ processor temperature looked like before installing the Ice Tower Cooler, averaging at 54 Ā°C.

And this is how it looks like after installing the cooler, averaging at 34Ā°C.

The cooler made a big difference in the temperature, which is about -20Ā°C.

This is what it looks like now after installing it.

I recommend this to anyone having stability issues with their setup.

The package comes with two fans.
A transparent fan with color-cycling RGB LEDs but it is a bit noisy and uses about 40mA @5V. This comes installed on the cooler. There is an additional fan in the package which is black but it is noiseless and uses 20mA @ 5V. I replaced the transparent one with the better black one as you can see in the photo.

1 Like

I solved my HA from constantly going off. I felt mine was more network based. Noticed that if i reset the router rather than the pi4, it would come back on. I thought because my ethernet was plugged in, that my pi would automatically be using it, but it wasnā€™t. It was till using the wifi.

So under Supervisor> System> Host> IPAdress> Change Make sure your eth0 ipv4 has a static ip and my ipv6 is set to DHCP.

Your static ip canā€™t be the same as your wifi one. Then connect to this one. Since doing that my HA has stayed up. 5 days and counting. (If you want your ip the same, just take care when swapping them over. Probably test a new ethernet ip before hand)

I have the same problem with random freezes of the system. There is some temperature spike but not significant, from 35 celcius to 44 celcius before it freezes, last time it happened at around 23:00 hours, close to midnight, times before that I didnā€™t check. This is the third time now in almost two months.

My setup is RPI 4 8GB with boot from SSD, no SD card installed. Iā€™ve noticed that my KNMI integration was the last thing in the logs that gave errors. Iā€™ve uninstalled the KNMI integration, letā€™s see if that fixes my freezes.

Network connection is done through cable, not WiFi. I have a case for my RPI 4 with heatsink and small fan that got supplied with it.

The random freezes suck because I want to move my password vault from the Google browser to my HA local instance and connect through VPN to avoid port forward. But for the password vault the be hosted on my RPI I need 99,999% uptime of the system to be able to rely on it.

I was able to capture a CLI trace at the time of a crash. My configuration: Raspberry Pi 4B 4GB, 120GB Intenso SSD with Home Assistant (external), Raspberry Pi 4 Case, USB-C Power Supply 5V 3A.
See graph: power and memory consumption as well as temperature look normal. The temperature actually got down at the crash time:


Here is the picture from the CLI screen; it shows ā€œrebooting in 5 secondsā€ at the end, but this doesnā€™t happen. Iā€™m unable to inteprete the CLI log, but maybe you can see some meaningful things to identify the reason of crashing, which happens almost daily.

Thanks.

Thatā€™s a kernel crash. I cannot really tell moreā€¦