Install and configure an OPLG on Linux

Install and configure an on-premises load generator (OPLG) on a Linux machine by deploying it in a Docker container.

System requirements

For Linux OPLG system requirements, see Support Matrix.

Prerequisites and limitations

The following prerequisites and limitations apply to Linux OPLGs.

Item Details
Date and time

Make sure that the date and time on the OPLG are correct.

Tip: Synchronize the machine clock with an Internet time server.

Connectivity

The OPLG machine must be able to access the OpenText Core Performance Engineering SaaS servers and cloud machines. Enable outbound HTTPS communication over port 443.

One test per OPLG

An OPLG can run only one test at a time.

Vusers

The number of Vusers in an on-premises load test cannot exceed the maximum allowed by your license.

Docker Docker Engine must be installed on each host machine where you deploy an OPLG container.

Supported protocols

The opentext_onelg_ubuntu Docker image contains OneLG, the OPLG installation for all OpenText Performance Engineering products. The image supports the following script protocols:

  • DevWeb

  • Gatling

  • Java over HTTP

  • Java Record Replay

  • Java Vuser

  • JMeter

  • Kafka

  • Mobile HTTP

  • MQTT

  • Oracle NCA

  • Oracle - Web

  • SAP - Web

  • TruClient 2.0

  • Web - HTTP/HTML

  • Windows Sockets

For details about the supported protocol versions, see Support Matrix.

Deploy an OPLG  container

Pull the opentext_onelg_ubuntu image from Docker Hub and deploy the OPLG container.

To deploy an OPLG  container:

  1. Pull the OneLG Docker image from Docker Hub:

    Copy code
    docker pull performancetesting/opentext_onelg_ubuntu:latest
  2. Launch the container in detached or foreground mode.

    Example - Background/detached mode:

    docker run -d \
          -e "STORM_TENANT=<your tenant id>"  \
          -e "STORM_SERVER=<server name>" \
          -e "STORM_USERNAME=<your user name>" \
          -e "STORM_PASSWORD=<your password>" \
          --net=host performancetesting/opentext_onelg_ubuntu
    Copy code

    Example - Foreground mode:

    docker run -t -i \
          -e "STORM_TENANT=<your tenant id>"  \
          -e "STORM_SERVER=<server name>" \
          -e "STORM_USERNAME=<your user name>" \
          -e "STORM_PASSWORD=<your password>" \
          --net=host performancetesting/opentext_onelg_ubuntu

     

  3. To enable JMeter or Gatling, add ENABLE_JMETER=1 or ENABLE_GATLING=1.
  4. If required, configure an HTTP/HTTPS proxy.

    Copy code
    Example:
     docker run -d \
          -e "STORM_TENANT=<your tenant id>" \
          -e "STORM_SERVER=<server name>" \
          -e "STORM_USERNAME=<your user name>" \
          -e "STORM_PASSWORD=<your password>" \
          -e "http_proxy=<your proxy url e.g. http://proxy.com>" \
          -e "https_proxy=<your proxy url e.g. http://proxy.com>" \
          --net=host performancetesting/opentext_onelg_ubuntu
  5. Set the required environment variables described in the Environment variables table.

Environment variables

You can pass environment variables using the --env-file command-line parameter. The following table describes each variable.

Variable Description
STORM_TENANT Tenant ID. Required.
STORM_SERVER

URL of the OpenText Core Performance Engineering server for your tenant's farm. Optional for version 26.2 and earlier. Required starting in version 26.3.

STORM_USERNAME User name. Required.
STORM_PASSWORD

Password. Required.

STORM_PROJECT_ID

Project ID. Optional. Default: 1.

STORM_KEY OPLG key. Optional. Linux only.
ENABLE_JMETER Enables JMeter functionality. Optional.
ENABLE_GATLING Enables Gatling functionality. Optional.

