Apache process hangs
Hello happy hackers!
I have this webserver running multiple websites as virtual hosts. I suddenly noticed (using top) that some of the apache processes hang. I can narrow down the problem to a single site with the command lsof +p PID, but I can't get any closer the problem. Is there a way to get a more detailed report of similar problems? I checked my logs but sadly can't find anything useful.
Sure - many ways.
The best/easiest is to look at the access log (e.g. /var/logs/apache2/access_log) and see what the last request was, and if it had anything to do with the "hang".
The Apache error log (e.g. "error_log") should be in the same directory. Look there, too.
Other tools might include:
* lsof: see what files/ports the process is using
* tcpdump or wireshark: take a network trace when the "hang" occurs.
Who knows - maybe you'll discover that the CLIENT might be at fault ;)
* gdb: you can attach to the live, "hung" process and get a stack traceback (of exactly where it's hanging)
'Hope that helps .. and Good Luck!
Please post back what you find!
You could also use mod_status to try to get a better insight into the problem:
Thanks for the advices!
However, wireshark was the one that hunted the problem down. A php-script that was looping and looping and looping...
|All times are GMT -5. The time now is 04:39 AM.|