Frequently I will be getting this question to my mailbox, forums and even in calls. How to calculate number of virtual users (VUsers) for load/stress testing? What should be the concurrent virtual users to load? What should be the peak load?
25, 100, 500, 1000. We cannot give number of VUsers blindly which will not return intuitive result for analysis.
The main purpose of VUsers is to simulate the live environment. It is very tricky but easy to obtain number of VUsers required for the load/stress testing. Universal formula to calculate the arriving rate to the system is Little’s Law.
N = Z * (R + T)
where N – number of VUsers,
Z – Transactions per Second (TPS)
R – Response Time in seconds
T – Think Time in seconds
If you get the following data from the stakeholders i.e. TPS, Response Time and Think Time, number of VUsers can be calculated easily.
E.g. TPS is 100, R is 3 sec and T is 2 sec then N will be
N = 100 * (3+2)
= 100 * 5
Peak load will be 500 VUsers.
Suppose if there is no data available on TPS and Response Time, and you aware any one of the following combinations, you can use this online calculator.
- Peak Hourly Visits and Average Visit Length
- Peak Hourly Pages, Testcase Size and Duration
It is vital important to simulate the input data in load/stress testing. This online calculator provides how many data you would need for simulation.
- Unboxing HPE LoadRunner 12.55 - August 20, 2017
- Measure Client-side Performance using Lighthouse - August 10, 2017
- Perf Calculator – free iOS app for performance testers - July 16, 2017
- How to performance test AngularJS or ReactJS applications? - June 25, 2017
- How to run Apache JMeter tests with Visual Studio Team Services? - June 6, 2017