HP Open Source Middleware Stacks Blueprint: LAMP Architecture on HP ProLiant BladeSystem Servers on RHEL

</BODY>
</HTML>
3. Perform a concurrency request to the test system by logging into another system and entering
the following command:
# ab -c 1000 -n 1000 http://<YOUR_WEB_SERVER_IP>/abtest.html
Where:
The value of the -n option sets the number of requests.
The value of the -c option sets the number of concurrency requests.
4. To monitor the access status on the test system, display the end of the access log file by
entering the following command:
# tail -f /var/log/httpd/access_log
The system displays a message similar to the following:
10.101.1.84 - - [10/May/2007:12:00:46 +0800] "GET /abtest.html HTTP/1.0" 200 206 "-" "ApacheBench/2.0.40-dev"
10.101.1.84 - - [10/May/2007:12:00:46 +0800] "GET /abtest.html HTTP/1.0" 200 206 "-" "ApacheBench/2.0.40-dev"
10.101.1.84 - - [10/May/2007:12:00:46 +0800] "GET /abtest.html HTTP/1.0" 200 206 "-" "ApacheBench/2.0.40-dev"
10.101.1.84 - - [10/May/2007:12:00:46 +0800] "GET /abtest.html HTTP/1.0" 200 206 "-" "ApacheBench/2.0.40-dev"
10.101.1.84 - - [10/May/2007:12:00:46 +0800] "GET /abtest.html HTTP/1.0" 200 206 "-" "ApacheBench/2.0.40-dev"
You can force a heavier load on the Apache HTTP Server by increasing the number of
concurrency requests with the -c option, and by prolonging the testing round by increasing
the number of requests with the -n option.
NOTE: If you encounter the following error: socket: Too many open files (24)
you can correct the error by entering the following: # ulimit -n <NUMBER>
This command increases the limit on the number of open files but only for the current shell
session. The increased limit is applicable to the newly launched commands on that shell
after the change. The commands that you launched previously continue to use the previous
limit.
Apache HTTP Server Status and Information
You can obtain various pieces of information regarding your Apache HTTP Server by configuring
the mod_status and mod_info module requests within the httpd.conf configuration file. The
mod_status module is configured using the server-status request and the mod_info module is
configured using the server-info request. For example, you can find out the current hosts and
requests being processed, whether the server was started or restarted, and basic server
configuration information. These two functions help you monitor your Apache HTTP Server.
Configuring and Using the Modules
Use the following steps to enable the mod_status and mod_info modules to collect and display
information.
1. Edit the /etc/httpd/conf/httpd.conf file and add the following lines:
<Location /server-status>
SetHandler server-status
Order deny,allow
Deny from all
Allow from YOUR_WEB_BROWSER_IP
</Location>
<Location /server-info>
SetHandler server-info
Order deny,allow
Deny from all
Allow from YOUR_WEB_BROWSER_IP
</Location>
Installing, Configuring, and Managing LAMP Middleware Stack Components 11