Resource Monitoring Agents
For testing, you would need many hosts. For example, you might have one host with the
application server, another host with the database server, and some hosts to apply the user load.
Due to network or firewall issues, sometimes, it becomes difficult for multiple hosts to connect to
each other. Resource Monitoring Agents are installed on the target hosts so that they can establish
a connection with HCL OneTest™ Server to
gather resource statistics of the target host.
The agents always try to connect with the server through the HTTPS protocol. You must install the agent and start it. From the Resource Monitoring Service dashboard, you can copy the command lines to download the .jar files or to run the agents. When you stop the agent, the data sources that you have already added persist but the live data will not be available.
The following tasks explain how you can install and start the Resource Monitoring Agents:
Installing Resource Monitoring Agents
You must install the Resource Monitoring Agents on the target host for which you want to
collect the performance statistics. The agents establish a connection with the Resource Monitoring
service.
Procedure
Results
Starting the RM Agent as a service on Windows
To ensure that the Resource Monitoring Agent starts by itself when the host is restarted,
you can set up the environment in such a way that the Resource Monitoring Agent can be started as a
service.
Before you begin
- Java 8 installed on the host.
- HCL OneTest Server added to the PATH environment variable.
- An offline token to connect the agent securely with appropriate permissions. You can create an offline token from the User menu of the Resource Monitoring dashboard or you can re-use your active offline token. The token expires if it is not used for a month.
Procedure
What to do next
For information about other winsw commands, see its documentation.
Starting the RM Agent as a service on Linux
To ensure that the Resource Monitoring Agent starts by itself when the host is restarted,
you can set up the environment in such a way that the Resource Monitoring Agent can be started as a
service.
Before you begin
- Java 8 installed on the host.
- HCL OneTest Server added to the PATH environment variable.
- An offline token to connect the agent securely with appropriate permissions. You can create an offline token from the User menu of the Resource Monitoring dashboard or you can re-use your active offline token. The token expires if it is not used for a month.
About this task
This topic relies on systemd services that is the default on most modern Linux distributions. Other ways may require adaptations of the instructions but the provided script will be a good basis in most cases.
Procedure
Results
Starting a Java Virtual Machine
To monitor the Resource Monitoring data from a Java Virtual Machine, you must start the
Java Virtual Machine. Some parameters must be set in the command line before running the Java
Virtual Machine.
Procedure
- In the command line that is used to run the Java Virtual Machine, enter The IP address of the JVM (local or remote host) and the IP port.
- Optional: You can optionally use authentication security data to launch the virtual machine. In this case, you must enter the name of the password file. You can also enter the name of a privilege file if needed.
Example
- Parameters used to launch a JVM without security:
java -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9010 -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -jar MyapplicationFile.jar
- Parameters used to launch a JVM with authentication security:
java -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9010 -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=true -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.password.file=jmxremote.password -Dcom.sun.management.jmxremote.access.file=jmxremote.access (this command line is optional) -jar MyapplicationFile.jar