-
Notifications
You must be signed in to change notification settings - Fork 201
Troubleshoot JMX metrics
This page aims to help to troubleshoot JMX metrics.
First, download JMXTerm.
After, start JMXTerm: java -jar jmxterm-1.0.2-uber.jar
Type jvms
to have the PIDs of the Java applications.
The jvms
command may not work (see). In this case, you can use the jcmd
or jps
Java command to retrieve the PID of your application before using JMXTerm.
Open a connection to your application: open <PID>
.
Display the available domains: domains
Select the wanted domain: domain <domain-name>
Display the MBeans for this domain: beans
Select the wanted MBean: bean <object-name>
Display the attributes of this bean: info
You can then evaluate an attribute: get <attribute-name>
JMXTerm has added a :
at the end of the objectName.
The JMX metrics configuration has to contain available objectName and attribute name.
"jmxMetrics": [
{
"name": "Troubleshoot JMX metric",
"objectName": "java.lang:type=OperatingSystem",
"attribute": "Name"
}
]