Page 1 of 1
PNP4NAGIOS problem with values above 1000
Posted: Tue Jul 31, 2018 9:16 am
by achahine21
Hello,
I'm trying to draw the output of check_snmp using a specific OID
My output is good.
example: the real output is 5421
however, the graph shows 5.421 k knowing that i'm using the default.php
what could i change to get the exact value without the k ?
Re: PNP4NAGIOS problem with values above 1000
Posted: Tue Jul 31, 2018 11:43 am
by mcapra
For the command producing this issue, can you share the raw output of the related check_snmp command executed from the CLI of your Nagios Core machine? Preferably with the
-v or
--verbose flag.
If it's an SNMP counter, RRDTool is probably going to store it as a
counter/derive data source type when in reality you want it as a gauge. You may want to check the associated XML file to see what this metric is being typed as.
Re: PNP4NAGIOS problem with values above 1000
Posted: Wed Aug 01, 2018 12:44 am
by achahine21
For the command producing this issue, can you share the raw output of the related check_snmp command executed from the CLI of your Nagios Core machine? Preferably with the -v or --verbose flag.
This is the output:
Code: Select all
./check_snmp -H 192.168.139.30 -C Public -o 1.3.6.1.4.1.9.10.24.1.1.4.1.3.2 -v
/usr/bin/snmpget -Le -t 10 -r 5 -m '' -v 1 [context] [authpriv] 192.168.139.30:161 1.3.6.1.4.1.9.10.24.1.1.4.1.3.2
iso.3.6.1.4.1.9.10.24.1.1.4.1.3.2 = Gauge32: 4874
SNMP OK - 4874 | iso.3.6.1.4.1.9.10.24.1.1.4.1.3.2=4874
also this is the XML file.
Code: Select all
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<NAGIOS>
<DATASOURCE>
<TEMPLATE>check_snmp</TEMPLATE>
<RRDFILE>/usr/local/pnp4nagios/var/perfdata/Cisco_Spider/Total_VPDN_Session.rrd</RRDFILE>
<RRD_STORAGE_TYPE>SINGLE</RRD_STORAGE_TYPE>
<RRD_HEARTBEAT>8460</RRD_HEARTBEAT>
<IS_MULTI>0</IS_MULTI>
<DS>1</DS>
<NAME>iso.3.6.1.4.1.9.10.24.1.1.4.1.3.2</NAME>
<LABEL>iso.3.6.1.4.1.9.10.24.1.1.4.1.3.2</LABEL>
<UNIT></UNIT>
<ACT>4937</ACT>
<WARN></WARN>
<WARN_MIN></WARN_MIN>
<WARN_MAX></WARN_MAX>
<WARN_RANGE_TYPE></WARN_RANGE_TYPE>
<CRIT>0</CRIT>
<CRIT_MIN></CRIT_MIN>
<CRIT_MAX></CRIT_MAX>
<CRIT_RANGE_TYPE></CRIT_RANGE_TYPE>
<MIN></MIN>
<MAX></MAX>
</DATASOURCE>
<RRD>
<RC>0</RC>
<TXT>successful updated</TXT>
</RRD>
<NAGIOS_AUTH_HOSTNAME>Cisco Spider</NAGIOS_AUTH_HOSTNAME>
<NAGIOS_AUTH_SERVICEDESC>Total VPDN Session</NAGIOS_AUTH_SERVICEDESC>
<NAGIOS_CHECK_COMMAND>check_snmp!PolyM1x!1.3.6.1.4.1.9.10.24.1.1.4.1.3.2 -c3000:</NAGIOS_CHECK_COMMAND>
<NAGIOS_DATATYPE>SERVICEPERFDATA</NAGIOS_DATATYPE>
<NAGIOS_DISP_HOSTNAME>Cisco Spider</NAGIOS_DISP_HOSTNAME>
<NAGIOS_DISP_SERVICEDESC>Total VPDN Session</NAGIOS_DISP_SERVICEDESC>
<NAGIOS_HOSTNAME>Cisco_Spider</NAGIOS_HOSTNAME>
<NAGIOS_HOSTSTATE>UP</NAGIOS_HOSTSTATE>
<NAGIOS_HOSTSTATETYPE>HARD</NAGIOS_HOSTSTATETYPE>
<NAGIOS_MULTI_PARENT></NAGIOS_MULTI_PARENT>
<NAGIOS_PERFDATA>iso.3.6.1.4.1.9.10.24.1.1.4.1.3.2=4937;;0; </NAGIOS_PERFDATA>
<NAGIOS_RRDFILE>/usr/local/pnp4nagios/var/perfdata/Cisco_Spider/Total_VPDN_Session.rrd</NAGIOS_RRDFILE>
<NAGIOS_SERVICECHECKCOMMAND>check_snmp!Public!1.3.6.1.4.1.9.10.24.1.1.4.1.3.2 -c3000:</NAGIOS_SERVICECHECKCOMMAND>
<NAGIOS_SERVICEDESC>Total_VPDN_Session</NAGIOS_SERVICEDESC>
<NAGIOS_SERVICEPERFDATA>iso.3.6.1.4.1.9.10.24.1.1.4.1.3.2=4937;;0;</NAGIOS_SERVICEPERFDATA>
<NAGIOS_SERVICESTATE>OK</NAGIOS_SERVICESTATE>
<NAGIOS_SERVICESTATETYPE>HARD</NAGIOS_SERVICESTATETYPE>
<NAGIOS_TIMET>1533103203</NAGIOS_TIMET>
<NAGIOS_XMLFILE>/usr/local/pnp4nagios/var/perfdata/Cisco_Spider/Total_VPDN_Session.xml</NAGIOS_XMLFILE>
<XML>
<VERSION>4</VERSION>
</XML>
</NAGIOS>
but don't really know how to fix my issue.
Re: PNP4NAGIOS problem with values above 1000
Posted: Wed Aug 01, 2018 4:41 pm
by cdienger
I think you'll need to set additional rrdtool options in the default.php(
https://oss.oetiker.ch/rrdtool/doc/rrdgraph.en.html). Try setting the upper limit to something like 10000.