Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-19004

Mapping of SNMP OIDs fails for OIDs starting with the same pattern

    XMLWordPrintable

Details

    • Incident report
    • Status: Closed
    • Trivial
    • Resolution: Won't fix
    • 5.2.3
    • None
    • Server (S)
    • None

    Description

      Steps to reproduce:

      1. Define two items
        1. snmptrap["SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.1"]
        2. snmptrap["SNMPv2-SMI::enterprises.28458.1.57.0.2.100.0.11"]
      2. Define Triggers with problem expression
        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)}

          =1

        2. {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

      3. 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 

      {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

      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.

      Attachments

        Activity

          People

            atocko Andrey Tocko
            enavarro Enrique Navarro
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: