May 22, 2017

HTTP load testing using ApacheBenchmark and Httperf

In this article I will show some http load testing examples using two useful webserver benchmark tools, ApacheBenchmark (called ab) and Httperf.
It’s important to note that both benchmark tools do not work like a real browser but they only test the standard http payload of the web application. This means that are not loaded the assets like images, javascript or css but only the rendered HTML of the URL under test. For example, suppose we want to test the url http://mywebserver/index.html. Here is the html source of index.html page.

During test, only the index.html source page are requested, the resources “jquery.min.js” and “image.png” are not loaded. Both AB and HTTPERF can test against concurrent connections, number of loads per connection, and give understandable results. In more advanced usages Httperf also allows the creation of a series of URIs to pass, to emulate a single session. The “wsesslog” option can be used to generate a specific sequence of URI accesses. This specifies a session workload generator instead of individual requests, including the number and sequence of URI’s, request method, think-time and burst-length parameters.

There are some others advanced test tools like Siege, Jmeter, or OpenSTA which simulate a “real” usage of a web site, but will not be covered in this article. Let’s see some examples of AB and HTTPERF use.







Related posts

Leave a Reply

Your email address will not be published.