Why is it slow?

I have a dedicated server with essentially a single site. It's fairly heavily trafficed - over 500K page views a day. The site is largely (80%+) dynamically generated with servlets and MySQL. The database is actually on another machine.

Most of the time the server is blazingly fast. Sub second responses. During the afternoons (peak usage time) it slows to a virtual crawl with 10 and even 20 second responses.

The thing that I'm trying to figure out is why. Even during slow times I'll usually see a load average under 1 and over 50% free cpu. Pings and traceroutes are still just as fast as other times. The server is otherwise just as responsive - ssh sessions, compiles etc show no slowdown.

During a slowdown stopping and restarting apache seems to have little if any affect.

Server is a pIII w/ 512M, redhat 7.1, apache 1.3.27, java 1.4.1, tomcat 4.1.12, php 4.2.3

Any ideas? I'd assume the load was just too great for the machine except for the fact that everything other than web serving is pretty much still fast. Serving all pages is slowed even static pages and/or php pages that don't access the DB.

Need more memory? free says:
mem total 512640 used 506716 free 5924
+/- buffers/cache: used 470300 free 42340
swap: total 530104 used 89756 free 440348

 

 

 

 

Top