JMX PMI Discovery

Included is the documentation of how to dump all the available JMX / PMI metrics, how to use the "EXPAND_PMI" directive (similar to the JMX GROUP_BY), and a unsupported vb script (developed by Sunil Joseph) that will take the dump file and try to create metrics.config entries.

GenPmi.vbs

Attached the VBscript that does much of the heavy lifting in reformatting the entries..

Be VERY cautious in using this as it will overload a probe or the Diagnostics Infrastructure if used improperly.

The attached zip file contains a VB Script that will take the file created by the Probes metrics dump or ‘groupby’ functionality and ATTEMPT to reformat (only) the PMI metrics entries into lines that can be directly added to the probes metric.config file.

Now having said that there are SEVERAL limitation to this tool.

1) This tool is not supported by the larger HP and the lab. It is my personal attempt to simplify the process of taking the raw dump entries and creating working metric.config entries. I am not absolutely certain that I have all of the parsing figured out. There probably will be some entries that simply do not work. Please let me know what those are.. I have a limited test environment and limited time to test.. So as we find entries that don’t work, I will research and figure out why.
2) The tool generates metric names and group names by concatenating strings in order to (Hopefully) create (required) unique names. In many cases the names generated are quite long. I have verified some of the output in the Diagnostics profiler, but I didn’t do that much testing with the UI so I don’t know how it will handle the extremely long names. There is probably a limit to how long strings can be in the system. So I strongly suggest you HAND EDIT the Metric names and the group names before using the entries. These are intended as examples of how the entries would be formatted. Not the final product for direct import into production use metrics.config files
3) The tool does its best to determine each metric’s unit of measure based on the information that has been dumped into the log. The metrics dump facility calls some API’s in WAS to get the metric description and unit types. Not all of metrics are documented. And lots of them just describe the unit of measure as N/a. So if the tool cannot identify the correct unit of measure it defaults to ‘count’. Providing the correct unit of measure to Diagnostics will help it to display and calculate the values more accurately. Where the information is available, I also added the description information from the log as a comment line in the output.
4) This WILL generate a HUGE number of possible lines for metrics.config. On my windows test machine it created 1160 entries, which would put a VERY heavy load on the JVM and the Diags server if they were all used. So again, these are to serve as examples and you MUST pick and choose the entries you are interested in.

To run the tool, copy the jmx_metrics_WAS6.txt file down from the probe to your windows system. The http://ProbeName:35000/filesscreen is REAL helpful for this.

Put the jmx_metrics_WAS6.txt file in the same directory as the tool, GenPMI.vbs . From a Windows command line execute:

Cscript genpmi.vbs

This version will run for several seconds and there are NO outputs from the tool while it is working..

The tool will read in the jmx_metrics_was6.txt file and create several output files.. the final results are in the metrics.config.txt file. This file is NOT a direct replacement for the probes metrics.config file. These are only PMI entries that can now to copied and pasted into the probes metrics.config file.

I would STRONGLY, STRONGLY suggest that you test this on sandbox systems until you are comfortable with the metrics and how they are presented. I would also suggest that the metric names and their group names be edited to something more meaningful for your users, before these entries are put into production use.

Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.