What does a MIB look like?

For an example, here are the first few lines of the standard DPS Telecom MIB file.

DPS-MIB-V38 DEFINITIONS ::= BEGIN
IMPORTS
DisplayString
FROM RFC1213-MIB
OBJECT-TYPE
FROM RFC-1212
enterprises
FROM RFC1155-SMI;
dpsInc OBJECT IDENTIFIER ::= {enterprises 2682}
dpsAlarmControl OBJECT IDENTIFIER ::= {dpsInc 1}
tmonXM OBJECT IDENTIFIER ::= {dpsAlarmControl 1}
tmonIdent OBJECT IDENTIFIER ::= {tmonXM 1}
tmonIdentManufacturer OBJECT-TYPE
SYNTAX DisplayString
ACCESS read-only
STATUS mandatory
DESCRIPTION "The TMON/XM Unit manufacturer."
::= {tmonIdent 1}
tmonIdentModel OBJECT-TYPE
SYNTAX DisplayString
ACCESS read-only
STATUS mandatory
DESCRIPTION "The TMON/XM model designation."
::= {tmonIdent 2}

Wow! What language is that?

The MIB is written in ASN.1 notation. (The initials stand for Abstract Syntax Notation 1) ASN.1 is a standard notation managed by the ISO (International Organization for Standardization) and used in everything from the World Wide Web to aviation control systems.

A full description of ASN.1 is beyond the scope of this white paper - standard references to ASN.1 run up to 600 pages. When starting out, there are only a few things to know about ASN.1:

  1. It's human-readable. This doesn't mean its necessarily easy to understand without a helpful guide like this white paper. It does mean you can view and even edit ASN.1 notation with basic text editors.
  2. It's designed for communication between diverse computer systems, so it's the same for every machine. This doesn't mean every machine will no what to do with the information but it will at least recognize the ASN.1 notation.
  3. It's extensible, so it can be used for describing almost anything. Once a term is defined in ASN.1, it can be used as a building block for making other terms. This can sometimes involve confusing references but with a little understanding and perserverence, you can usually find all the pieces to the puzzle.
  4. It's worth learning. Equipment telemetry managers will be more confident integrating SNMP telemetry with a basic understanding of ASN.1 in their skill set. As more equipment is being designed with some kind of SNMP capability, being comfortable with the related MIB files has real value.