Long delay when 1fps

Forum for questions and support relating to the 1.28.x releases only.
Locked
ThreeLeaf
Posts: 14
Joined: Wed Jul 01, 2015 4:40 am

Long delay when 1fps

Post by ThreeLeaf »

Hello. I use the translator. I'm new to Zoneminder. I have 30 ip cameras Hikvision DS-2CD2032-I. 1280x720 - 1 fps. PC - Ubuntu Server 14.10. i3 processor and 12GB of RAM. Zoneminder shows the image with a long delay in 10-15 seconds. If in the camera settings to deliver 25 fps and in zoneminder 25 fps then the delay becomes 1-2 seconds. Further, when reducing fps increases delay.
I found on the forum threads about the dependence of the fps and delay in zoneminder. Removing the fps limit at zoneminder, and leaving it only on the camera. It turned out to reduce the delay to ~6 seconds ( decreased by 2 times).
Is there a solution to this problem?
Thanks in advance.
Linwood
Posts: 75
Joined: Thu Jun 25, 2015 6:40 pm

Re: Long delay when 1fps

Post by Linwood »

I just started with zoneminder and saw something similar on a DS-2CD2332-I, and found I was reducing the frame rate in zoneminder (on the monitor general tab) instead of in the camera. Try leaving the Maximum FPS and Alarm Maximum FPS blank on the general tab, and selecting your desired rate in the camera itself.
Southcross
Posts: 43
Joined: Tue Feb 10, 2015 9:17 pm

Re: Long delay when 1fps

Post by Southcross »

had the same issue with my cameras. the server would start to lag behind the camera by 10-30s... sometimes alarms would drop huge sections of frames
lowered the frame rate on my camera instead of ZM, solved the issue. Not ideal to run 15fps all the time, even during alarms, but better than a 2 second gap in recordings
Southcross
Posts: 43
Joined: Tue Feb 10, 2015 9:17 pm

Re: Long delay when 1fps

Post by Southcross »

follow up question... how do you like the HIKVISION camera(s)?
User avatar
knight-of-ni
Posts: 2406
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: Long delay when 1fps

Post by knight-of-ni »

You have vastly exceeded the capabilities of your hardware.
One cannot realistically expect to get 30 megapixel IP cameras at high frame rate to work on an i3 cpu. The actual frame rate is the frame rate coming from the the camera, not the frame rate you see in zoneminder.

Set the frame in your camera to ~5 fps, and then clear out any values you have placed into the max fps and alarm max fps fields in zoneminder as mentioned previously.

Stop all your cameras, except for one, and look at the %cpu of all your running processes. You should see a process called zma and zmc. Add these together. This is about how much % cpu each camera consumes.

Assume a cpu cap of 75% to reserve resources for the rest of the operating system.

Now divide 75 by the percent cpu your camera consumes.

This will tell you how many cameras you can expect to realistically run without problems, per cpu core.

So, on my demo system, my Foscam 9821 consumes 15% cpu at 720p resolution and 5fps. I have two cpu cores. That means my system can reasonably support up to 10 cameras -> (75 /15 ) * 2 = 10
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
Southcross
Posts: 43
Joined: Tue Feb 10, 2015 9:17 pm

Re: Long delay when 1fps

Post by Southcross »

probably why he was trying to run at 1FPS.... looking at the specs online, it looks like they *only* do 20/25/30 FPS?
ThreeLeaf
Posts: 14
Joined: Wed Jul 01, 2015 4:40 am

Re: Long delay when 1fps

Post by ThreeLeaf »

All said exactly what I wrote earlier in the topic. I've already got 1 fps on the camera and turned off the FPS limit in zoneminder.
User avatar
knight-of-ni
Posts: 2406
Joined: Thu Oct 18, 2007 1:55 pm
Location: Shiloh, IL

Re: Long delay when 1fps

Post by knight-of-ni »

Maybe there is information being lost in the translation.

Here is the spec sheet for your camera:
http://www.hikvision.com/UploadFile/ima ... 746023.pdf

According to that, your cameras cannot stream at 1 fps.

In order to continue, follow the instructions I posted earlier and tell us your results.
Additionally, post all the settings you entered into zoneminder for one of your cameras (screenshots are preferred).
Visit my blog for ZoneMinder related projects using the Raspberry Pi, Orange Pi, Odroid, and the ESP8266
All of these can be found at https://zoneminder.blogspot.com/
Locked