AppDynamics Application Intelligence Platform
3.8.x Documentation
This topic explains how to configure the App Agent for Java using the existing system property values.
AppDynamics recommends that you use the existing system properties to configure the Agent when your environment consists of multiple JVMs on the same machine. Once you have these variables configured, you can complete Agent installation for all JVMs by simply adding the javaagent argument to each JVM startup script. Then add the rest of the information to the controller-info.xml file.
AppDynamics recommends that you use the system properties if the same startup script is starting all the JVMs in your environment.
You can identify the node name based on the value of -Dserver.name and the tier name based on the value of -Dcluster.name.
Also, you can combine two or more system properties to identify the node or tier name. You can use -Dhost.name and -Dserver.name to identify similarly named nodes on different machines even when they belong to the same tier.
You can use existing system properties for the controller host and port, however combining is not supported in this case.
Use the following syntax to represent the value of the system property in the controller-info.xml file.
${system property name}
You can combine multiple system properties.
${host.name}${server.name}
You can combine system properties with literals. In the following example '_' and 'inventory' are literals.
${host.name}_${server.name}.inventory
${host.name}
or
${server.name}
or
${host.name}${server.name}
${cluster.name}
Consider a JVM with a script file named startserver.sh. This script file has following system property:
-Dserver.name=$1
If you execute:
startserver.sh ecommerce01
The script creates a new server named ecommerce01.
To use this system property for Agent configuration, add the appdynamics.agent.nodeName property to startserver.sh file.
-Dappdynamics.agent.nodeName=$server.name
When the script creates the new server named ecommerce01, it will be identified by AppDynamics as both a server and as a node.
The following screenshot shows a sample configuration for the controller-info.xml file and the startup script.