Without knowing the exact number of Load Generators required to conduct a performance test without having any test resource constraints, the results of that performance test could be anywhere from skewed at best to completely invalid at worst if not enough test resources were allocated. For example, if four Load Generators were required, but instead the test was executed with only two Load Generators, the over consumption of resources on these two Load Generator machines will likely degrade the effectiveness of the anticipated workload these Load Generators were expected to deliver. These machines will bog down over the course of the scenario, thus losing control over the pacing and throughput of the performance test.
Follow these steps to calculate about how many Load Generators will be required for any given HTTP/Web protocol performance test:
- First, record and enhance the script to work with multiple users and iterations.
- Once the script is ready, after noting the current memory footprint of the Load Generator, run the test with only one Virtual User (Vuser) and observe the amount of memory consumed by this one process after the Vuser process has leveled off and is running at a steady state.
- Now run the test iterating with five Vusers. Keep the same starting delay and add each Vuser one at time with about a one-minute or so delay before the start of the next Vuser and observe how much RAM is consumed for each Vuser added to the test execution.
- Make sure to consider reserving around 750 MB to 1 GB of memory for operating system resources.
- Calculate the 75 percent of remaining RAM after including the RAM for system resources. For example, if the machine has 4 GB of RAM, and 1 GB is removed from our calculation for system resource allocation, the remaining 3 GB is 75 percent of the remaining memory.
- Subtract the memory allocated for the first Vuser.
- Divide by the average of the last 4 Vusers.
- Finally, re-add the footprint amount from the first Vuser.
Please note that this process is a basic reference, a generic starting point to determine test resource allocation for a performance test. It may not work quite exactly the same on all applications or for some of the other protocols like Citrix, RDP, or other GUI-based protocols like QTP / UFT scripts. As of LoadRunner 12, there is now a Load Generator calculator. See how comparatively close the outcomes of both of these approaches are to one another.