Note:

  • Copy the server URL from the browser address bar after you open the tenant. For example, if the browser URL is https://<myserver.com>/home/?TENANTID=208294383&projectId=1, use https://<myserver.com>.

    Examples:

    • US: https://loadrunner-cloud.saas.microfocus.com

    • Europe: https://loadrunner-cloud-eur.saas.microfocus.com

  • For versions 26.2 and earlier, if you omit the server URL, the default server is https://loadrunner-cloud.saas.microfocus.com. If the tenant ID belongs to a different server farm, the request fails with a 403 (Forbidden) error. Starting in version 26.3, if STORM_SERVER is missing, the agent stops, displays a help message, and exits.

  • For tenants created after version 24.3, enter your client ID in STORM_USERNAME and your client secret in STORM_PASSWORD. For earlier tenants, continue using your user name and password. If authentication fails, verify your credentials and make sure STORM_SERVER matches your tenant's farm. Starting in version 26.3, incorrect credentials and an incorrect server URL display different error messages.

Manually deploy and configure a Docker container

This section describes how to manually deploy and configure an OPLG Docker container.

To deploy and configure a Docker container:

  1. From the Navigation menu Navigation menu, select Assets > Load Generators.

  2. Select an existing load generator, or click the Create button Create to add one.

  3. If you are creating a new load generator:

    1. Enter a name and description.

    2. Select Linux as the operating system.

    3. Set the maximum number of Vusers for each supported protocol.

    4. Click Save.

  4. Copy the generated Key value. You need this key when configuring the container.

  5. For the opentext_onelg_ubuntu image, run:

    Copy code
    docker run -t -i \
          -e "STORM_DISABLE_AUTO_REGISTER=1" \
          --net=host performancetesting/opentext_onelg_ubuntu

    The current working folder is:

    Copy code
    /opt/testexec.server/stormagent
  6. Add the load generator key and your credentials to the sample_conf.json file:

    Copy code
    {
        "key": "<YOUR KEY>",
        "interval": 20000,
        "logLevel": "info",
        "server": {
            "protocol": "https:",
            "addr": "my-cloud-server.com",
            "user": "<YOUR USERNAME>",
            "password": "<YOUR PASSWORD>",
            "tenant": "<YOUR TENANTID>"
        },
        "injector": {
            "rootPath": "../injector_mdrv"
        }
    }

    Note: Copy the server address from the browser address bar after you open the tenant. For example, if the browser URL is https://myserver.com/home/?TENANTID=208294383&projectId=1, use https://myserver.com.

  7. Launch the container:

    Copy code
    node bin/stormagent.js --config ./sample_conf.json

Run a test using a Docker container

This section describes how to run a test using a load generator on a Docker container.

To set up an on-premises test run:

  1. From the Navigation menu Navigation menu, select Load tests, and select a load test.

  2. Open the Load profile pane and select a script. Expand the Location list and select On-premises. If there are no scripts listed, click the Add from Assets button Add from Assets to select one or more scripts from the repository.

  3. Open the Load distribution pane and click the On-premises tab. Click the + Add from Assets button to select the on-premises load generators to use for your test.

  4. To customize the number of allowed Vusers per protocol, select one of the on-premises generators, and click the Edit button. Customize the number of Vusers for the desired protocols.

For more information, see Tests.

Create and view logs

You can create and view test run logs.

To create a log:

Launch the container with the -r or --reserveTestLog flag.

For example:

Copy code
docker run -d -e STORM_AGENT_EXTRA_CONFIG='--reserveTestLog'

Logs are saved in the inj_o_*** folders under /storm.

To view a log:

Do one of the following:

  • View logs from within a running Docker container:

    1. Run:

      Copy code
      docker exec -t -i <container ID> /bin/bash
    2. Go to the /storm folder and view the required log.

  • Copy logs to your local file system:

    Run:

    Copy code
    docker cp <container ID>:/storm /tmp/

    The logs are copied to the /tmp folder in your local file system.