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

Apache noob here. I have a virtualbox instance with debian squeeze installed and apache. I'm seeing all 4 of my cores max out for about 10 minuets then it goes away. This is happening a few times per week. When I'm able to load top I can see apache processes maxed out.

/usr/sbin/apache2 -k start

When I check the access log I'm not seeing a huge amount of traffic. I installed mod_evasive last week thinking they might have been a ddos or bot hammering on login pages but I can't see that in the logs. I'm suspecting there might be some bad php code somewhere. How would I go about tracing where that might be?

The web server is hosting about 4 wordpress sites for a small business and another php application with about 10 users.

I've ensured i've updated debian. I'm running on the latest wordpress.

share|improve this question

2 Answers 2

Use mod_status to see status page. There are list of all current running requests with additinal detail, if you enable extended status.

share|improve this answer

about to -1 for Apache noob here ;)

You may see something in the access.log. If a single php script is running for a long time, then you will see the log line when the process ends, with the time the script started.

For example:

<?php
  sleep(120);
  echo "hi";

started at 15:00 will generate a log entry at 15:02 with the timestamp 15:00.

share|improve this answer

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.