subscribe iconSubscribe to this information
POWER7 information

snmp_info command

Purpose

Requests or modifies values of Management Information Base (MIB) variables managed by a Simple Network Management Protocol (SNMP) agent.

Syntax

snmp_info [-mode get | next] [-verbose] [-com Community] [-debug Level] [-host HostName] [-file ObjectFile] [-retry Tries] [-wait WaitTime ] Variable.Instance

The following syntax is for the set option:

snmp_info -mode set [-verbose] [-com Community] [-debug Level] [-host HostName] [-file ObjectFile] [-retry Tries] [-wait WaitTime ] Variable.Instance=Value

The following syntax is for the dump option:

snmp_info -mode dump [-verbose] [-com Community] [-debug Level] [-host HostName] [-file ObjectFile] [-retry Tries] [-wait WaitTime ] [Variable.Instance]

Description

The snmp_info command requests or modifies values for one or more Management Information Base (MIB) variables managed by a Simple Network Management Protocol (SNMP) agent. This command may only be issued by a user with root privileges or by a member of the system group.

If you specify the get option, the snmp_info command requests information about one or more MIB variables from an SNMP agent.

If you specify the next option, the snmp_info command requests information from an SNMP agent about the instances following the specified instances. The next option makes it possible to obtain MIB values without knowledge of the instance qualifiers.

If you specify the set option, the snmp_info command modifies values for one or more MIB variables for an SNMP agent. Only a few MIB variables are designated read-write. The agent that manages the MIB database may take various actions as a side effect of modifying MIB variables. For example, setting the ifAdminStatus MIB variable to 2 will normally shut down a network interface. The action taken is determined by the implementation of the SNMP agent that manages the database.

If you specify the dump option, the snmp_info command can be used to traverse the entire MIB tree of a given agent. If a group is passed in as the Variable parameter, the snmp_info command will traverse that specified path of the MIB tree.

The snmp_info command has a debug facility that dumps the debug information for transmitted and received packets. The facility is enabled with the -debug flag.

Flags

Flag name Description
-com Community Specifies the community name to be used to query. If you do not specify this flag, the default community name is public.
-debug Level Specifies the level of I/O debug information. Use one of the following values:
0
No debug information.
1
Port bindings and the number of bytes transmitted and received.
2
Level 1 plus a hexadecimal dump of incoming and outgoing packets.
3
Level 2 plus an English version of the request and response packets.
If you do not specify this flag, the default debug level is 0.
-host HostName Specifies the host name of the SNMP agent to be queried. If you do not specify this flag, the default host name is the host name of the system on which the user is currently logged.
-file ObjectFile Specifies the name of the objects definition file. If you do not specify this flag, the default objects definition file name is /etc/mib.defs.
-mode Option Specifies the mode by which to access the MIB variables. The value can be one of the following options:
get
Requests information about the specified MIB variables
next
Requests the instances following the specified instances
set
Modifies the specified write access MIB variables
dump
Dumps the specified section of the MIB tree
Note:
  1. The option name can be specified by the minimum number of characters required to make it unique.
  2. If you do not specify this flag, the default mode is get.
-retry Tries Specifies the number of times the snmp_info command transmits the SNMP request to the SNMP agent before ending with the message no SNMP response. If you do not specify this flag, the default number of tries is 3.
-verbose Specifies that the output from the snmp_info command be displayed in verbose mode. If you do not specify this flag, the information will not be displayed in verbose mode.
-wait Specifies the wait time in seconds for the response from the snmpd agent. If you do not specify this flag, the default wait time is 15 seconds.

Parameters

Parameter Description
Value Specifies the value to which the MIB Variable parameter is to be set. A value must be specified for each variable. If a value is not specified, the request packet will be invalid.
Variable Specifies the name in text format or numeric format of a specific MIB variable as defined in the /etc/mib.defs file. If the option to the -mode flag is next or dump, the Variable parameter may be specified as a MIB group.
Instance Specifies the instance qualifier for the MIB Variable parameter. The Instance parameter is required if the option to the -mode flag is get or set. The Instance parameter is optional if the option to the -mode flag is next or dump.
Note:
  1. There should be no blank spaces in the Variable.Instance parameter sequence.
  2. If the Instance parameter is not specified, do not place a period after the Variable parameter.

For further information, consult RFC 1213, which defines the Management Information Base (MIB) for network management, and RFC 1157, which defines the SNMP protocol for creating requests for MIB information and formatting responses.

Exit Status

See Exit status for Virtual I/O Server commands.

Examples

To display the current system information and snmp configuration information, type the following command:
snmp_info -mode dump system


Send feedback Rate this page

Last updated: Wed, June 03, 2015