Page 1 of 1

hundreds of httpd processes

Posted: Mon Apr 27, 2009 8:51 am
by rsdvd
Hi All

I have recently moved my zoneminder server from an old machine to a new 1.24.1 instance, and I am seeing a strange problem.

Everything seems to be set up fine, using my 8-chip SAA7130 card and currently 6 cameras.

However, when I watch them through 'montage' the server quickly produces 258 differnt httpd processes (maximum for my apache config) and then locks up apache, stopping the console and montage web pages.

The only way I can get out of this is to restart apache.

Does anyone have any ideas where to start looking?

Thanks in advance

Phil.

Posted: Mon Apr 27, 2009 8:53 pm
by MrEvoMan
Your httpd.conf or apache2.conf file will have Min and Max number of server setting. Let me see if I can find the line....

Something like this:

Code: Select all

MinSpareServers 5
MaxSpareServers 10
StartServers 2

Posted: Wed Apr 29, 2009 10:34 am
by rsdvd
thanks for the reply, but I know about the apache process limits - these are already set to sensible figures.

After more investigation it seems the problem arrises if 1 of my cameras srews up.

I get a

Code: Select all

 INF [Got signal 15 (Terminated), exiting]
in the syslog and 1 of the monitors stalls with a fixed image, however the montage window seems to keep requesting images from zoneminder which causes a new httpd process for each image.

It does not take long for it to reach the maximum number of processes (ServerLimit), which then hangs zoneminder.

The only way to release the httpd processes is to restart apache.

Has any one else seen this before? The answer is probably to fix why my cameras screw up, but I don't think zoneminder should lock up liek this.

Thanks in advance

Phil.

Posted: Wed Apr 29, 2009 1:21 pm
by newvisionantenna
Try out jZMConsole and don't even use the montage view. Just a suggestion and it's working great with my setup.

Posted: Wed Apr 29, 2009 1:34 pm
by arekm

Posted: Wed Apr 29, 2009 2:19 pm
by rsdvd
Try out jZMConsole and don't even use the montage view. Just a suggestion and it's working great with my setup.
This looks interesting, and seems to work really well - however I still need access to the web montage as I have several webonly frontends to view the cameras.
I tried this, and it did not seem to fix my issues, when the cam crashed it still kept starting new httpd processes untill apache refused to create any more.

duplicated topics

Posted: Mon May 04, 2009 6:24 pm
by henriquejf
In an effort to solve, or even organize related problems, i am asking users experiencing **APACHE HANGS** to double check what has been tried before by other users, so we don´t loose our time and get things working as expected;

I am not even sure that it is a ZM bug, but i am sure that many people have to restart apache from time to time, just as me; One user found it useful to restart apache as a cron job every x minutes, another user proposed to use http://jzmconsole.securitykit.net/ as a workaround for the problem when it happens in the montage view, but i am sure that we´ll have that fixed soon by the community, so we don´t have to give up and try the mentioned workarounds;


apache hanging problems - related, duplicated (or not) topics
==============================================================


** Maxopenfile reached & machine hangs zm problem ?
http://www.zoneminder.com/forums/viewtopic.php?t=13486

** apache not responding
http://www.zoneminder.com/forums/viewtopic.php?t=13322

** Apache instances/responsiveness issue...solved(?)
http://www.zoneminder.com/forums/viewto ... c&start=15

** Zoneminder UNSTABLE & HANGS, needs frequent restarting
http://www.zoneminder.com/forums/viewto ... 1196#51196

** hundreds of httpd processes
http://www.zoneminder.com/forums/viewtopic.php?t=13588


If some experienced programmer could give us a light, it would be so kind !!

Posted: Mon May 04, 2009 6:46 pm
by mitch
I have a patch that I will release later today that may address part of this for anyone who has extra apache processes due to zms not terminating correctly when not in use should see some relief but that certainly doesn't sound like everyone described in the threads.

Posted: Mon May 04, 2009 10:09 pm
by cordel
pretty sure we have this fixed up in SVN but shoot us the patch just in case so we can make sure for the next release.

Posted: Wed May 06, 2009 9:42 am
by rsdvd
Cordel

I have just upgraded to the SVN verison, and I can confirm that it does fix this issue.

I don't get hundreds of httpd processes any more.

Thanks

Re: hundreds of httpd processes

Posted: Sun Jun 26, 2011 9:34 am
by Maklaut