logstash-plugins / logstash-input-snmp

Apache License 2.0
17 stars 22 forks source link

smidump failed to locate MIB module #79

Closed ainiml closed 4 years ago

ainiml commented 4 years ago

Running smidump --level=6 -s -m -k -f python OG-CONNECT-MIB.mib receives errors on missing MIB module

error failed to locate MIB module:

root@cf4e7738b411:/mibs/opengear# smidump  --level=6 -s -m  -k -f python OG-CONNECT-MIB.mib  >/foo
OG-CONNECT-MIB.mib:12: [1] {module-not-found} failed to locate MIB module `OG-SMI-MIB'
OG-CONNECT-MIB.mib:14: [1] {module-not-found} failed to locate MIB module `RFC-1212'
OG-CONNECT-MIB.mib:16: [1] {module-not-found} failed to locate MIB module `SNMPv2-SMI'
OG-CONNECT-MIB.mib:18: [1] {module-not-found} failed to locate MIB module `SNMPv2-CONF'
OG-CONNECT-MIB.mib:20: [1] {module-not-found} failed to locate MIB module `SNMPv2-TC'
OG-CONNECT-MIB.mib:52: [2] {maxaccess-in-smiv1} MAX-ACCESS is SMIv2 style, use ACCESS in SMIv1 MIBs instead
OG-CONNECT-MIB.mib:53: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:60: [2] {maxaccess-in-smiv1} MAX-ACCESS is SMIv2 style, use ACCESS in SMIv1 MIBs instead
OG-CONNECT-MIB.mib:61: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:79: [2] {maxaccess-in-smiv1} MAX-ACCESS is SMIv2 style, use ACCESS in SMIv1 MIBs instead
OG-CONNECT-MIB.mib:80: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:90: [2] {maxaccess-in-smiv1} MAX-ACCESS is SMIv2 style, use ACCESS in SMIv1 MIBs instead
OG-CONNECT-MIB.mib:91: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:98: [2] {maxaccess-in-smiv1} MAX-ACCESS is SMIv2 style, use ACCESS in SMIv1 MIBs instead
OG-CONNECT-MIB.mib:99: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:106: [2] {maxaccess-in-smiv1} MAX-ACCESS is SMIv2 style, use ACCESS in SMIv1 MIBs instead
OG-CONNECT-MIB.mib:107: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:114: [2] {maxaccess-in-smiv1} MAX-ACCESS is SMIv2 style, use ACCESS in SMIv1 MIBs instead
OG-CONNECT-MIB.mib:115: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:136: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:150: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:173: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:182: [2] {status-invalid-smiv1} invalid status `current' in SMIv1 MIB
OG-CONNECT-MIB.mib:42: [1] {object-identifier-unknown} unknown object identifier label `ogMgmt'
OG-CONNECT-MIB.mib:88: [2] {basetype-unknown} type `DisplayString' of node `ogconnEventUsername' does not resolve to a known base type
OG-CONNECT-MIB.mib:96: [2] {basetype-unknown} type `DisplayString' of node `ogconnEventType' does not resolve to a known base type
OG-CONNECT-MIB.mib:112: [2] {basetype-unknown} type `DisplayString' of node `ogconnEventPortLabel' does not resolve to a known base type
OG-CONNECT-MIB.mib:71: [2] {type-unknown} unknown type `DisplayString'
smidump: module `OG-CONNECT-MIB.mib' contains errors, expect flawed output

MIB file exists:

root@cf4e7738b411:/mibs/opengear# ls -lh OG-SMI-MIB*
-rwxrwx--- 1 root root 3.6K Jun  2 22:42 OG-SMI-MIB
-rwxrwx--- 1 root root 3.6K Jun  2 22:42 OG-SMI-MIB.mib
ainiml commented 4 years ago

doesn't work: smidump -p *.mib --level=6 -s -m -k -f python OG-CONNECT-MIB.mib

works: smidump -p OG-SMI-MIB.mib --level=6 -s -m -k -f python OG-CONNECT-MIB.mib