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.

I'm somehow a newbie on sysAdmin.

I have a Dedicated Server @Mediatemple and they're not supporting me on this issue.

So far I had an issue with MySQL Expensive Queries and I found a way how to determine which PHP Application is querying large amount of data which we don't need.

My issue now is ,that I can do a "ps aux" and I can see that a "httpd" service is consuming CPU and Memory more than others ,but I can't find out which vhost or application is doing that.

So is there a way how to find out from the HTTPD process, which application is causing that.

PS Our OS is CentOS 5.x with Apache2 and PHP5.

share|improve this question
add comment

2 Answers 2

up vote 3 down vote accepted

You could check your access.log to see which URLs are requested the most.

If you need real-time information, you should configure mod_status. It tells you what queries apache is currently working on.

share|improve this answer
    
With ExtendedStatus On, mod_status will tell you which PID is processing which URL and how long it has been processing for. –  Ladadadada May 3 '12 at 13:32
add comment

You can use New Relic and set newrelic_set_appname (string) so that each of your applications will provide performance metrics.

share|improve this answer
add comment

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.