I am working on a tiny little PHP project for a friend of mine, and I have a WAMP environment setup for local development. I remember the days when the response from my local Apache 2.2 was immediate. Alas, now that I got back from a long, long holiday, I find the responses from localhost
painfully slow.
It takes around 5 seconds to get a 300B HTML page served out.
When I look at the task manager, the httpd
processes (2) are using up 0% of the CPU and overall my computer is not under load (0-2% CPU usage).
Why is the latency so high? Is there any Apache setting that I could tweak to perhaps make its thread run with a higher priority or something? It seems like it's simply sleeping before it's serving out the response.
localhost
resolving properly DNS-wise?ping localhost
should come back instantaneously with127.0.0.1
.http://localhost/index.html
)? If not, it might be a PHP issue, not an Apache issue.strace
andtcpdump
are useful tools for this.