I wanted to stress test by webserver. Here is how i want to do it.

I have 'u' different urls on my webserver. so i need to hit these urls in parallel, with a hit rate of 'n' hit per second, per url.

what would be the best tool to do this ?

link|improve this question

feedback

2 Answers

up vote 0 down vote accepted

Try httperf utility.

Here is its usage example:


httperf --hog --server foo.bar --num-conn 100 --ra 10 --timeout 5 --uri /test

This asks foo.bar 100 times for URI /test with fixed rate 10 connection per second. If you want to ask different URI's, run many httperf instances in parallel mode with different --uri parameters.

link|improve this answer
httperf is cool, but I keep getting segfaults for heavier tests. --ra 10 is fairly low. – Tudorizer Aug 24 '11 at 9:11
feedback

Your title suggests that you have jmeter which is how I would do it. Create a test plan that has all the URLs in a Random group with a percentage matching your usage statistics (if you have any, otherwise just stick with an even distribution). Then set up a user to hit pages every n seconds (depending on how much text is on each page users will stay there between 4 and 40 seconds) and set it up to ramp up to a very large number of users. The only problem with jmeter is that it will sometimes overwhelm its own host before it overwhelms the webserver. Also, you need the machine you are testing and the machine you are testing with to be on the same LAN segment to take out the possibility that bandwidth is affecting your results.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.