Add hosts to a cloud-based load generator

When you create a LoadRunner script, the details of the application under test (AUT) are recorded in the script. If the reference to the AUT is a host name, the load generator in the cloud cannot recognize the host. An IP address is required.

To overcome this obstacle, you can add a list of relevant hosts and their IP addresses to the load generator in the cloud.

Update a cloud-based load generator's hosts file

You create a text file, hosts.add, that contains the host names and corresponding IP addresses of your AUTs. This file is added to your script's .zip file.

At runtime, when the script is uploaded to the load generator, the load generator's hosts file is updated with the hosts contained in the hosts.add file.

To create the hosts.add file:

  1. Open an empty text file in a text editor and enter the IP addresses and corresponding host names in the format <ip address> <hostname>. For example:

    123.123.123.123 hostname1

    11.22.33.44 hostname2

    .

    .

    .

    Use the following guidelines:

    • Host names may include the following characters only:

      • [a-z][A-Z]

      • Numbers [0-9]

      • hyphen [-]

      • period [.]

    • IP addresses must be valid IPv4 or IPv6 addresses.
    • ONLY host names and IP addresses may be included in this file. Do not include headings or comments or any other text as this prevents the script from uploading.
  2. Save the file as hosts.add, and close the file.
  3. Add the hosts.add file to your script's .zip file.

    Note: If several scripts are being uploaded, add the hosts.add file to each script's .zip file.

Back to top

Notes and limitations

Scripts containing an invalid hosts.add file are not uploaded successfully. Make sure that the hosts.add file is set up according to the guidelines described above.

Back to top