Regarding SNMP Trap

Ranjeet Kumar ranjeetk at aztecsoft.com
Wed Dec 27 12:09:24 CET 2006


Hi,



I am trying to get snmp trap to nagios. I am using nagios-2.4-1,
nagios-pluging-1.4.3 & OS - Debian.

I am referring "Pro Nagios 2.0" book to for this.



I translated the mib using snmpttconvertmib as follow: -



/usr/sbin/snmpttconvertmib -in=/usr/share/smnp/mibs/IF-MIB.txt
-out=/etc/snmp/snmtt.conf



as well as added EXEC statement on snmptt.conf. below is the contents of
snmptt.conf



MIB: IF-MIB (file:/usr/share/snmp/mibs/IF-MIB.txt) converted on Thu Dec
21 12:34:15 2006 using snmpttconvertmib v1.1

#

#

#

EVENT linkDown .1.3.6.1.6.3.1.1.5.3 "Status Events" Normal

FORMAT Interface number $1 on $r is entering the $3 state

EXEC /usr/share/nagios2/plugins/eventhandlers/submit_check_result "$r"
"snmp_trap" 2 "Interface number $1 is entering the $3 state"

#FORMAT A linkDown trap signifies that the SNMP entity, acting in $*

SDESC

A linkDown trap signifies that the SNMP entity, acting in

an agent role, has detected that the ifOperStatus object for

one of its communication links is about to enter the down

state from some other state (but not from the notPresent

state).  This other state is indicated by the included value

of ifOperStatus.

Variables:

  1: ifIndex

  2: ifAdminStatus

  3: ifOperStatus

EDESC

#

#

#

EVENT linkUp .1.3.6.1.6.3.1.1.5.4 "Status Events" Normal

FORMAT Interface number $1 on $r is entering the $3 state

EXEC /usr/share/nagios2/plugins/eventhandlers/submit_check_result "$r"
"snmp_trap" 2 "Interface number $1 is entering the $3 state"

#FORMAT A linkUp trap signifies that the SNMP entity, acting in an $*

SDESC

A linkUp trap signifies that the SNMP entity, acting in an

agent role, has detected that the ifOperStatus object for

one of its communication links left the down state and

transitioned into some other state (but not into the

notPresent state).  This other state is indicated by the

included value of ifOperStatus.

Variables:

  1: ifIndex

  2: ifAdminStatus

  3: ifOperStatus

EDESC

EVENT CatchAll .1.* "SNMP Traps" Critical

FORMAT $D

EXEC /usr/share/nagios2/plugins/eventhandlers/submit_check_result "$r"
"snmp_traps" 2 "$O: $1 $2 $3 $4 $5"



I am able to see the logs of translated trap as log but it is not
executing the EXEC command. I tried using manually it works fine.

Please help me in solving this issue.



Thanks,

Ranjeet






The information contained in, or attached to, this e-mail, contains confidential information and is intended solely for the use of the individual or entity to whom they are addressed and is subject to legal privilege. If you have received this e-mail in error you should notify the sender immediately by reply e-mail, delete the message from your system and notify your system manager. Please do not copy it for any purpose, or disclose its contents to any other person. The views or opinions presented in this e-mail are solely those of the author and do not necessarily represent those of the company. The recipient should check this e-mail and any attachments for the presence of viruses. The company accepts no liability for any damage caused, directly or indirectly, by any virus transmitted in this email.

www.aztecsoft.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-lists.org/archive/users/attachments/20061227/690ba883/attachment.html>
-------------- next part --------------
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
-------------- next part --------------
_______________________________________________
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