Pregunta

There is a way to enumerate values in mib files (http://en.wikipedia.org/wiki/Management_information_base) such as http://www.webnms.com/snmp/help/snmpapi/snmpv1/using_mibs_in_applns/enumintegers.html however is it possible to write such enumeration and reuse it throughout the mib to avoid duplicate enumerations throughout the file?

¿Fue útil?

Solución

If you have a chance to carefully read SNMPv2-TC,

http://www.ietf.org/rfc/rfc2579.txt

you will see that there are already common enum types defined, such as TruthValue.

TruthValue ::= TEXTUAL-CONVENTION
    STATUS       current
    DESCRIPTION
            "Represents a boolean value."
    SYNTAX       INTEGER { true(1), false(2) }

By importing such enum definitions in your MIB document or define your own, you can use/reuse them throughout the file.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top