Results 1 to 10 of 10
Thread: httpd Processes sticking around.
-
09-24-2009, 09:09 PM #1Web Hosting Master
- Join Date
- Dec 2006
- Posts
- 597
httpd Processes sticking around.
I've been having a problem for the past few days where a few httpd process will just start and stick around using a ton of CPU. The only way to make them go away is to restart apache and kill the individual processes.
I have seen it as high as 5 of these doing this at once. They are running about 90 - 100% CPU usage and causing the sever load to increase.
I have never seen this, I did not change anything with my apace config so I don't understand why all of a sudden I am having this problem
I have attached a screen shot of top. Does anyone have any idea's on things to try to figure out what is causing this?
ThanksSpeedSmart.net - The ultimate HTML5 internet speed test & App
-
09-25-2009, 04:04 AM #2Junior Guru
- Join Date
- Oct 2008
- Location
- Chicago, IL
- Posts
- 222
When you kill apache, do you have to kill these high load processes separately?
Almost as if they're not associated with apache? Or am I reading too much into this?
How soon after you kill apache do they start running high loads on the cpu?
What is the StartServers directive in httpd.conf set to? How many websites on this server?
Sorry for all the questions. Just trying to help.Thomas J. Raef
WeWatchYourWebsite - so you don't have to!
-
09-25-2009, 04:18 AM #3Junior Guru
- Join Date
- May 2009
- Location
- On a Speck!!!!!
- Posts
- 216
Is the Apache compiled as Prefork module or worker module?
-
09-25-2009, 06:20 AM #4Web Hosting Master
- Join Date
- Oct 2004
- Location
- Kerala, India
- Posts
- 4,771
Did you check the apache status page to see if any particular site is having more connections? Also have a check of the server for ddos attack.
David | www.cliffsupport.com
Affordable Server Management Solutions sales AT cliffsupport DOT com
CliffWebManager | Access WHM from iPhone and Android
-
09-25-2009, 08:55 AM #5Temporarily Suspended
- Join Date
- Jul 2009
- Posts
- 178
strace -p pid where pid is of the http process consuming max cpu.
You can find the domain which is consuming max resources.
-
09-25-2009, 09:20 AM #6Web Hosting Master
- Join Date
- Dec 2006
- Posts
- 597
I can kill each httpd process that is doing this separately or I can kill them all by restarting apache.
Most of the time its about an hour or so before 1 comes back again. But overnight I will come back and have several.
My httpd looks like this
KeepAlive On
MaxKeepAliveRequests 1000
KeepAliveTimeout 20
HostnameLookups off
ErrorLog "logs/error_log"
DefaultType text/plain
AddType text/html .shtml
<IfModule prefork.c>
StartServers 4
MinSpareServers 2
MaxSpareServers 4
ServerLimit 2050
MaxClients 1500
MaxRequestsPerChild 10
</IfModule>
Its prefork
There is only one site running on this server and from checking around there isn't a abnormally higher number of connections, or usage of something. Everything is the way its suppose to be except this.SpeedSmart.net - The ultimate HTML5 internet speed test & App
-
09-25-2009, 09:52 AM #7Web Hosting Master
- Join Date
- Feb 2005
- Location
- India
- Posts
- 1,073
What script is running. Did you check cpu usage option of WHM (assuming your running whm/cpanel), to see what process/script/path is causing the load. I have a feeling its an insecure or buggy script (forum or live support system)?
-
09-25-2009, 10:50 AM #8Web Hosting Master
- Join Date
- Dec 2006
- Posts
- 597
Using both of those I think that I may have found the problem.
I run a custom script for my file hosting site, and when a file is uploaded there is some stuff done to it and its put in a special location on the server outside the public_html dir to keep things safe.
But there was one dir with like 10 files missing and anytime someone requested a one of those files, The php script that I use to get and do all the special things to the file so a user can download it, was going nuts looking for the file 100,000's of times.
stat64("*********/ufiles/997/0/997/47937bd9c80cd9.70867069", 0xbfc0d3a0) = -1 ENOENT (No such file or directory)
Hopefully this is it, I've had too many sleepless nights trying to figure this out.
Thanks to everyone who helped.SpeedSmart.net - The ultimate HTML5 internet speed test & App
-
09-25-2009, 10:52 AM #9Web Hosting Master
- Join Date
- Apr 2004
- Location
- UK
- Posts
- 1,334
Correct me if I am wrong, but by default httpd keeps a pool of processes (a worker pool) open to save on launch latency. Work is then farmed out to these processes.
.
» Kayako customer service software and live chat software- your customers deserve better than helpdesk
-
09-25-2009, 11:05 AM #10Web Hosting Master
- Join Date
- Dec 2006
- Posts
- 597
SpeedSmart.net - The ultimate HTML5 internet speed test & App
Similar Threads
-
httpd processes running top or ps?
By joeshacks in forum Hosting Security and TechnologyReplies: 2Last Post: 02-05-2008, 04:12 AM -
Why so many Httpd processes?
By the_go_453 in forum VPS HostingReplies: 3Last Post: 04-19-2007, 12:47 AM -
5 Httpd processes?
By runes911 in forum Hosting Security and TechnologyReplies: 9Last Post: 04-13-2005, 05:10 PM -
httpd processes out of hand?
By JSH-John in forum Hosting Security and TechnologyReplies: 7Last Post: 02-01-2004, 10:56 AM -
httpd processes
By phuture in forum Dedicated ServerReplies: 1Last Post: 02-03-2002, 02:01 AM