1SNMPTRANSLATE(1)                   Net-SNMP                   SNMPTRANSLATE(1)
2
3
4

NAME

6       snmptranslate  -  translate  MIB  OID names between numeric and textual
7       forms
8

SYNOPSIS

10       snmptranslate [OPTIONS] OID [OID]...
11       snmptranslate [OPTIONS] -
12

DESCRIPTION

14       snmptranslate is an application that translates one or more SNMP object
15       identifier values from their symbolic (textual) forms into their numer‐
16       ical forms (or vice versa).
17
18       OID is either a numeric or textual object identifier.
19
20       The special - argument is used to translate multiple object IDs in  one
21       run.   Input is taken from stdin, and output is written to stdout.  The
22       input format can be a single object ID per line, or can be  the  output
23       of snmpwalk or snmpget .
24

OPTIONS

26       -D[TOKEN[,...]]
27               Turn  on  debugging output for the given TOKEN(s).  Try ALL for
28               extremely verbose output.
29
30       -h      Display a brief usage message and then exit.
31
32       -m MIBLIST
33               Specifies a colon separated list of MIB  modules  to  load  for
34               this  application.   This  overrides  the  environment variable
35               MIBS.
36
37               The special keyword ALL is used to specify all modules  in  all
38               directories  when  searching  for  MIB files.  Every file whose
39               name does not begin with "." will be parsed as if it were a MIB
40               file.
41
42       -M DIRLIST
43               Specifies  a  colon separated list of directories to search for
44               MIBs.  This overrides the environment variable MIBDIRS.
45
46       -T TRANSOPTS
47               Provides control over the translation of the OID  values.   The
48               following TRANSOPTS are available:
49
50               -TB   Print all matching objects for a regex search.
51
52               -Td   Print full details of the specified OID.
53
54               -Tp   Print a graphical tree, rooted at the specified OID.
55
56               -Ta   Dump the loaded MIB in a trivial form.
57
58               -Tl   Dump a labeled form of all objects.
59
60               -To   Dump a numeric form of all objects.
61
62               -Ts   Dump a symbolic form of all objects.
63
64               -Tt   Dump  a  tree  form of the loaded MIBs (mostly useful for
65                     debugging).
66
67               -Tz   Dump a numeric and labeled form of all objects  (compati‐
68                     ble with MIB2SCHEMA format).
69
70       -V      Display version information for the application and then exit.
71
72       -w WIDTH
73               Specifies  the width of -Tp and -Td output. The default is very
74               large.
75
76       In addition to the above options, snmptranslate  takes  the  OID  input
77       (-I), MIB parsing (-M) and OID output (-O) options described in the IN‐
78       PUT OPTIONS, MIB PARSING OPTIONS and OUTPUT OPTIONS sections of the sn‐
79       mpcmd(1) manual page.
80

EXAMPLES

