3

I have been requested to perform load testing for website and after that decision to purchase new server will depends on me so I do not want to take any wrong decision or risk.

Requirement:

1 - Put load on 15 pages

2 - Delay/Interval between 2 threads/users 30 seconds

3 - Start with number of users 15 [Will increase till 50 step by step]

4 - Run Test for 30 Minutes

My test plan:

1 - Added Thread group with Number of threads : 15, Ramp-up Period [Seconds] : 1800 , Loop Count : 1

2 - Added HTTP Request Default

3 - Added Cookie Manager

4 - Added HTTP request for all 15 pages

5 - Added Constant timer with every request with milliseconds: 30000 [Is this correct? will it put 30 seconds delay between every 2 threads/users?]

6 - Added Listener: View Result Tree with every request

7 - Added listeners: Summary report, Spline Visualizer as a common listener.

So my questions are simple:

1 - Is above test plan is correct based on requirements?

2 - Do I need to add more listener or plugin to get a more detailed report of load testing?

I just want to ensure above as I need real performance result so that based on the result we can optimize our server or purchase a new high configurable server to handle more users.

  • Why you added 1800 seconds as RampUp? – Dhiman Sep 4 '15 at 13:01
  • Because we need to run load testing till 30 minutes. – Helping Hands Sep 4 '15 at 13:59
  • @HelpingHands, Do you use HTTP sampler or custom Java sampler? – Pacerier Sep 10 '15 at 8:32
  • @Pacerier- I am using HTTP Sampler. – Helping Hands Sep 10 '15 at 8:36
2

I will your plan is right for most of the things, I am listing down only those things which you need to add/update.

  1. Add Cache Manager
  2. Taking care of Timers: Note that timers are processed before each sampler in the scope in which they are found.
    • So if you want to delay each user by 30 seconds for All 15 pages, then you should add this Constant Timer at the end/start of Thread Group/Controller and all your HTTP Request of 15 pages should be inside one Controller. It will execute like this

enter image description here

  • Now second scenario if you want to delay each of the 15 page requests by 30 seconds for each user, then add this Timer as child element of each HTTP Sampler, by this way every user will pause for 30 seconds before clicking on the next page. If each page is in a separate Controller then add Timer as child of the first request inside the Controller. (I think this is what you want to achieve)

enter image description here

If you want hybrid of both scenarios, then using RampUp time will help you (which you have already used)

Timer is for delay between Requests/pages and RampUp is for delay between users.

  1. Now the next thing, which I think is missing in your plan as per the requirement is 'Running script for 30 mins.' For this you can either use 'Jmeter Scheduler' or you can use the command 'jmeter -Jduration=1800 -n -t /path/to/your/test/plan.jmx'. This will let your script to be executed only for 30 mins. Duration provided is in seconds.
  2. RampUp time which you have used as 1800, this you have used for the purpose of running script for 30 mins., but this is not the intent of RampUp or you can say RampUp is not used for this purpose, this should be used for providing delay among Threads.
  3. Use the Perfmon Metrics Listener this will provide the value of CPU, Memory etc. of the server which is being loaded. For this you will need to install the Jmeter Plugin (on JMeter machine) and Server Agent (on server)
  4. Once script is final, Disable or Delete the Tree Listener, as this heavy listener and will slow down JMeter processing.
  5. Run your scripts in non-GUI mode, using the Command Line or the Batch file.
  • Hey thanks for answer and helpful update , I have question that if I use first scenario then I will need to add 2 thread groups? – Helping Hands Sep 4 '15 at 14:05
  • No, need to add 2 Thread group, just add your timer at the start of Thread group i.e. Add this add this as child of the First Request only, then each user entering the plan will wait for 30 secs then jump to Page 1, 2, 3.... without any delay. But if you want next user enters after 30 secs of last user, then you need to add RampUp. – Dhiman Sep 4 '15 at 14:28
0

What "load" you're talking about? Given request per 30 seconds 15 users will execute 900 requests in 30 minutes - 0.5 request per second. 50 users will execute 3000 requests in 30 minutes - 1.6 requests per second.

If your current server is capable of handling this load - you can postpone acquiring a new one for now.

If you need to know how many requests per second your server is capable to serve with reasonably low response time - you can use Constant Throughput Timer or Throughput Shaping Timer (if you need stepping load)

  • Actually our goal is run test for 30 minutes with 15 users and there should be gap of 30 seconds between 2 requests. – Helping Hands Sep 5 '15 at 14:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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