-
Incident report
-
Resolution: Won't fix
-
Trivial
-
None
-
5.2.3
-
None
Steps to reproduce:
- Define two items
- snmptrap["SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.1"]
- snmptrap["SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.11"]
- Define Triggers with problem expression
- {NDP SNMP Template:snmptrap["SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.1"].regexp(^.*28458.1.57.1.2.0 type=2 value=INTEGER: 1)}
=1
- {NDP SNMP Template:snmptrap["SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.11"].regexp(^.*28458.1.57.1.2.0 type=2 value=INTEGER: 1)}
=1
- {NDP SNMP Template:snmptrap["SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.1"].regexp(^.*28458.1.57.1.2.0 type=2 value=INTEGER: 1)}
- Send trap SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.11
sending trap
{ oid: '1.3.6.1.4.1.28458.1.57.0.2.100.0.11', varBinds: [ \{ oid: '1.3.6.1.4.1.28458.1.57.1.1.0', type: 4, value: '100' },
{ oid: '1.3.6.1.4.1.28458.1.57.1.2.0', type: 2, value: 1 },
Result:
Both traps are triggered and two problems are raised
Expected:
Only the
=1
should be matched and only one problem should be raised
The problem seems to be in the regexp used when matching the OID. Maybe the solution should be ending the OID regexp with the "\n" pattern.
Then,
1.3.6.1.4.1.28458.1.57.0.2.100.0.11\n will match but
1.3.6.1.4.1.28458.1.57.0.2.100.0.1\n will not.