8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 1/31
Krish Hegde 1
LoadRunner Controller
• LoadRunner Controller controls a
Scenario and all its components such as
Vusers, Hosts, Scripts.
• LoadRunner Controller plays the role of a
Moderator. ie Add & Monitor Vusers.
• View complete details on Vusers, hosts,
Scripts, status etc.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 2/31
Krish Hegde 2
LoadRunner Controller
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 3/31
Krish Hegde 3
Create a Scenario
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 4/31
Krish Hegde 4
Configure Scenario
Step 1:Create a New Scenario & Save theScenario in a Data Drive.
Step 2: Add Vusers
Step 3: Add HostsStep 4:
• Add hosts to Host List
• Add Scripts to Scripts List
• Add Vusers to Vuser Groups
Step 5: Configure Scenario
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 5/31
Krish Hegde 5
Review Scenario
• Review Scenario and all its Components.
• Check whether the Scenario can fulfill test
objectives.• Review Scenario Configuration
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 6/31
Krish Hegde 6
Add Hosts
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 7/31
Krish Hegde 7
Add Scripts
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 8/31
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 9/31
Krish Hegde 9
Create Vuser Groups
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 10/31
Krish Hegde 10
Create Vusers
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 11/31
Krish Hegde 11
Rendezvous Points
• During a scenario run you can instruct multipleVusers to perform tasks simultaneously by usingrendezvous points. A rendezvous point createsintense user load on the server and enables
LoadRunner to measure server performanceunder load.• You ensure that multiple Vusers act
simultaneously by creating a rendezvous point .When a Vuser arrives at a rendezvous point, it isheld there by the Controller. The Controller releases the Vusers from the rendezvous either when the required number of Vusers arrive, or when a specified amount of time has passed.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 12/31
Krish Hegde 12
Rendezvous Points
• Using the Controller, you can influence the level of server load by selecting: – which of the rendezvous points will be active during the scenario
– how many Vusers will take part in each rendezvous
• For example, to test a bank server you could create ascenario that contains two rendezvous points. The firstrendezvous ensures that one thousand Vuserssimultaneously deposit cash. The second rendezvousensures that another thousand Vusers simultaneously
withdraw cash. If you want to measure how the server performs when only five hundred Vusers deposit cash,you can deactivate (disable) the “withdraw” rendezvous,and instruct only five hundred Vusers to participate in the“deposit” rendezvous.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 13/31
Krish Hegde 13
Configure Scenario
• Before you run a scenario, you can
configure both the host and Vuser
behaviors for the scenario.
• The default settings correspond to most
environments.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 14/31
Krish Hegde 14
Runtime Settings
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 15/31
Krish Hegde 15
Configure Output file
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 16/31
Krish Hegde 16
Set timeout
• LoadRunner enables you to set the timeout
interval for commands, pinging of hosts, and
Vuser elapsed time.
• The command timeouts relate to hosts andVusers. The host commands for which you can
specify a timeout interval are Connect,
Disconnect, and Heartbeat. The Vuser
commands for which you can specify a timeoutinterval are Init, Run, Pause, Abort.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 17/31
Krish Hegde 17
Set File path
• When you run a scenario, by default the
run-time files are stored locally on each
Vuser host. (the machine running the
Vuser script) The default location of thefiles is under the temporary directory
specified by the host’s environment
variables.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 18/31
Krish Hegde 18
Configure Hosts
• Before you run a scenario, you can indicatewhich hosts will run Vusers in the scenario. For example, if a host is unavailable for a particular scenario run, you can exclude it temporarily
instead of removing it entirely from your list of hosts.• You select which hosts will take part in the
scenario by using the Enable and Disablecommands. Disabling a host temporarilyremoves it from the list. Enabling a hostreinstates it.
• Host tab>Details>Vuser limits
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 19/31
Krish Hegde 19
Set Max Vuser for Host
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 20/31
Krish Hegde 20
Preparing to run Scenario
• Before you run a scenario, you need to specifythe location of the results (mandatory), assign aname to the results, schedule the scenario, andprovide scenario summary information. Inaddition, you can specify the applications toinvoke at the start of a scenario.
• Although most of the pre-scenario settings areoptional, by using them you can enhance thetesting process. These values are scenariospecific—you can set different values for eachLoadRunner scenario.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 21/31
Krish Hegde 21
Specify results location
• When you run a scenario, by default theruntime files are stored locally on each
Vuser host. After the scenario, the resultsare collated together and processed onthe Controller machine.
• Alternatively, you can instruct LoadRunner to save the results on a shared networkdrive.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 22/31
Krish Hegde 22
Specify results location
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 23/31
Krish Hegde 23
Using Test Director
1 Choose Options > TestDirector
Connection to open a connection to a
TestDirector server and database.2 Open an scenario from the database (File
> Open), or save the current scenario to
the TestDirector database (File > SaveAs).
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 24/31
Krish Hegde 24
Collating Results
• When you run a scenario, by default all Vuser information is stored locally on each Vuser host.After scenario execution the results areautomatically collated or consolidated
• To disable automatic collation, choose Results> Auto Collate Results to clear the check markadjacent to the option.
• To manually collate results, choose Results >
Collate Results. If your results have not beencollated, then LoadRunner Analysis willautomatically collate the results beforegenerating the analysis data.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 25/31
Krish Hegde 25
Schedule Scenario Run
• After you create a scenario, you select the
Groups and Vusers that you want to participate
in the scenario and run it manually from the
Controller.• Alternatively, you can use the LoadRunner
Scheduler to set up a scenario to run
automatically. You can set the start and duration
time of the scenario and indicate which Groupsshould participate in the scenario. This chapter
describes:
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 26/31
Krish Hegde 26
Schedule Scenario Run
• Open the Scheduler and select an event mode Choose Scenario >Scheduling from the LoadRunner Controller to open the Scheduler andselect the Basic or Expert event modes. The Expert mode allows you to setup dependencies and schedule external events.
• Schedule groups Add existing Vuser groups to the scenario schedule and
set a starting time.• Set the timing properties Set the timing related specifications for thescenario such as duration, initialization, ramp up, and ramp down.
• Create and schedule external events Define delays and external events,and schedule them at the desired points. This setting only applies to Expertevent mode.
• Specify dependencies and sequences. Specify dependencies of one
group upon another or indicate an event sequence. This setting only appliesto Expert event mode.
• Save the schedule and run the scenario. Save the setup and run thescenario from the Scheduler interface. The test runs according to your settings.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 27/31
Krish Hegde 27
Managing Scenario using
TestDirector • LoadRunner works together with TestDirector,
Mercury Interactive’s test management tool.TestDirector provides an efficient method for storing and retrieving scenarios and collecting
results. You store scenarios and results in aTestDirector repository and organize them intounique groups.
• The Controller’s Tools menu contains two menuitems related to TestDirector. The first item,TestDirector Connection changes the testrepository from the standard file system to theTestDirector database. The second item,TestDirector, invokes TestDirector.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 28/31
Krish Hegde 28
Open connection to TestDirector
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 29/31
Krish Hegde 29
Open Scenario from TestDirector
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 30/31
Krish Hegde 30
Save Results in TestDirector
• Before you run a scenario, you set the
results location. If you have a connection
open to the TestDirector project, results
are saved to the default test set. You canalso save the results to a new or existing
test set, or to disk using the standard file
system.
8/14/2019 Load Runner Creating Load Runner Scenarios Chapter 3
http://slidepdf.com/reader/full/load-runner-creating-load-runner-scenarios-chapter-3 31/31
Krish Hegde 31
• Questions?