JMeter – Load Testing a Website

For some reason I’ve always shied away from load testing. Its been something I’ve considered to be a black-art, requiring some specialist skills. Anyway, I need to load test a website, and was told about JMeter. Half hour later I’d completed my (simple) tests. Massive thumbs up from me for JMeter!

What follows is a very quite how to for just load testing a simple website. JMeter looks like its capable of so much more, but this is all I required at this stage.

1. Download JMeter (http://jakarta.apache.org/site/downloads/downloads_jmeter.cgi)
2. Unzip the file and then look in the bin directory and double click the ‘ApacheJMeter.jar’.
3. Right click on the test plan and add a Threads(Users)->Thread Group. For the 1st test I simply put 10 threads starting in 5 seconds.
4. Under this Base Group add a Sample->HTTP Request and set up the call to the web server (with the various parameters). One thing I got wrong here was pre-fixing the server address with http://
5. Go to File->Save and save the set up.
6. Then click Run->Start and watching the green box on the right hand side (and also the thread count). Note – I found that my Java web app struggled when it hadn’t previously been run (presumably compiling for the first time). After this I had no issues.

Like I said to start with, so simple and straight-forward – no black art, and something I wish I’d taken 5 minutes to play around with long before now.

References:

Not many, which I think speaks volumes. Normally when trying out new tools I have to Google everywhere to find out everything. JMeter had everything I needed directly on their site.

JMeter Getting Started: http://jakarta.apache.org/jmeter/usermanual/get-started.html

Advertisements

3 thoughts on “JMeter – Load Testing a Website

  1. Pingback: Selenium « Gregor Bowie's Blog

  2. Pingback: Performance Testing with JMeter 2.9 Book Review | Gregor Bowie's Blog

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s