High CPU load after upgrade 1.34 -> 1.36
High CPU load after upgrade 1.34 -> 1.36
Hi, my server load rises from 14 to 25 after upgrade from Debian oldstable to stable. I've made no configuration changes. Server is working fine with ZM for ages, it is 2xIntel(R) Xeon(R) CPU E5-2640 0 @ 2.50GHz with 128GB RAM. Here are some graphs documenting the change:
System is running 71 modect monitors. Can anybody give me a hint where should I search please.
Thank you in advance!
Milan
System is running 71 modect monitors. Can anybody give me a hint where should I search please.
Thank you in advance!
Milan
-
- Posts: 1
- Joined: Mon Sep 09, 2024 9:14 am
Re: High CPU load after upgrade 1.34 -> 1.36
I would like to understand why the gap value appears!migo wrote: ↑Fri Sep 06, 2024 7:30 am Hi, my server load rises from 14 to 25 after upgrade from Debian oldstable to stable. I've made no configuration changes. Server is working fine with ZM for ages, it is 2xIntel(R) Xeon(R) CPU E5-2640 0 @ 2coreball.50GHz with 128GB RAM. Here are some graphs documenting the change:
Screenshot from 2024-09-06 07-47-44.png
Screenshot from 2024-09-06 07-48-04.png
Screenshot from 2024-09-06 09-25-22.png
System is running 71 modect monitors. Can anybody give me a hint where should I search please.
Thank you in advance!
Milan
Re: High CPU load after upgrade 1.34 -> 1.36
Please read the release notes.
You are likely using double the ram due to ImageBuffers not being updated.
You are likely using double the ram due to ImageBuffers not being updated.
Re: High CPU load after upgrade 1.34 -> 1.36
Which one?stafflabour wrote: ↑Mon Sep 09, 2024 9:15 amI would like to understand why the gap value appears!migo wrote: ↑Fri Sep 06, 2024 7:30 am Hi, my server load rises from 14 to 25 after upgrade from Debian oldstable to stable. I've made no configuration changes. Server is working fine with ZM for ages, it is 2xIntel(R) Xeon(R) CPU E5-2640 0 @ 2coreball.50GHz with 128GB RAM. Here are some graphs documenting the change:
Screenshot from 2024-09-06 07-47-44.png
Screenshot from 2024-09-06 07-48-04.png
Screenshot from 2024-09-06 09-25-22.png
System is running 71 modect monitors. Can anybody give me a hint where should I search please.
Thank you in advance!
Milan
Re: High CPU load after upgrade 1.34 -> 1.36
No. In 1.34 ImageBuffers had to be large... Now it can be something more like 3. During the upgrade the value should have been copied to MaxImageBuffers and set to 3, but I've seen lots where that didn't happen, and so, both are large and the system is unnecessarily using double the ram.
Re: High CPU load after upgrade 1.34 -> 1.36
Weekend looked promising, system load was around 16, but today when there was lot of movement under cameras, system load peaked at over 60.
There is lot of free usable ram:
I'm trying to do zoneminder downgrade now to 1.34.
There is lot of free usable ram:
I'm trying to do zoneminder downgrade now to 1.34.
Last edited by migo on Mon Sep 09, 2024 1:36 pm, edited 1 time in total.
Re: High CPU load after upgrade 1.34 -> 1.36
Thank you for clarification. Initially there were large values from v1.34, I've adjusted all to 0 - automatic setting for Maximum Image Buffer Size, right after upgrade... Image Buffer Size was set to 3.iconnor wrote: ↑Mon Sep 09, 2024 1:31 pm No. In 1.34 ImageBuffers had to be large... Now it can be something more like 3. During the upgrade the value should have been copied to MaxImageBuffers and set to 3, but I've seen lots where that didn't happen, and so, both are large and the system is unnecessarily using double the ram.
Re: High CPU load after upgrade 1.34 -> 1.36
I was able to downgrade Zoneminder to 1.34 using Deb11 package and I also needed to install and use php7.4 for it. I've dropped 1.36 database and imported backup from 1.34. Everything else is the same like was with 1.36. I've let it settle a bit to not make false conclosions. Now is Zonemnider working like it should. I've downgraded Zonemnider at 11 AM yesterday, it can be seen on graphs below.
I don't think that 1.36 was using double the RAM, please look at memory usage graph:
Actually 1.36 was using less RAM than 1.34 but not using shmem at all.
Interesting is that 1.36 was making a lot more context switches:
and VM stat looks more jerky. DB usage pattern is different too, but this comes from changes you have made in code, no table locking etc.
I've monitored system load with atop, and it was CPU bound only. So no network or IO problems were detected. With this test I can rule out HW problem and Debian12 influence on Zoneminder's performance.
Any ideas? Thank you very much!
Milan
I don't think that 1.36 was using double the RAM, please look at memory usage graph:
Actually 1.36 was using less RAM than 1.34 but not using shmem at all.
Interesting is that 1.36 was making a lot more context switches:
and VM stat looks more jerky. DB usage pattern is different too, but this comes from changes you have made in code, no table locking etc.
I've monitored system load with atop, and it was CPU bound only. So no network or IO problems were detected. With this test I can rule out HW problem and Debian12 influence on Zoneminder's performance.
Any ideas? Thank you very much!
Milan
Re: High CPU load after upgrade 1.34 -> 1.36
Here is CPU usage graph:
and VM stat graph:-
- Posts: 9
- Joined: Sat Sep 14, 2024 3:01 pm
Re: High CPU load after upgrade 1.34 -> 1.36
Hey Milan, that sounds frustrating, man. When you're facing a sudden spike in CPU load after an upgrade without tweaking settings, it usually boils down to how the new version is utilizing resources differently. Since you got a beefy setup, those 2xIntel Xeon CPUs and 128GB RAM should handle ZM with ease. But if it's spiking unexpectedly, maybe there's a new feature in 1.36 that's more resource-intensive. I'd recommend checking out ZM's release notes for the new version to see if any changes might be causing this. You might also want to monitor specific processes to see which one is causing the strain. Good luck, bro!
Re: High CPU load after upgrade 1.34 -> 1.36
Thank you. The biggest change to me was merge of zma and zmc processes according to change log, but developers should have better insight. Maybe it is something with encoding/sending data to web browser.
Here are more details about our system: We have 5 computers running 5-6 cameras onscreen non-stop within Firefox web browser. 40% cameras are 640x480 resolution, 40% HD and rest FullHD all are 25FPS. All cameras are streaming h264 passthrough and not saving jpegs. All cameras are modect with Analysis FPS set to 5.
After downgrade to 1.34 is all fine all the week:
Here are more details about our system: We have 5 computers running 5-6 cameras onscreen non-stop within Firefox web browser. 40% cameras are 640x480 resolution, 40% HD and rest FullHD all are 25FPS. All cameras are streaming h264 passthrough and not saving jpegs. All cameras are modect with Analysis FPS set to 5.
After downgrade to 1.34 is all fine all the week:
Re: High CPU load after upgrade 1.34 -> 1.36
In addition, here is network usage graph, incoming traffic from cameras is 200Mbit/s and is +- constant, outgoing traffic is to the 5 PCs used by surveillance personnel and varies upon stuck live video in browser windows on those computers. The CPU load is not dependent on count of connected clients with Zoneminder 1.34 as can be seen here.
- Attachments
-
- Screenshot from 2024-09-17 13-19-43.png (50.79 KiB) Viewed 1290 times