You are here

Check_jmx no graphs

5 posts / 0 new
Last post
talbrecht
talbrecht's picture
Check_jmx no graphs

Hi all,

 

I configure check_jmx for a test with HeapMemoryUsage and get results like this:

JMX OK HeapMemoryUsage.used=39739215744{committed=102760448000:init=110100480000:max=102760448000:used=39739215744}

But there is no graph for this...

 

What is wrong or what to do for a graph?

 

Regards,

Torsten

smarsh
smarsh's picture
Re: Check_jmx no graphs

Does check_jmx return performance data?

bellis
bellis's picture
Re: Check_jmx no graphs

Hi Sam

Hope you're well?  Long time no speak!  Congratulations on your new title in LinkedIn, presumably a promotion!  Nice one!

I'm desperately needing to get check_jmx working with performance data too but I'm not having any luck.  I've tried to work through the Nagios Exchange comments for check_jmx but none of it makes any sense to me.

I've got check_jmx working on one metric at the moment (HeapMemoryUsage) and that's working fine but I'm not getting any graphs.

What is needed to get check_jmx to produce performance data please?

Regards

Bryn

bellis
bellis's picture
Re: Check_jmx no graphs

Sorry, should have had a further look before posting!  I think I might have sorted it with a very helpful post from 

https://code.google.com/p/jmxquery/issues/detail?id=22

My check_jmx now looks like this and is producing graphs:

#!/bin/sh JAVA_HOME=/usr RDIR=`dirname $0` OUTPUT=$($JAVA_HOME/bin/java -cp $RDIR/jmxquery.jar org.nagios.JMXQuery "$@") EXIT_STATUS=$? STATUS=`echo $OUTPUT` PARAMCOUNT=$(echo $OUTPUT | tr -cd '=' | wc -c) if [ $PARAMCOUNT -gt "1" ] then         VALUE=$(echo $OUTPUT | sed 's/.*{\(.*\)}.*/\1;/' | sed 's/;/;;;0; /g') else         VALUE=$(echo $OUTPUT | awk '{print $NF}') fi echo "$STATUS | $VALUE"   exit $EXIT_STATUS   Hope this helps someone else.   Bryn
smarsh
smarsh's picture
Re: Check_jmx no graphs

Hey Bryn,

Thanks! I love it when users solve their own issues, haha.

All the best,

Sam