[Bug]: Frigate starts writing to local disk if network storage is intermittently not available, does not recover, bricks Home Assistant #13951
Replies: 1 comment 8 replies
-
This is not a bug, and it seems you are misunderstanding how this is working. Frigate runs in a docker container, it has no knowledge of what kind of storage it is writing to, if that storage disconnects, or anything of the sort. That is all handled by the host. In docker config it is trivial to configure a container to stop if the network storage disconnects. If you're running as an addon then this would be a feature request for the home assistant supervisor |
Beta Was this translation helpful? Give feedback.
8 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Checklist
Describe the problem you are having
Two days ago I did some maintenance to my central storage system, therefor the SMB share for frigate became unavailable for a certain amount of time.
Today, when looking at System Metrics -> Storage the wrong storage device is being used to calculate disk usage.
In my case the Systems internal SSD with 240GB is being shown (Home Assistant installed on x64 NUC), while frigate media is actually being stored on a network share set up within Home Assistant that has 12TB of total space.
Further investigation revealed that frigate created the storage file structure on the local disk (/media/frigate) after the SMB share became unavailable.
This led to the following issues:
This is a very problematic error, since a split second network outage breaks the entirety of video recordings - and Home assistant in the aftermath. While I use a rather large 240GB disk for the HA installation, most people only have very small local storage available so it bricks the system for them even faster.
Since there is no message or notification whatsoever this breaks the entire HA installation due to the disk running full. Plus you loose your recordings from the point forward your disk gets full if you do not notice immediately.
Also recovery from this state is rather problematic as one needs the ability to ssh into the machine and clean up the storage manually to even make HA run again.
I really like that frigate tries to compensate for an outage in the media storage location but I strongly suggest that this becomes configurably in the frigate.yaml config file.
The outage of centralized storage is not a question of "if" but only "when". You update the firmware of your switch? Outage (with ubiquiti thats every few weeks). You restart the fileserver after an update? Outage. You change out a GBIC module? Outage. You replace a cable in your rack? Outage. You run your stuff via Wifi? Well, outages are preprogrammed then.
I suggest the following:
It is my point of view that besides all fancy detecion stuff the most important part of surveillance is a bullet proof method for recording. The system has to recover from power outages, intermittently loss of connectivity and all kinds of anomalies.
Steps to reproduce
This is a method to reproduce immediately. It happend to me without a HA restart, just not immediately.
Version
0.14.1-f4f3cfa
In which browser(s) are you experiencing the issue with?
No response
Frigate config file
docker-compose file or Docker CLI command
Relevant Frigate log output
Relevant go2rtc log output
Operating system
HassOS
Install method
HassOS Addon
Network connection
Wired
Camera make and model
Dahua
Screenshots of the Frigate UI's System metrics pages
see above
Any other information that may be helpful
No response
Beta Was this translation helpful? Give feedback.
All reactions