LoadRunner Stress Test Experience Summary

Source: Internet
Author: User

First, the effect of the time of the virtual user iteration on the whole pressure scene.

1, Virtual user iteration time is greater than or equal to the upward cycle of the pressure scene.

In this case, in the upstream cycle of the pressure scenario, all virtual users are run in sequence based on the policies set by the stress scene. After the upstream cycle of the pressure scenario, the virtual user is running in a stable period because the first running virtual user has not exited the iteration. When the first running virtual user exits the iteration, it enters the campaign period. During the campaign, there will be a virtual user on-line and offline, one after the other, but the total number of virtual users currently running close to the total number of virtual users, the actual deviation, the number of deviations and pressure scene step setting and the script sleep time. When the step of the scene is set to 0 o'clock, the time of the motion is equal to the upstream period of the pressure scene, because when the step is set to 0 o'clock, it means that the virtual user is offline on the line, which is equal to their upstream rate. After the period of exercise, it goes into a stable period because the first virtual user to run has not exited the iteration. If the end point falls to a stable period, the virtual user will not stop the iteration immediately, but will wait until the next campaign period to exit from the run. If the end time point falls in the period of motion, when a virtual user exits the iteration, the user goes offline and no longer enters the next iteration because the user is offline at the time of the campaign, so the virtual user exits the iteration according to the exit strategy set by the stress scene.

2, the virtual user iteration time is less than the upward cycle of the pressure scene.

In this case, there is no stable period, the virtual user's online line runs through the whole stress test. Assume that there are 100 virtual users, one per second, as shown in the virtual user. During the first iteration of the virtual user, the top 50 users went online. In the second iteration of the virtual user in the time, the 51st user to the 100th user to go online, at the same time, because the virtual user in the first iteration of the period of 1 to 50 users in succession and on-line, so when the 51st user on-line, 1th users also on-line, 2nd users offline; When 52nd users go online, 2nd user Online, 3rd user offline. According to this rule, in the upward cycle of the pressure scene, the virtual user's upper and lower line in the last iteration time is the synchronization upper and lower line of the virtual user in the previous iteration time. When entering the operating cycle of the pressure scene, the virtual user upper and lower line is the synchronization of the virtual users in all iterations of the upstream cycle, so when entering the run cycle, the 1th and 51st virtual users come online, and because the 2nd and 52nd virtual users last iteration time, So the 2nd and 52nd virtual users are offline. In the next second, the 2nd and 52nd virtual users are online, 3rd and 53rd virtual users are offline, and so on. Because there is no stable period, there is always a virtual user offline, so when the end point is reached, the virtual user will exit the iteration according to the exit strategy set by the pressure scene. It is important to note that the total number of virtual users actually running is close to the total number of virtual users when entering the operating cycle of the stress scene. Their deviation and the upward cycle of the pressure cycle with the virtual user time of a single iteration of the quotient value, microscopic, in the pressure scene at a certain point in time, the number of virtual users of quotient value is online, while the number of virtual users are offline, the remaining virtual users are performing iterations, of course, this is the theoretical situation, The actual operation will be much more complex, with the logic of the script and the settings of the scene.

Second, the file parameterized setting.

, the parameter selection policy is set to unique, each iteration, and Continue in a cyclic manner, which means that the parameters are selected from file at each iteration (same parameter values in the same iteration), each time taking a different parameter. If the alternate parameters are all selected, continue to select the parameters from the beginning of the loop. We dig deeper, how does loadrunner do the above strategy? This is the case, assuming there are 10 virtual users, the alternative parameters are 1000, in order to ensure that 10 virtual users each time the value is different, the alternative 1000 parameters evenly divided into 10 equal parts, each to a virtual user. Each virtual user to take the value, the order to take their own block, when the end of the block, and then the value. Note that the above strategy is valid only if the iteration is valid, that is, the second option must be selected, otherwise the LoadRunner will error when all 1000 parameters are taken out.

Sometimes we need to correspond to two parameter one by one, for example, each user has his own user name, that is, the UserID parameter and the Truename parameter is one by one corresponding, how to achieve the one by one corresponding parameter? This is done by logging the data source of the two parameters to a parameter table and setting the policy of the selection parameter to the same.

Note that the last line in the Notepad must be a blank line, otherwise LoadRunner will report an exception for "Missing lines".

Third, scene settings.

1, the Step setting:

The setting of the step size affects the wait time between actions in the virtual user's iteration and the wait time for the last iteration of the virtual user and the next iteration, and the iteration wait time between the different virtual users is not affected.

2, the pressure scene upstream policy settings:

The set policy is 10 users every 3 seconds, not 3 seconds in succession on 10 users.

3, other settings.

Deactivate log:

Set think time:

Error handling policies and running policies for virtual users:

Network speed Control Strategy:

LoadRunner Stress Test Experience Summary

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.