Provides sample input to the mosy command.
The /usr/samples/snmpd/mibII.my file is a sample input file to the mosy command, which creates an objects definition file for use by the snmpinfo command. The mosy compiler requires its input file to contain the ASN.1 definitions as described in the Structure and Identification of Management Information (SMI) RFC 1155 and the Management Information Base (MIB) RFC 1213. The mibII.my file contains the ASN.1 definitions from the MIB RFC 1213 (MIB II). RFC is the abbreviation for Request for Comments.
Comments are specified by - - (two dashes). A comment can begin at any location after the comment sign and extend to the end of the line.
The mibII.my file begins with a definition of the SNMP subtree of the MIB, as assigned by the Internet Activities Board (IAB). This definition contains the name of the RFCs from which the ASN.1 definitions are obtained.
RFC1213-MIB {iso org(3) dod(6) internet(1) mgmt(2) 1 } DEFINITIONS ::= BEGIN IMPORTS mgmt, NetworkAddress, IpAddress, Counter, Gauge, TimeTicks FROM RFC1155-SMI OBJECT-TYPE from RFC-1213; mib-2 OBJECT IDENTIFIER ::= { mgmt 1 }-- MIB-II system OBJECT IDENTIFIER ::= { mib-2 1 } interfaces OBJECT IDENTIFIER ::= { mib-2 2 } at OBJECT IDENTIFIER ::= { mib-2 3 } ip OBJECT IDENTIFIER ::= { mib-2 4 } icmp OBJECT IDENTIFIER ::= { mib-2 5 } tcp OBJECT IDENTIFIER ::= { mib-2 6 } udp OBJECT IDENTIFIER ::= { mib-2 7 } egp OBJECT IDENTIFIER ::= { mib-2 8 } -- cmot OBJECT IDENTIFIER ::= { mib-2 9 } transmission OBJECT IDENTIFIER ::= { mib-2 10} snmp OBJECT IDENTIFIER ::= { mib-2 11}
The file must contain the ASN.1 definition for each MIB variable. The ASN.1 definition is presented in an OBJECT-TYPE macro.
Following is the format of an OBJECT-TYPE macro:
ObjectDescriptor OBJECT-TYPE SYNTAX ObjectSyntax ACCESS AccessMode STATUS StatusType DESCRIPTION Description ::= {ObjectGroup Entry}
The following definitions
describe the pieces of the macro:
The ObjectGroup and Entry variables are used to specify the unique numerical object identifier for each MIB variable. See RFC 1155 for an explanation of the object identifier.
See RFC 1155 for further information on the OBJECT-TYPE macro.
This sample mibII.my file was created by extracting the definitions from Chapter 6, "Definitions," of RFC 1213. This file is shipped as /usr/samples/snmpd/mibII.my.
The following example of an OBJECT-TYPE macro describes the sysDescr managed object:
sysDescr OBJECT-TYPE SYNTAX DisplayString (SIZE (0..255)) ACCESS read-only STATUS mandatory DESCRIPTION A textual description of the entity. This value should include the full name and version identification of system's hardware type,software operating-system, and networking software. It is mandatory that this only contain printable ASCII characters. ::= { system 1 }
/usr/samples/snmpd/mibII.my | Specifies the path of the mibII.my file. |
/usr/samples/snmpd/smi.my | Defines the ASN.1 definitions by which the SMI is defined in RFC 1155. |
/etc/mib.defs | Defines the Management Information Base (MIB) variables the snmpd agent should recognize and handle. This file is in the format which the snmpinfo command requires. |
This file is part of Simple Network Management Protocol Agent Applications in Network Support Facilities in Base Operating System (BOS) Runtime.
The mosy command, snmpinfo command.
The smi.my file.
Management Information Base (MIB) and Terminology Related to Management Information Base (MIB) Variables in AIX 5L Version 5.1 Communications Programming Concepts.
Rose, Marshall T. The Simple Book, An Introduction to Internet Management. Englewood Cliffs, NJ, Prentice Hall, 1994.