How to benchmark apache+php

This is to see whether you server is CPU-bound or RAM-bound.

We have to stress it and see which one of those components gets saturated first.

If that is the RAM, we can add easily more RAM. The amount of RAM to add depends of the share of the CPU that can still be used before the website becomes slow.

ab -n 300 -c 1 http://www.mywebsite.com

This are the command to run during the stress test

_ uptime

_ free

_ ps -ylC httpd –sort:rss > number_of_apache_processes.txt

_ netstat -nt | grep :80 | wc -l

And obviously check how quick the website is.

This entry was posted in Apache, PHP, System Administration. Bookmark the permalink.

Leave a Reply