snmpgetone(1M) TCP/IP 5.4R3.00 snmpgetone(1M)
NAME
snmpgetone, getone - get MIB-object from SNMP agent,
SYNOPSIS
snmpgetone [-n][-t] host community object ...
where:
host is a hostname or Internet address
community is a community string
object is a fully qualified object name
DESCRIPTION
Use the snmpgetone command to retrieve the values for object
instances from an SNMP agent. The snmpgetone command sends a request
for object to the agent running on host. The agent authenticates the
request by checking that community has read access to object. If
community does not have read access, the request is discarded and
snmpgetone will fail due to a timeout. If community does have read
access, the agent returns the value for the requested object
instance. If any of the objects in the request do not exist, the
entire request will fail with a "No such variable name" message.
The snmpgetone command is new in DG/UX 5.4R3.00 and has a different
output format than the original getone command. The getone command
is provided for backward compatibility, but it will be removed in a
future release.
Specify host as either a hostname or as an Internet address in dot-
notation.
The community string is a text string used by the agent to
authenticate the request. You must configure the agent to allow read
access for community for the operation to be successful.
The object specified must be fully qualified, which means that it
should represent an object instance instead of an object type. For
example, sysDescr represents an object type while sysDescr.0
represents an object instance. You may specify the object in either
dot-notation representing the object identifier or as a text string
representing the object descriptor.
Options are:
-n Display Object ID's in a numeric format instead of translating
them into a symbolic name.
-t Display the data type of the object in addition to its name
and value.
EXAMPLE
$ snmpgetone myhost public sysDescr.0 sysUpTime.0 1.3.6.1.2.1.2.1.1
sysDescr.0 = DG/UX TCP/IP SNMP AGENT
sysUpTime.0 = 964922
ifNumber.0 = 2
Licensed material--property of copyright holder(s) 1
snmpgetone(1M) TCP/IP 5.4R3.00 snmpgetone(1M)
DIAGNOSTICS
Exit status is 0 upon success.
Exit status is -1 if there are errors parsing the command line.
Exit status is 1 if the agent returns an error.
SEE ALSO
snmpgetmany(1M), snmpgetnext(1M), snmpsetany(1M), snmptraprecv(1M),
snmptrapsend(1M), snmpgettab(1M), snmpd(1M), snmpd.conf(4M),
snmpdfiles(4M).
Licensed material--property of copyright holder(s) 2