This section provides step-by-step instructions on how to provision load generators in the cloud for LoadRunner tests. Some of the instructions refer to the Amazon EC2 cloud, but you can configure the parallel settings for HP Helion.
Create a security group
A security group is a configuration for allowing or disallowing specific traffic to and from a machine.
To use load generators on the cloud, you must use a security group allowing load generator communication. Create a security group in your account management console with a custom TCP rule that allows inbound traffic on the port used for the communication between the load generator and the Controller. By default, LoadRunner uses port 54345. This can easily be changed using a network profile, described below.
The source IP should be Anywhere, unless you will be using a Controller from a specific, single IP address.
Create a key pair - optional
A key pair is a security measure used for interactive logging in to cloud machines. This is not strictly required for using load generators on the cloud, but may be useful for cases in which you need to log into a machine manually, third-party software installation, or local log inspection.
If required, create a key pair in your account management console and save the generated .pem file.
Create an access key
LoadRunner's Controller uses Access keys to communicate with the cloud provider.
For EC2, an access key is composed of an access Key ID and a secret access key. This access key is different from your EC2 Web Console access credentials and must be created separately.Refer to the AWS documentation for information on creating an Access Key. Save the access key ID and secret access key.
For HP Helion, an access key set consists of an access key and secret key. For details, refer to the HP Helion documentation.
For Microsoft Azure, you need to provide a Subscription ID and path to the relevant certificate file. For details, refer to the Microsoft Azure documentation.
You are now finished preparing your cloud account.
SSL encryption in used to ensure secure communication between the local LoadRunner Controller and Load Generator on the cloud machine. You must own a CA certificate file and either a CA private key file or an SSL certificate file.
To create new certificates, run the gen_ca_cert.exe utility . This process creates two files in the folder from which the utility was run: the CA Certificate file, used to sign SSL certificates (cacert.cer), and the CA Private Key, used with the CA certificate to generate an SSL certificate (capvk.cer). For details, see How to Create an SSL Digital Certificate.
Configure the proxy server - optional
If you are using the LoadRunner Controller behind a proxy server (for example, an enterprise proxy server), the proxy server must be configured to allow communication.
The following ports must be enabled in the CONNECT method:
- 443 – Used for communication with Amazon AWS API.
- 35357 – Used for communication with HP Helion API.
- The port (by default 54345) used for communication between the load generator and Controller. You can configure this with a network profile as described below.
If your environment includes an HTTP 1.0 proxy server using NTLM, make sure to enable the port defined in the network profile for communication with the load generator machine, in order to bypass the NTLM authentication.
Set the Windows Internet options - only relevant when using a proxy server
Configure the proxy locally in the Windows Internet Options:
- Open the Windows Internet options (Tools > Internet Options)
- In the Connection tab, click LAN Settings.
- Specify your proxy server information.
Create a Controller network profile
- In the Controller select (Tools > Network Profile Manager)
- In the Network Profile Manager dialog box, click the Add button. Click on an empty line in the Network Profile Name list and create a new profile. For details, see Network Profile Manager Dialog Box.
Select Use proxy and fill the proxy server details, if required.
In the Connection Mode section, optionally specify a different port, to be used for the Controller's communication with the load generators using this network profile.
Add a virtual account
- In the Controller, select Tools > Manage Cloud Accounts.
- Enter an account name and select an account provider.
- Fill in the access credentials, such as the access and secret keys, that you created above. You can retrieve these keys from the cloud provider's management console.
- Optionally, specify a time delay to terminate the load generator if collation fails. For details, see Manage Cloud Accounts Dialog Box.
- Click Save. LoadRunner validates the credentials against the cloud provider.
Specify load generators - provision new load generators
- In the Controller's Load Generators dialog, select Add from Cloud > Provision New LG.
Fill in the basic information
- Select the account you created. Machine parameters will be retrieved from the cloud provider.
- Increasing the number of load generators allows you to provision more than one machine with the same parameters.
- To automatically terminate the machines after the scenario run and after all the data has been collated, select Terminate the load generator when load test is finished.
Click More to specify provider-specific parameters and images. Initially, default parameters are selected. These parameters are unique for each cloud provider.
- In the Machine Settings section, select and specify values. All fields are required, except for Additional Ports. The user name is that of the administrator account used above. You are now creating a password for the machine to be provisioned. The password should be at least 8 characters long and contain 3 of the lowercase/uppercase/digit/special symbols.
- If you are behind a proxy server, or using a non-default communication port, go to the Connections section and select the network profile created earlier to be used with the provisioned machines.
- Verify the provisioning parameters (amount, termination policy, and machine parameters) before clicking the Provision button.
Once the new cloud machines are started, they will be added to the Controller's Load Generators list. LoadRunner copies the certificates files to the load generator machine and configures the communication port. The LoadRunner agent is also configured to check client certificate to ensure a secure connection, since the machines are publicly available.
During provisioning, the load generator status is In Progress. This status indicates provisioning of the test machine on the cloud and launching the OS and load generator on this machine. This process can take a few minutes.
Once the load generator status changes to Down, it can be used for running a scenario. You can verify its availability by clicking the Connect button.
Specify load generators - use existing cloud-based load generators
You can use running instances of cloud machines in your account, either provisioned through the Controller, or manually created.
To be used as load generators, cloud machines must comply with the following: (Machines provisioned through Controller with HP provided images, are pre-configured to comply with these requirements.)
- Load Generator software must be installed and the LoadRunner Agent software must be running.
- The certificate file on the cloud load generator must be signed by the same CA as the certificates on the Controller.
- The machine must locally allow the communication ports mentioned above.
To specify an existing load generator:
- In the Controller's Load Generators dialog box, select Add from Cloud > Use Existing LG.
- In the Use Cloud Load Generator dialog box, select your cloud account.
- Select the machines you would like to add to the scenario.
- If you are behind a proxy server, select the network profile created earlier to be used for the selected machines.
- Click Add Machine to assign the selected machine to the scenario.
Delete load generators
When not being used, cloud machines may still be incurring costs to your account. The Controller allows you to terminate cloud load generators directly from the scenario.
In the Load Generators dialog box, select the machine you want to delete and click Delete
In the Delete Load Generator window, select one of the following options:
- Delete from Scenario. the machine will be removed from this Controller, but it is still up and running.
- Delete and Terminate. the machine will be removed from this Controller and also terminated from the cloud provider.