Changing values from bytes to KB, MB, or GB

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
alsoszaa
Posts: 33
Joined: Fri Sep 21, 2018 10:52 am

Changing values from bytes to KB, MB, or GB

Post by alsoszaa »

I am using a plugin / command within Nagios XI to collect Java heap memory usage (check_jmx). This is working very well! however the units are in bytes. I would like to change the units to KB, MB, or GB, but the check_jmx -help does not have this option. Is there a way to still change the units even though its not an option written into the plugin?
bolson

Re: Changing values from bytes to KB, MB, or GB

Post by bolson »

Hello,

As I'm sure you understand, Nagios XI doesn't create the news, it just reports it. In other words, XI simply displays the plugin's output. As a consequence, there are only two options to achieve what you're looking for:

1) Modify the plugin to do the math to report in KB, MB, GB, etc.

2) Create a "wrapper" plugin which runs the existing plugin, saving it's output into variables, making the calculation, and reporting the modified results. Both of these options are out of scope for Nagios Support. However, you may find advice and direction here from the user community.

Thank you!
Locked