Benchmarking Utilities – I Ditched ApacheBench for Siege

ApacheBench [1] was an obvious choice for my benchmarking related tasks, at least until I ended up spending almost three hours trying to figure out why I kept getting “apr_poll: The timeout specified has expired (70007)” errors… it turns out there is a hardcoded 30 seconds on socket timeout value [2].

I’ve moved on now, I am using Siege [3]; it’s perfect for my current needs –specifying concurrency and repeatation couldn’t be any easier. The only downside is that the unit of measurement isn’t flexible… it’s seconds all the way. Running it in verbose mode makes automation even easier; in the example below, I ran Siege with single concurrency for a total of five times with a delay of 5 seconds between each repeatation.

siege -c1 -r5 -d5 http://localhost/OAI-XMLFile-2.21/XMLFile/w15/!!!oai_dc!1638000

** SIEGE 2.70
** Preparing 1 concurrent users for battle.
The server is now under siege...
Transactions:		           5 hits
Availability:		      100.00 %
Elapsed time:		     8069.88 secs
Data transferred:	        0.97 MB
Response time:		     1610.38 secs
Transaction rate:	        0.00 trans/sec
Throughput:		        0.00 MB/sec
Concurrency:		        1.00
Successful transactions:           5
Failed transactions:	           0
Longest transaction:	     2114.21
Shortest transaction:	     1378.94
HTTP/1.1 200 2114.21 secs:  204270 bytes ==> /OAI-XMLFile-2.21/XMLFile/w15/!!!oai_dc!1638000
HTTP/1.1 200 1587.04 secs:  204269 bytes ==> /OAI-XMLFile-2.21/XMLFile/w15/!!!oai_dc!1638000
HTTP/1.1 200 1499.58 secs:  204269 bytes ==> /OAI-XMLFile-2.21/XMLFile/w15/!!!oai_dc!1638000
HTTP/1.1 200 1378.94 secs:  204270 bytes ==> /OAI-XMLFile-2.21/XMLFile/w15/!!!oai_dc!1638000
HTTP/1.1 200 1472.11 secs:  204270 bytes ==> /OAI-XMLFile-2.21/XMLFile/w15/!!!oai_dc!1638000