DIFFERENT SEVERITY IN THE SAME OID TRAPS

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
oslec
Posts: 55
Joined: Mon Jan 14, 2013 5:19 pm

DIFFERENT SEVERITY IN THE SAME OID TRAPS

Post by oslec »

HELLO,

THE SAME OID CAN SEND DIFFERENT SEVERITIES

comcolHaAvailFailedNotify .1.3.6.1.4.1.323.5.3.29.1.2.31227
I AM USING SNMP Traps With NXTI

I WANT TO ASSOCIATE THE EVENT WITH A PASSIVE SERVICE

HOW CAN I PASS THE SEVERITIES TO CHANGE THE STATE BETWEEN CRITICAL AND OK?

THE VARIABLE THAT INDICATES SEREVRITY IS $ 4
5 =(clear)
1= (Critical)


Thanks
gsmith
Posts: 1253
Joined: Tue Mar 02, 2021 11:15 am

Re: DIFFERENT SEVERITY IN THE SAME OID TRAPS

Post by gsmith »

Hi,

Here is one way to do it:
https://support.nagios.com/kb/article/a ... e-911.html

And another way depending on your MIB file:
In general, the severity is not an attribute of an SNMP trap.

Usually the custom severity mapping is defined in vendor specific MIB file as variable binding of specific trap. Here is an example:

sysLogMessageSeverity OBJECT-TYPE
SYNTAX INTEGER {
emergency (0), --system is unusable
alert (1), --action must be taken immediately
critical (2), --critical conditions
error (3), --error conditions
warning (4), --warning conditions
notice (5), --normal but significant condition
informational (6), --informational messages
debug (7) --debug-level messages

}
ACCESS read-only
STATUS mandatory
DESCRIPTION
"Severity level of the message"
::= { sysLogMibObjects 5 }
from https://stackoverflow.com/questions/368 ... ty-in-snmp

Let me know how you make out. If you have more questions please attach the MIB file you are using.

Thanks
oslec
Posts: 55
Joined: Mon Jan 14, 2013 5:19 pm

Re: DIFFERENT SEVERITY IN THE SAME OID TRAPS

Post by oslec »

thanks for the documentation

what I did was create 2 different events, one for ok and the other for critical, and use it with a match in the severity variable.

it works

Thanks,
gsmith
Posts: 1253
Joined: Tue Mar 02, 2021 11:15 am

Re: DIFFERENT SEVERITY IN THE SAME OID TRAPS

Post by gsmith »

Great!

Thanks.
Locked