Alan’s Blogometer

Alan Gutierrez blogs on software, social networks, and himself.

Subscrive Via RSS Feed

Diagnosing Server Overload

My server, ljubljana.blogometer.com, will sometimes hang after receiving too many requests. I don’t want it to keep me from getting in via ssh, so I’ve written a rather drastic shell program to monitor the server. It fetches the blogometer.com home page using curl. If it takes longer than three seconds, it blocks port 80. This is run by cron every minute. The script will write out the output of the programs ps ax and free. I’ve not been able to figure out what’s really causing the server to choke with that output so I’ve added top -n 5 -b and tail -n 500 /var/log/httpd/access_log. I’m open to any suggestions of commands to add to this snapshot.