0

I'm experiencing a problem with a php/apache install on debian lenny. At random times during the day it will stop servicing request for .php pages, but static pages (html/css etc.) continue to work. There is no useful information in the apache or php error logs. There are ~40 sites running on this server, so I can't even tell which site is causing the problem.

Does anyone have nay ideas on how to troubleshoot this problem?

Thanks

3 Answers 3

0

Very odd behaviour and not a lot of information to go on. What do you mean by 'it will stop servicing request for .php'? You get no response? An error? the unparsed PHP file? Something else?

Based on the information you've provided, the only way to progres this would be to setup some automatic polling of a simple PHP page - e.g. using nagios

2
  • It will timeout. I've already setup monitoring, so I'll know when it happens, but I'm not sure how to proceed from there. How can i identify which of the apache instances is misbehaving? Can I somehow get a list of resources used by that instance? etc.
    – jw.
    Jun 22, 2011 at 11:48
  • Update: I've dumped the status of apache while it was hung: pastebin.com/QZiXxkyX As you can see it apparently keeps spawning new apache processes that all keep hanging until it can't spawn any more new processes. I guess there's some php code that's called that somehow hangs the interpreter without crashing it, and everytime it's called it spawns a new apache process that immediately hangs.
    – jw.
    Jun 22, 2011 at 13:36
0

Are you swapping out/using up your memory? How is disk space looking?

If you are using database, can you make a successful connection to it when this happens?

Are you running as FCGI? If so, does garbage collection remove socket created within /tmp/ space?

0

To try narrow the problem down to a specific vhost, I would suggest adding the 'ExtendedStatus on' directive for mod_status1. This will report the virtual host names in the mod_status report which you pastebin'ed. Once you've narrowed down which vhost is misbehaving you may want to install and enable Xdebug 2(a PHP profiler/debugger). Debug should let you know which bit of code is blocking/causing issues.

Hope this helps.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .