Simple HTTP Load Testing with Siege on SuSE

Load Testing doesn't have to be complicated, Enjoy it using this one!

If your looking to do Load Testing on your web server, you can do things manually with wget, curl, role your own or use a tool called Siege that does what a lot of other expensive tools don't, which is do what you expect and do it right.

Siege, is an open source load-testing and benchmarking utility that will help stress test your web platform before exposing it to the real world. It really shines for its simplicity and usability. There is no pre-package for it on SuSE as there are on Debain and Ubuntu, so you'll have to grab a copy of the tarball and compile it yourself.

Once you have a working installation, you will need to give siege a configuraton file by issuing the command:


siege.config

You can view it by:


siege -C

Ok, remeber to use this stress test tool on your site and not on any other web site out on the web! To get started let's say you want to simulate about 100 simultaneuos users every 12 or less seconds or so, accessing a particular URL. Go ahead and try this:


siege -d12 -c100 http://mysite.com/something.php

'd' specifies a random interval between 0 and some number, in our case , 0 and 12 seconds.

'c' is the amount of simulated users, in this case 100. Siege is also able to test multiple URL's by a file listing and randomly accessing each URL. When you want to test more options go ahead and man 'siege'.

When your finished testing, Siege will give you a tally of the results and a summary can be found at /usr/local/var/siege.log:


Example:

Lifting the server siege...      done.

Transactions:                   1516 hits
Availability:                 100.00 %
Elapsed time:                 156.89 secs
Data transferred:              40.07 MB
Response time:                  0.01 secs
Transaction rate:               9.66 trans/sec
Throughput:                     0.26 MB/sec
Concurrency:                    0.07
Successful transactions:        1516
Failed transactions:               0
Longest transaction:            0.73
Shortest transaction:           0.00

FILE: /usr/local/var/siege.log
You can disable this annoying message by editing
the .siegerc file in your home directory; change
the directive 'show-logfile' to false.

That's it, Load Testing doesn't have to be complicated, Enjoy!


Peace be unto you. Thank you for visiting!