-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cache management and Event Clips #942
Comments
If you don't have enough ram, you can't use a tmpfs volume for the cache. It will work fine without tmpfs. Not sure why #2 would happen. Does it happen with fewer cameras? |
Thanks for the quick response! and sorry again for not being able to contribute yet. I didn't limit Docker's tmpfs size (it's unlimited by default) and of course I didn't use the overlapping option in config.yml |
I did more testing: It seems that when only one or two cameras miss frames or their VBR jumps too much, enough to trip ffmpeg, it stops splitting the segments or generally goes crazy (spiking CPU use). Then, all streams (even from good stable cameras) suffer, and no MP4 files are saved into Clips folder. The cache gradually fills up then cache clearing happens causing even more errors in the log. I guess RAM never fills up with tmpfs because of this periodic clearing. Now I have a fully working setup with 36 streams from 1080p Wisenet Cameras. Usage: CPU ~80%, RAM ~5GB, GPU ~75%. However, to get to this point I went through some quirks which I still don't understand:
So now I am back at exactly the same config as I started with, less 4 cameras, and all is working fine! |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
I've previously planned to contribute to this project starting this month, but pressure at work won't allow me enough time to do so.
However, I tried to test a few things on a large real-world deployment (40 RTSP Wisenet Cameras) using a modest PC. I had a few issues and still couldn't get Frigate to work as expected.
Issues:
Notes:
DB and MQTT still have all events logged, published correctly at all times.
Errors logged:
Setup:
Config:
docker-compose.yml
config.yml (an example camera (x40 in my actual file) along with global options:
Tests:
I also tried to replace the container's intel driver and ffmpeg with versions (intel-non-free) matching what I have on the host OS, using frigate's final container as base.
Details are in this : Container on my Docker Hub
and this Dockerfile on my github
But both the original Frigate container and my modified version behaved exactly the same.
I am ready to provide any additional info that may help, and looking forward to your insight on this issue.
Thanks in advance.
The text was updated successfully, but these errors were encountered: