Custom montage killing my ZM server

Forum for questions and support relating to the 1.25.x releases only.
Locked
gregom
Posts: 42
Joined: Thu Jun 25, 2009 7:25 pm
Location: US of A - what's left of it...

Custom montage killing my ZM server

Post by gregom »

I am testing ZM 1.25.0 on Ubuntu 12.04.2 64-bit. This is a custom build my boss made but neither of us have much linux knowledge. My server is running two AMD quad-core Opteron's with 4 GB DDR2 memory and 4.5TB of storage from four 1.5TB drives in RAID-5 on a HighPoint RocketRaid 2320.

I have 16 cameras to test with, but unfortunately they are not all the same. I have 12 IP cameras, six are an older Bosch and the other six are a Toshiba. I also have four Viacom analog cameras each supporting 480 NTSC TV lines. The system performed well with all 16 cameras recording at 320x240 at 5 fps. I had two solid weeks of recording with no problems.

Now i've changed the cameras to 640x480 (some are 704x480, and the analog cams are 768x480). I kept the 5 fps but my server is struggling to handle it with my custom montage webpage I just started working on. It seems to be running fine with the ZM montage view, but when I use my custom montage the web server stops responding to everything else and I get the following errors in the log. I have to stop or close our of my custom montage to get the web server to respond to other requests. It is so tied up I can't even click on a camera to get the full view, but if I close the custom montage view then everything returns to normal.

Here are two of the errors that are showing up in my logs:

Code: Select all

2013-05-03 12:46:32.642331	zms	2272	ERR	Terminating, last frame sent time 1367606792.531540 secs more than maximum of 10.000000	zm_monitor.cpp	3639

Code: Select all

2013-05-03 12:50:05.306446	zms	2305	INF	Got signal 15 (Terminated), exiting	zm_signal.cpp	44
Is this just caused by how i'm calling for it? I'm not sure what exactly is the problem is here... Below is my HTML code for my custom montage:
I obtained the code from http://www.zoneminder.com/forums/viewto ... 29&t=20870 since i'm going to be testing authentication later.

Code: Select all

<html>
<head>
        <link rel="shortcut icon" href="/cctv.ico" />
        <title>Test DVR</title>
</head>
<body bgcolor="black">


<table align="center">
 <tr>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=24" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=24&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=25" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=25&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=26" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=26&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=27" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=27&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
 </tr>
</table>



<table align="center">
 <tr>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=28" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=28&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=29" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=29&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=30" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=30&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=31" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=31&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
 </tr>
</table>



<table align="center">
 <tr>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=32" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=32&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=33" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=33&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=34" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=34&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=38" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=38&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
 </tr>
</table>



<table align="center">
 <tr>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=35" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=35&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=36" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=36&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=37" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=37&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
   <td><a href="http://10.0.0.7/zm/index.php?view=watch&mid=39" target="_blank">
        <img src="http://10.0.0.7/cgi-bin/nph-zms?mode=jpeg&monitor=39&scale=58&maxfps=5&buffer=1000&buffer=1000connkey=000000buffer=1000&rand=0000000000"></a></td>
 </tr>
</table>


</body>
<html>

I have no idea what buffer=1000 is for, and why there are two of them but no "&" between it and "connkey=000000". I also don't know what rand= either. What is this code for? I tried to look it up on the web but wasn't finding anything. In addition to the performance issues, I only see the first six cameras when viewing my webpage. So there must be some limit on the ZM server i'm hitting with my requests.
Flasheart
Posts: 342
Joined: Thu Jul 06, 2006 2:27 pm

Re: Custom montage killing my ZM server

Post by Flasheart »

What's the load on the server during this?

In case that's what's going high, take a look at http://www.zoneminder.com/wiki/index.php/IpCamMontage which is similar, but takes mjpeg feeds directly off the camera.

This will move the streaming of all your ip cams off the server, and you can view your analogues via zm as per your example.
gregom
Posts: 42
Joined: Thu Jun 25, 2009 7:25 pm
Location: US of A - what's left of it...

Re: Custom montage killing my ZM server

Post by gregom »

Thanks for the reply. I watched using the top command and at first attempt the load didn't change when I open my custom montage webpage. But I can't get a response from my server for anything else. I think the Apache webserver is tied up with max connections or something. I tried again later and the system load went up to 8-10. Then I started getting buffer overrun errors in the log.

I like the idea of pulling streams directly from the cameras, but then I lose the camera name, date and time overlayed on the video. I don't care so much about the date and time but we need to see the names of the cameras. Perhaps I can find a way to overlay text on top of the streamed images. I need to do more research on this, but if you can shed some light on this subject even further that would help.
Locked