82       •   snmptranslate -On -IR sysDescr
83           will translate "sysDescr" to a more qualified form:
84
85           system.sysDescr
86
87       •   snmptranslate -Onf -IR sysDescr
88           will translate "sysDecr" to:
89
90           .iso.org.dod.internet.mgmt.mib-2.system.sysDescr
91
92       •   snmptranslate -Td -OS system.sysDescr
93           will translate "sysDecr" into:
94
95           SNMPv2-MIB::sysDescr
96           sysDescr OBJECT-TYPE
97             -- FROM SNMPv2-MIB
98             -- TEXTUAL CONVENTION DisplayString
99             SYNTAX OCTET STRING (0..255)
100             DISPLAY-HINT "255a"
101             MAX-ACCESS read-only
102             STATUS current
103             DESCRIPTION "A textual description of the entity. This
104                          value should include the full name and
105                          version identification of the system's
106                          hardware type, software operating-system,
107                          and networking software."
108           ::= { iso(1) org(3) dod(6) internet(1) mgmt(2) mib-2(1) system(1) 1 }
109
110       •   snmptranslate -Tp -OS system
111           will print the following tree:
112
113           +--system(1)
114              |
115              +-- -R-- String    sysDescr(1)
116              |        Textual Convention: DisplayString
117              |        Size: 0..255
118              +-- -R-- ObjID     sysObjectID(2)
119              +-- -R-- TimeTicks sysUpTime(3)
120              +-- -RW- String    sysContact(4)
121              |        Textual Convention: DisplayString
122              |        Size: 0..255
123              +-- -RW- String    sysName(5)
124              |        Textual Convention: DisplayString
125              |        Size: 0..255
126              +-- -RW- String    sysLocation(6)
127              |        Textual Convention: DisplayString
128              |        Size: 0..255
129              +-- -R-- Integer   sysServices(7)
130              +-- -R-- TimeTicks sysORLastChange(8)
131              |        Textual Convention: TimeStamp
132              |
133              +--sysORTable(9)
134                 |
135                 +--sysOREntry(1)
136                    |
137                    +-- ---- Integer   sysORIndex(1)
138                    +-- -R-- ObjID     sysORID(2)
139                    +-- -R-- String    sysORDescr(3)
140                    |        Textual Convention: DisplayString
141                    |        Size: 0..255
142                    +-- -R-- TimeTicks sysORUpTime(4)
143                             Textual Convention: TimeStamp
144
145
146       •   snmptranslate -Ta | head
147           will produce the following dump:
148
149           dump DEFINITIONS ::= BEGIN
150           org ::= { iso 3 }
151           dod ::= { org 6 }
152           internet ::= { dod 1 }
153           directory ::= { internet 1 }
154           mgmt ::= { internet 2 }
155           experimental ::= { internet 3 }
156           private ::= { internet 4 }
157           security ::= { internet 5 }
158           snmpV2 ::= { internet 6 }
159
160       •   snmptranslate -Tl | head
161           will produce the following dump:
162
163           .iso(1).org(3)
164           .iso(1).org(3).dod(6)
165           .iso(1).org(3).dod(6).internet(1)
166           .iso(1).org(3).dod(6).internet(1).directory(1)
167           .iso(1).org(3).dod(6).internet(1).mgmt(2)
168           .iso(1).org(3).dod(6).internet(1).mgmt(2).mib-2(1)
169           .iso(1).org(3).dod(6).internet(1).mgmt(2).mib-2(1).system(1)
170           .iso(1).org(3).dod(6).internet(1).mgmt(2).mib-2(1).system(1).sysDescr(1)
171           .iso(1).org(3).dod(6).internet(1).mgmt(2).mib-2(1).system(1).sysObjectID(2)
172           .iso(1).org(3).dod(6).internet(1).mgmt(2).mib-2(1).system(1).sysUpTime(3)
173
174       •   snmptranslate -To | head
175           will produce the following dump
176
177           .1.3
178           .1.3.6
179           .1.3.6.1
180           .1.3.6.1.1
181           .1.3.6.1.2
182           .1.3.6.1.2.1
183           .1.3.6.1.2.1.1
184           .1.3.6.1.2.1.1.1
185           .1.3.6.1.2.1.1.2
186           .1.3.6.1.2.1.1.3
187
188       •   snmptranslate -Ts | head
189           will produce the following dump
190
191           .iso.org
192           .iso.org.dod
193           .iso.org.dod.internet
194           .iso.org.dod.internet.directory
195           .iso.org.dod.internet.mgmt
196           .iso.org.dod.internet.mgmt.mib-2
197           .iso.org.dod.internet.mgmt.mib-2.system
198           .iso.org.dod.internet.mgmt.mib-2.system.sysDescr
199           .iso.org.dod.internet.mgmt.mib-2.system.sysObjectID
200           .iso.org.dod.internet.mgmt.mib-2.system.sysUpTime
201
202       •   snmptranslate -Tt | head
203           will produce the following dump
204
205             org(3) type=0
206               dod(6) type=0
207                 internet(1) type=0
208                   directory(1) type=0
209                   mgmt(2) type=0
210                     mib-2(1) type=0
211                       system(1) type=0
212                         sysDescr(1) type=2 tc=4 hint=255a
213                         sysObjectID(2) type=1
214                         sysUpTime(3) type=8
215
216       •   snmptranslate -OX -
217           with the following input:
218
219           SNMPv2-SMI::mib-2.14.1.1.0 = IpAddress: 192.0.2.1
220           SNMPv2-SMI::mib-2.14.1.2.0 = INTEGER: 1
221           SNMPv2-SMI::mib-2.14.1.3.0 = INTEGER: 2
222
223           will produce the following output:
224
225           OSPF-MIB::ospfRouterId.0 = IpAddress: 192.0.2.1
226           OSPF-MIB::ospfAdminStat.0 = INTEGER: 1
227           OSPF-MIB::ospfVersionNumber.0 = INTEGER: 2
228
229

SEE ALSO

231       snmpcmd(1), variables(5), RFC 2578-2580.
232
233
234
235V5.9.1                            13 Nov 2013                 SNMPTRANSLATE(1)
Impressum