Connecting agents to the Resource Monitoring service
You must install the Resource Monitoring agents on the target host for which you want to monitor the performance statistics. The agents must be run to establish a connection with the Resource Monitoring service.
Before you begin
- The Resource Monitoring service does not require access to the agent host but the agent must have reached the service host over HTTPS.
- The Java agent must have been launched from a jar file and requires a Java 8 virtual machine.
- The Docker agent must have been launched in a Docker container and requires Docker 19.03.
About this task
This task applies to Java and Docker agents. However, the commands used to install agents are different from Java and Docker agents. You can find the commands and instructions in HCL OneTest™ Server in the Resource Monitoring agents page.
Before you start the Docker agents, you must build a Docker image.Procedure
- In HCL OneTest™ Server click Set up Agents to extend Resource Monitoring service to access the Agents page where you can find the instructions and commands that are to be used to install and run the agents.
-
To download the agent, click Download jar file for a
Java agent or Download Docker file for a Docker
agent.
You can also use the curl and wget commands to download the agent without accessing the Resource Monitoring web UI. For more facility, use the code snippets to copy and fill in the commands with the valid offline token and the jar or docker file name.
curl -O -J https://hostName/rm/Agent-jar wget --content-disposition https://hostName/rm/Agent-jar
- This step applies to Docker agents only, copy the build command and paste it in your console to build a Docker image.
-
To run your Agent, configure the command as follows:
- Copy the appropriate command respectfully to your environment system with the code snippets.
- In your console, points to the directory path that contains the Agent jar file, and paste the command.
On Windows:set HCL_ONETEST_OFFLINE_TOKEN=(Enter your offline token here) java -jar (Enter the name of the downloaded jar file here) --ServiceUrl=https://hostName/rm --projectId=<project_id>
On Linux:sudo HCL_ONETEST_OFFLINE_TOKEN=(Enter your offline token here) java -jar (Enter the name of the downloaded jar file here) --ServiceUrl=portNumber/rm --projectId=<project_id>