-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathNET-SNMP-TUTORIAL-MIB.txt
128 lines (104 loc) · 4.03 KB
/
NET-SNMP-TUTORIAL-MIB.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
NET-SNMP-TUTORIAL-MIB DEFINITIONS ::= BEGIN
-- A Comment!
-- IMPORTS: Include definitions from other mibs here, which is always
-- the first item in a MIB file.
IMPORTS
netSnmpExamples FROM NET-SNMP-EXAMPLES-MIB
OBJECT-TYPE, Integer32,
MODULE-IDENTITY FROM SNMPv2-SMI
MODULE-COMPLIANCE, OBJECT-GROUP FROM SNMPv2-CONF;
--
-- A brief description and update information about this mib.
--
netSnmpTutorialMIB MODULE-IDENTITY
LAST-UPDATED "200205290000Z" -- 29 May 2002, midnight
ORGANIZATION "net-snmp"
CONTACT-INFO "postal: Wes Hardaker
P.O. Box 382
Davis CA 95617
email: [email protected]
"
DESCRIPTION "A simple mib for demonstration purposes.
"
::= { netSnmpExamples 4 }
-- Define typical mib nodes, like where the objects are going to lie.
-- we'll prefix everything in this mib with nst (net snmp tutorial)
nstMIBObjects OBJECT IDENTIFIER ::= { netSnmpTutorialMIB 1 }
nstMIBConformance OBJECT IDENTIFIER ::= { netSnmpTutorialMIB 2 }
-- define 3 objects, which will all be implemented in different ways
-- within the tutorial.
nstAgentModules OBJECT IDENTIFIER ::= { nstMIBObjects 1 }
nstAgentModuleObject OBJECT-TYPE
SYNTAX Integer32
MAX-ACCESS read-write
STATUS current
DESCRIPTION
"This is an object that simply supports a writable integer
when compiled into the agent. See
http://www.net-snmp.org/tutorial-5/toolkit/XXX for further
implementation details."
DEFVAL { 1 }
::= { nstAgentModules 1 }
nstAgentSubagentObject OBJECT-TYPE
SYNTAX Integer32
MAX-ACCESS read-write
STATUS current
DESCRIPTION
"This is an object that simply supports a writable integer
when attached to the agent. The object should be accessible
when the agentx subagent containing this object is attached.
See http://www.net-snmp.org/tutorial-5/toolkit/XXX for
further implementation details."
DEFVAL { 2 }
::= { nstAgentModules 2 }
nstAgentPluginObject OBJECT-TYPE
SYNTAX Integer32
MAX-ACCESS read-write
STATUS current
DESCRIPTION
"This is an object that simply supports a writable integer
when attached to the agent. This object should be accessible
when the dynamic plugin has been loaded into the agent. See
http://www.net-snmp.org/tutorial-5/toolkit/XXX for further
implementation details."
DEFVAL { 3 }
::= { nstAgentModules 3 }
--
-- The above definitions produce a section of the mib tree that looks
-- like this (including our parent node, printed using the
-- snmptranslate command):
--
--
-- % snmptranslate -M+. -mNET-SNMP-TUTORIAL-MIB -Tp -IR netSnmpTutorialMIB
-- +-netSnmpTutorialMIB(4)
-- |
-- +-nstMIBObjects(1)
-- | |
-- | +-nstAgentModules(1)
-- | |
-- | +- -RW- Integer32 nstAgentModuleObject(1)
-- | +- -RW- Integer32 nstAgentSubagentObject(2)
-- | +- -RW- Integer32 nstAgentPluginObject(3)
-- |
-- +-nstMIBConformance(2)
-- You can then use the snmptranslate command to get the numerical or
-- textual OID representation of any piece of the tree:
-- Getting a OID:
-- % snmptranslate -M+. -mNET-SNMP-TUTORIAL-MIB -IR nstSSSecondsSinceChanged
-- .1.3.6.1.4.1.2021.13.4242.1.1.2
-- Getting a textual OID:
-- % snmptranslate -On -M+. -mNET-SNMP-TUTORIAL-MIB -IR nstSSSecondsSinceChanged
-- enterprises.ucdavis.ucdExperimental.netSnmpTutorialMIB.nstMIBObjects.nstScalarSet.nstSSSecondsSinceChanged
-- Getting a description:
-- % snmptranslate -Td -M+. -mNET-SNMP-TUTORIAL-MIB -IR nstSSSecondsSinceChanged
-- .1.3.6.1.4.1.2021.13.4242.1.1.2
-- SYNTAX TimeTicks
-- UNITS "1/100th Seconds"
-- MAX-ACCESS read-only
-- STATUS current
-- DESCRIPTION "This object indicates the number of 1/100th seconds since the
-- nstSSSimpleString object has changed. If it is has never been
-- modified, it will be the time passed since the start of the
-- agent."
-- END: Don't forget this!
END