Output problems with check_snmp ...
Jack Doyle
jdoyle at lewisgaleclinic.com
Mon May 24 22:13:03 CEST 2004
I'm new to the snmp stuff... I'm following your lead and trying to get
it to do one thing and I get this (when sending to our core cisco
switch)
[root at redman plugins]# ./check_snmp -H 10.1.1.1 -o system.sysUpTime.0
SNMP problem - No data recieved from host
CMD: /usr/bin/snmpget -t 1 -r 9 -m ALL -v 1 -c public 10.1.1.1:161
system.sysUpTime.0
-----
John N. Doyle, Network+ Certified Professional
Systems Operations Specialist
Lewis-Gale Clinic Information Systems
540.772.3669
>PGP Key Available: http://68.106.83.67:8082/pgp.txt
-----Original Message-----
From: Andreas Ericsson [mailto:ae at op5.se]
Sent: Wednesday, May 12, 2004 4:33 AM
To: nagios-users at lists.sourceforge.net
Subject: Re: [Nagios-users] Output problems with check_snmp ...
Justin Hennessy wrote:
> Hi all (again),
>
> I am trying check the uptime of my managed switches but I have a
> little problem when I put the test into Nagios.
>
> When I run this:
> /usr/local/nagios/libexec/check_snmp -H 172.16.4.1 -o
> system.sysUpTime.0 -C dragonsbain
>
> I get this:
> SNMP OK - Timeticks: (563369316) 65 days, 4:54:53.16
>
> BUT when I run this:
> /usr/local/nagios/libexec/check_snmp -H 172.16.4.1 -o
> system.sysUpTime.0 -C dragonsbain -w 10 -c 30
>
> I get this:
> SNMP CRITICAL - *563375231*
>
> Can anyone shed some light on why the output changes when I put the
> WARNING and CRITICAL criteria in?
>
Which is correct. One timetick represents 1/100 of a second, and
563369316 1/100's of a second makes for 65 days, 4 hours, 54 minutes and
53.16 seconds (the above example. There was a time delay of 59.15
seconds delay between your running of snmpget and check_snmp).
check_snmp doesn't do that translation for you, so you have to specify
it in timeticks (why you would want thresholds on uptime in the first
place eludes me, but who am I to say?)
Anyways... The math goes something like this;
threshold=(((((days*24*60)+hours)*60+minutes)*60+seconds)*100)+centiseco
nds
Mind the math precedense.
One day is 86400 seconds. You do the math on the thresholds you want,
and don't forget to multiply by 100.
> Thanks,
>
Anytime.
> Justin
>
--
Andreas Ericsson
OP5 AB
+46 (0)733 709032
andreas.ericsson at op5.se
-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to
deliver higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when
reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
-------------------------------------------------------
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g.
Take an Oracle 10g class now, and we'll give you the exam FREE.
http://ads.osdn.com/?ad_id149&alloc_id66&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue.
::: Messages without supporting info will risk being sent to /dev/null
More information about the Users
mailing list