etingof / pysmi

SNMP MIB parser
http://snmplabs.com/pysmi/
BSD 2-Clause "Simplified" License
134 stars 52 forks source link

Any reason why some of the mib files are excluded for json conversion using mibdump tool? #67

Closed wasim-nihal closed 1 year ago

wasim-nihal commented 1 year ago

When running mibdump tool, the output log says few of the mib files were excluded from code generation as below. Can someone please let me know what's the reason behind this exclusion and is there an option to override this behavior?

MIBs excluded from code generation: RFC-1212, RFC-1215, RFC1065-SMI, RFC1155-SMI,
RFC1158-MIB, RFC1213-MIB, SNMPv2-CONF, SNMPv2-SMI, SNMPv2-TC, SNMPv2-TM
wasim-nihal commented 1 year ago

Some MIBs may not be automatically transformed into another form and therefore must be explicitly excluded from processing. Such MIBs are normally manually implemented for each target MIB format. Examples include MIBs containing base SMI types or ASN.1 MACRO definitions (SNMPv2-SMI, SNMPV2-TC), initially compiled but later manually modified MIBs and others.

Default list of blacklisted MIBs for pysnmp transformation target is: RFC-1212, RFC-1215, RFC1065-SMI, RFC1155-SMI, RFC1158-MIB, RFC1213-MIB, SNMP-FRAMEWORK-MIB, SNMP-TARGET-MIB, SNMPv2-CONF, SNMPv2-SMI, SNMPv2-TC, SNMPv2-TM, TRANSPORT-ADDRESS-MIB.

If you need to modify this list use the –mib-stub option

Reference: https://snmplabs.thola.io/pysmi/mibdump.html

lextm commented 1 year ago

Since you used that site as reference, you might want to read https://GitHub.com/etingof/pysnmp/issues/429 to learn more.