Image buffer size

Forum for questions and support relating to 1.33.x development only.
Post Reply
Posts: 18
Joined: Thu Sep 20, 2018 7:50 am

Image buffer size

Post by andrew-yu » Wed Jun 12, 2019 7:24 am

I see many log entries about image buffer size. Now Zoneminder wants buffer size like 400 or 500 for some of my cameras. I haven't so much RAM for that. I already setup minimum keyframe interval on all cameras where i could do it. Can it so large keyframe intervals like 400 or 500? Or can it be any performance issue?

Code: Select all

ImageBufferCount 85 is too small. Needs to be at least 401. Either increase it or decrease time between keyframes

User avatar
Posts: 2251
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: Image buffer size

Post by knight-of-ni » Wed Jun 12, 2019 12:38 pm

There is a direct relationship between how often keyframes are sent and memory requirements.

The message you posted indicates the keyframes are coming in way too slowly. A value of 401 is unusually large... double check you are entering the kayframe value in the camera correctly.

Keep in mind, in order to decrease the time between keyframes, you typically need to increase the keyframe value in the camera. I've often found the verbiage in the camera, describing the keyframe field, to either be misleading or absent altogether. Typically the value you enter represents the number of frames to send between each keyframe, so a value of 10 means to send a keyframe after every 10 frames.

If I want 1 keyframe to be sent every second and my cameras is running at 5 fps, then that would typically mean I would need to put a value of 5 in the keyframe field in the camera. If running @7fps, then use a keyframe value of 7, etc.

This can vary per camera, but this is typically what I end up doing.
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at

Posts: 11
Joined: Mon Mar 02, 2020 7:01 pm

Re: Image buffer size

Post by warlord » Tue Mar 03, 2020 5:33 pm

I am having a similar issue with my cameras. I've got Besder 1080p PoE cameras and all of them are reporting this issue. As is my Doorbird camera. For doorbird it was telling me "20 is too small, increase to 31". I increased to 35, and now it says "35 is too small, increase to 51". And all my Besder cameras are saying "40 is too small, increase to 51". I can't see how to change this setting at all on the doorbird.

But I've played with these camera configs on the Besders. I am recording from the Besder cameras at 5fps. The "I Frame Interval" was already set to 2. I tried increasing that to 5, but it didn't make a difference. I tried changing from VBR to CBR and going to the highest bitrate, but it didn't make a difference.... unless I need to stop the stream and restart it for the changes to take effect?

I don't have the RAM to increase the buffers -- I've got 32G RAM and I already increased the buffers from the default, 20, to 40 in order to get a longer pre-roll in my events. But right now I'm riding around 93% SHM usage.

Posts: 1
Joined: Fri Apr 10, 2020 10:14 am

Re: Image buffer size

Post by BassT » Fri Apr 10, 2020 10:31 am

Same Problem here.
I'm on 1.34.7 with 3 WiFi Cams, setup in VM.
Image Buffer Size is set to 30 because of ~5Gig Ram.

Now, where to set (decrease) time between key frames?
Can't find / see the settings, ...

Post Reply

Who is online

Users browsing this forum: No registered users and 12 guests