Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

We're trying to find a bug that will cause multiple PHP processes to be run at the same time and thus eating up the CPU resources for around 5 minutes. During these 5 minutes, our server will totally inaccessible.

We can't seem to replicate the problem and not to mention seeing the same problem on our staging server. My question is will installing xdebug on our production server help us finding the root of the problem? Will xdebug affect our production servers performance?

Regards Joe Thong

share|improve this question

migrated from stackoverflow.com Nov 13 '10 at 1:37

This question came from our site for professional and enthusiast programmers.

    
@OMG Ponies, it is very likely that there is a code issue causing the high cpu issue. @user504789 I'm confused as to if it is happening on both servers or simply there production server? –  evolve Nov 11 '10 at 17:07
    
You could check out some testing tools: opensourcetesting.org/performance.php I think this might work for your testing: p-unit.sourceforge.net but have never used it myself –  Phill Pafford Nov 11 '10 at 17:39
    
@evolve, we are still not able to replicate this on the staging servers. –  sujoe Nov 12 '10 at 3:22

1 Answer 1

in apache, set ExtendedStatus On if u have mod_status compiled - http://httpd.apache.org/docs/2.2/mod/mod_status.html#extendedstatus

with this, u able to monitor what are the URL that causing the infinite loop or spawn multiple background processes

or even simpler, log the time taken for apache to serve a single page - http://httpd.apache.org/docs/2.2/mod/mod_log_config.html %D or %T and diagnose the log file

share|improve this answer
    
thanks, but I forgot to mention we're using IIS 6, any similar tools or options? –  sujoe Nov 12 '10 at 3:23
    
@sujoe : it should has mod_status compiled, try apache -l to list module compiled, or simply start tracking the page processing time in your apache log –  ajreal Nov 12 '10 at 4:38

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.