This topic explains how you run a load test that involves multiple machines. In this section:
Understanding the Purpose and General Procedure
Load Test allows you to run tests on remote machines so that you can generate extremely large loads and run tests from different hosts on a network.
You need to perform three main steps before you can run tests on a remote machine:
- Add the machine to the Machines area of the Load Tests tab.
- Configure one or more scenarios to run tests on remote machine.
- Start the remote machine as a Load Test Server.
After you have performed all these steps, Load Test will run tests on the remote machine whenever it executes a load test scenario that is configured to involve that machine.
Adding and Configuring Remote Machines
There are a number of ways to add remote machines, as well as options for configuring them.
Adding Machines Manually
To add a remote machine from manually, complete the following:
- Right-click the Machines node.
- Choose New Machine from the shortcut menu. A New Machine node appears in the Machines node of the Load Tests tree.
- To change the New Machine name, enter a name in the right GUI panel’s Host field.
- To change the New Machine port number, enter a port number in the right GUI panel’s Port field.
- To configure a machine to run in High Throughput Mode, select the High Throughput Mode checkbox within the machine configuration panel. For details on high throughput mode, see Using High Throughput Mode.
Adding Machines From the Machines List
To add a remote machine from the Machines List, complete the following:
- Select the Machines node from the Load Tests tab. A list of a available machines is displayed in the Machines List of the Project Configuration panel. If no machines are displayed, this means no Load Test Windows Services were found on your network.
- Select the machines you wish to add, then click the Add button.
- To refresh the list of available machines, click the Refresh button.
Adding Machines in the Advanced View
To add a remote machine from in the Advanced View, complete the following:
- Select the Machines node from the Load Tests tab. The Machines List and Advanced View tabs display in the Project Configuration panel.
- Select the Advanced View tab.
- Right-click a remote machine row in the Advanced View tab. The selected machine must be running in order to add it to the Machine List.
- Choose Add to Machine List from the shortcut menu. A new machine node corresponding to the host name appears in the Machines node of the Load Tests tree.
The local host is the default machine listed in the Load Test tab’s Machines branch. If you select the localhost node, you will see that the name is set to localhost and the port is set to zero. These settings are permanent and cannot be changed.
Configuring Options in the Advanced View Tab
The Advanced View tab lists all remote machines on the local network that were installed as a Load Test Windows service. All of these machines can be used to run additional load tests.
If you want to configure a remote machine on the local network to run load tests, that machine’s version of Load Test must match the Load Test version running on your machine.
Even if you did not install Load Test as a Windows service, you will always have access to the Advanced View tab and will always be able to configure the remote machines that display in this panel. However, if you did not install Load Test as a Windows service, your machine will not display in the Advanced View tab and other remote machines will be prevented from configuring your machine.
The following options are available in the Advanced View tab:
- Refresh: Click to find all Load Test Windows service installations on the local network. A table displays the attributes of each remote machine installation and is sortable by column title. The following is displayed in the table:
- Host: Displays the name of the remote machine.
- Process State: Displays if the Load Test Server process is running or not running.
- Process Port: Displays the port number on which the Load Test Server is listening.
- Check Process State: Click to view the process state of the selected machine.
- Start: Click to start the Load Test Server process on the selected remote host.
- Stop: Click to stop the Load Test Server process on the selected remote host.
To view remote installation details, first click the Check Process State button, then double-click the desired row from the table. The Starter Properties dialog box displays. From this dialog box, you can view the version and build date, the installed applications files, and the port name and port number of the selected installation.
Verifying Remote Machines
You can verify that the remote machines added to the Machines node of the Load Tests tab are running and can communicate with your machine in one of two ways:
- Right-click the Machines node and select Verify Machines from the shortcut menu. All of the machines under the Machines node will be sequentially verified.
- Right-click one of the remote machine nodes beneath the Machines node and select Verify from the shortcut menu. Only the selected remote machine will be verified.
After verifying a remote machine, the status indicator to the left of the remote machine node will change and verification details will be displayed in the Messages window.
Depending on the remote machine’s state, the color to the left of the remote machine node will change according to the following:
- Green: Indicates that the remote machine is ready.
- Grey: Indicates that the remote machine is running a load test. When a load test is running, grey indicates the machine is busy and cannot be used by other load tests.
- Red: Indicates that the remote machine is unavailable and will not be able to run any load tests.
Transferring Project External Dependencies to Remote Machines
A SOAtest project that you use in Load Test can have external dependencies in the form of files that are used by the SOAtest tests while they are being executed by the load test’s virtual users. For the SOAtest project tests to function correctly, these external resources need to be available on both the Load Test controller machine and remote machines running load generators. Load Test automates the process of transferring the external dependencies to remote machines.
Synchronization States of the Machines
The process of transferring project dependencies to remote machines is called synchronization. The Load Test Configuration tree reflects the synchronization state of remote machines. The 'back and forth' arrows on the machine state icon indicate the synchronization state of the machine:
- Green arrows: The machine is synchronized. All external resources required by the project are available on the remote machine.
- Red arrows: The machine is not synchronized. All or some of the external resources required by the project are missing on the remote machine.
- Gray arrows: The synchronization state of the machine is unknown.
If you mouse over a machine node in the Load Test Configuration tree, a tool tip will show the machine availability and synchronization state.
Selecting Resources for Synchronization
You can control which external resources are transferred to the remote machine. To do this:
- In the Load Test Configuration tree, select Machines> localhost.
- In Machine Dependencies tab of the localhost configuration panel, select the resources you want transferred to the remote machines.
- If the dependencies table is empty, it means that the application cannot find any external dependencies or cannot find the current project.
- All resources are selected by default. You can unselect some or all of the resources if you use custom dependency transfer mechanisms outside of Load Test that are tailored to the specifics of your project setup and testing environment.
Note that if you select a row in the resource selection tree table, the location of the external dependency on the localhost will be shown in the Resource Path sub panel (under the tree table).
Viewing Synchronization Details of Remote Machines
To view the synchronization state of a specific machine:
- Right-click the appropriate machine node, then choose Check Synchronization.
To check synchronization of all enabled machines in the configuration:
- Right-click the Machines node, then choose Check Synchronization.
The remote machine synchronization state is reported in the resource tree-table, which is located in the Machine Dependencies tab of the remote machine configuration panel. If you select a row in the tree table, synchronization details will be shown in the Resource State sub panel.
Machines that belong to the local installation (localhost machines running on any port) will always appear as completely synchronized. This is because these Load Test machines belong to the same installation as the localhost machine which acts as a controller.
Manually Synchronizing Remote Machines
To synchronize a specific remote machine:
- Right-click the appropriate machine node, then choose Synchronize.
To synchronize all enabled machines in the configuration:
- Right-click the Machines node, then choose Synchronize.
A separate dialog will show the synchronization progress for the machines selected for synchronization.
- You do not have to check the synchronization states of the machines before synchronizing. Load Test will do that automatically before any synchronization.
- You do not have to manually synchronize the remote machines before launching a load test. The application will automatically do it for you as a part of the load test startup process. However, you may choose to synchronize the machines manually to reduce the load test start up time.
Automatic Remote Machine Synchronization During the Load Test Startup Procedure
Remote machine synchronization is a part of the machine initialization task, which is performed before the start of each load test. During the synchronization stage, only those resources that are missing or modified will be transferred to the remote machines. The Status of the initialization process and the Details of each of the initialization stages for each machine are reflected in the Task Progress panel of the Load Test Start Up dialog.
Working with SOAtest Project Dependencies
If the SOAtest project you’re using in Load Test leverages a file data source, be sure to enable that data source’s Refresh Dynamically Based on Last Import option if you want the file data source to use all files that are in the import directory at the time the file data source is used. If you do not enable this option, the file data source will only use the files that are listed in the table in the file data source—even if the import directory has additional files.
Enabling or Disabling Remote Machines
To disable/enable an existing machine:
- Right-click the appropriate node in the Machines branch, then choose Disable/Enable from the shortcut menu.
If a machine is disabled, it will not run with the load test until it is enabled again.
Enabling High Throughput Mode
To configure a machine to run in High Throughput Mode:
- Select the High Throughput Mode checkbox within the machine configuration panel.
For details on high throughput mode, see Using High Throughput Mode.
Configuring Scenarios to Run Remote Machines
By default, Load Test will apply the same ratio of profiles and number of virtual users or hit rate to all machines involved in a test. However, you can customize a scenario for different machines by clearing the Machine Independent box in the scenario settings panel; for details, see Customizing Test Suite Scenarios.
Working with Remote Machines Located on Different Networks
A Load Test controller machine (the one that runs in the GUI mode and from which you control the load test) can use a Load Test server machine located on a different network if the network equipment that bridges these networks allows communication on the port that the Load Test server machine is listening on.
For example, if you run your Load Test controller on network A and your Load Test server is started on port 10095 by a “lt -loadtestserver 10095” command on network B, you need to make sure that the communication on port 10095 between the networks A and B is not restricted by your network equipment.
Talk to your system or network administrator about the network configuration issues. The configuration should allow any TCP traffic exchange for that port. The network equipment that bridges networks A and B can either pass the traffic from one network to the other or it can block it. This network equipment can be configured to pass the TCP traffic associated with a certain port between the networks (i.e., "opening the port"). However, this may not be sufficient. Sometimes, communication between networks A and B associated with a certain port can be allowed only for certain network protocols. For instance, communication between A and B may be open on port 80, but only for HTTP protocol traffic. If the Load Test controller and server are on different networks, the network equipment that bridges the two networks should be configured to:
- Allow the TCP traffic exchange associated with the port on which the Load Test server is listening between networks A and B ("open the port").
- Lift, remove, or disable any protocol filters that may prevent the TCP communication associated with that port between networks A and B.
Running the Test from the GUI
Starting the Load Test Server
The remote machines must be running the Load Test Server whenever you want to execute load tests on these machines.
To start the Load Test Server from the GUI (Windows only):
- Choose Start> Programs> Parasoft> Load Test> Load Test Server.
Running Load Tests
After you have started the test machines in Load Test server mode, you can start your test by clicking the Load Test button in the client machine’s toolbar.
During the test, each machine will execute the designated number of virtual users and types of user profiles. Load Test will display the loading rate for the client as well as the loading rate for all servers.
All results will be reported on the client. You can determine whether Load Test displays load testing results for all machines or for a selected machine by choosing the appropriate item from the Load Test Result’s Machine box.
Running the Test from the Command Line Interface