MIB Overview
Network Management
Nowadays, the Internet expands rapidly and the network scale also grows increasingly large. A large-scale network may consist of various devices. On such a network, the diversity and the great number of devices bring a great challenge to network management, that is, how to effectively manage the complex network and provide high-quality network services.
Network management plays a critical role in the whole network solution. The following four elements are involved in the network management:
Managed node: is a device to be managed.
Agent: is the software or hardware that functions to trace the status of the managed node.
Manager: communicates with the agents that reside in managed nodes, and displays the status of the nodes.
Network management protocol: works to exchange information between the manager and the agents.
At present, the Simple Network Management Protocol (SNMP) is most widely used for network management over the TCP/IP-based networks.
SNMP-based Network Management
The SNMP-based network management consists of the following four components:
NMS
The network management station (NMS) is an independent device that runs the network management application. The network management application provides at least one human-machine interface (HMI) through which the network administrator manages the network.
SNMP agent
The agent is the software installed on the managed node. It receives and handles the request packets from the NMS, and returns responses to the NMS. In some urgent cases, the agent sends a trap packet to the NMS.
SNMP
As an application layer protocol in the TCP/IP suite, SNMP exchanges management information between the NMS and the managed node.
MIB
The Management Information Base (MIB) is a set of managed objects (MOs). It acts as a communication bridge between the NMS and the agent. The NMS manages the devices by using the MIB. Each agent maintains a MIB. The NMS reads or sets the value of an object contained in a MIB.
Figure 2-1 illustrates the SNMP-based network management.
The following describes the components shown in Figure 2-1 and the interoperation between them.
The NMS communicates with the agent through SNMP. The NMS monitors and manages the device where the agent resides by reading or writing the objects in the MIB.
SNMP is responsible for the communication between the NMS and the agent. Data is encapsulated in the protocol data unit (PDU) defined by SNMP. The SNMP packets are transferred through the transport layer protocol such as UDP.
The agent is a process running on a managed node. The agent interoperates with the NMS, maintains the MIB, and manages and monitors modules on the managed node.
The MIB stores the information about each module of the managed node. The NMS maintains and monitors a managed node by reading or writing the objects contained in the MIB.
SNMP
SNMP Version
There are three versions of SNMP: SNMPv1, SNMPv2c, and SNMPv3.
In SNMPv1 and SNMPv2c, the NMS controls the authority to access managed nodes by using the community name list. The agent does not check the validity of the community name. SNMP packets are transferred without encryption. That is, security is not guaranteed for authentication and confidentiality.
Compared with SNMPv1, SNMPv2c supports:
More operations and data types
Plenty of error codes
Multiple transport layer protocols
SNMPv3 provides all the functions of SNMPv1 and SNMPv2, and features a security mechanism that authenticates and encrypts SNMP packets. In terms of security, SNMPv3 emphasizes security of data and access control.
SNMPv3 ensures the security for SNMP packets in the following ways:
Data integrity check
The data cannot be modified in an unauthorized manner. The change of the data sequence is limited to the allowed extent.
Data origin authentication
SNMPv3 authenticates the managed node from which the received packet originates and not the application that generates the packet.
Data confidentiality
When the NMS or the agent receives a packet, it checks the time at which the packet is generated. If the difference between the creation time and the system time exceeds the threshold, the packet is discarded. In this way, the packets that are modified by malicious users are not accepted.
SNMPv3 control the access to the MOs by the operations of the protocol.
SNMP PDUs
SNMP defines five types of PDUs, namely SNMP packets, which are exchanged between the NMS and the agent.
Figure 2-2 shows the SNMP packets exchanged between the NMS and the agent.
The SNMP packets are described as follows:
get-request: indicates the NMS wants to fetch one or more parameters from the MIB of the agent.
get-next-request: indicates the NMS wants to fetch the next parameter from the MIB of the agent.
set-request: indicates that the NMS wants to set one or more parameters in the MIB of the agent.
get-response: returns one or more parameters. This packet is the response returned from the agent.
trap: are sent by the agent to inform the NMS of some important events. Sending trap packets does not require the request packets from the NMS.
The first three packets are sent from the NMS to the agent while the last two packets are sent from the agent to the NMS.
SNMP Packet Operation Process
The agent on the managed node receives a request packet from the NMS through UDP port 161.
The agent treats the received packet as follows:
Decoding the packet based on basic encoding rules of ASN.1 and representing it in an internal data structure
The agent discards the packet if some errors cause the decoding failure.
Checking the SNMP version number contained in the packet
The agent fetches the version number from the packet and compares it with the version that it supports. If they are inconsistent, the agent discards the packet.
Checking the community name contained in the packet
The community name is inserted by the NMS. If the community name is not the supported one, the agent discards the packet. A trap packet is returned to the NMS at the same time. SNMPv1 provides weak security measures, which are enhanced in SNMPv3.
Fetching the PDU from the authenticated ASN.1 object
If the operation fails, the agent discards the packet.
Handling the PDU. The agent handles the PDU according to its type. It searches the MIB to find the MO matching the variable, and then obtains the value of the variable from the module. After that, the agent generates the response packet, encodes it and returns it to the NMS.
The NMS performs the same operations as the agent, and displays the final result.
For SNMP configurations, refer to the S12700 and S12700E V200R019C10 Configuration Guide - Network Management and Monitoring.
MIB
A MIB is a collection of MOs. It defines the following attributes of an MO:
Object name
Access authority
Data type of the object
The Structure of Management Information (SMI) stipulates how to define and organize the MOs. It also defines the data types for these objects, for example, Counter and Gauge.
The MIB designates the variables maintained by the network elements. The variables are the information that can be queried and set by NMS. The MIB provides a data structure of the combination of the all the possibly managed objects on a network.
MIB Tree Structure
All the MOs in a network compose the tree structure of the MIB. The leaf nodes of the tree are managed objects. An MO is identified by the set of nodes along the path from the root to the leaf node. Such a path is called object identifier (OID).
Figure 2-3 shows the MIB tree structure.
An OID consists of positive integers and zero, and it is used to uniquely identify an MO in the MIB. The SMI ensures that each OID is unique within a MIB.
Once the MIB file is released, OIDs are bound to the MOs. The binding cannot be modified. The MOs in the MIB cannot be deleted, but can be set to obsolete indicating that the MO is not used.
In the tree structure shown in Figure 2-3, the MO mgmt is represented by { iso(1) org(3) dod(6) internet(1) mgmt(2) } or 1.3.6.1.2 that is called OID.
The NMS refers to an MO by specifying the OID.
MIB Classification
MIBs fall into the following two types:
Public MIBs
Defined by RFCs, the public MIBs allow the structure design of common protocols and the standardization of interfaces. Manufacturers design and offer SNMP interfaces according to the specifications defined in RFC.
Private MIBs
They are the supplement of the public MIBs. Some enterprises need to develop private protocols or special functions. The private MIBs are designed to enable the SNMP interface to manage such protocols or functions. They also help the NMS provided by the third party to manage devices.
MIB Concepts
MIB Objects and Nodes
As shown in Figure 2-4, IF-MIB is used as an example. A MIB tree consists of table, row, and column objects. The table object consists of row objects, and the row object consists of a series of column objects.
The MIB tree nodes are classified into:
Leaf node
A leaf node does not have subnodes in a MIB tree. The leaf nodes are classified into scalar nodes and table nodes.
Non-leaf node
The non-leaf node reflects the association between the subnodes, and cannot be accessed using the SNMP protocol.
In the MIB reference, the row object "Entry" is described as prefix. For example, the description of "The OID prefix of this table is 1.3.6.1.2.1.2.2" in ifTable corresponds to ifEntry.
MIB Compliance Statement
MIB compliance statement is used to describes how a feature module complies with the SNMP entity structure. MIB compliance statement cannot be operated using SNMP syntax. As shown in Figure 2-5, LLDP-MIB is used as an example. MIB compliance statement consists of compliances and group, which respectively indicate the number of MIB statements and a collection of objects which are used to configure the corresponding function.
MIB compliance statement describes how the feature module complies with the SNMP entity structure, and cannot be operated using SNMP syntax, so it is not included in MIB reference.
Maximum Access
The maximum access to MIB objects specifies the operations that can be performed on the MIB objects, as described in Table 2-1. For details about the operations that can be performed on a specified MIB object, see the MIB object description.
Maximum Access |
Description |
Operation |
---|---|---|
not-accessible |
No access right |
No operation can be performed. |
read-only |
Read-only |
Read information. |
read-write |
Read and write |
|
read-create |
Read and create |
|
accessible-for-notify |
Notify only |
Used for trap notification. |