Skip to main content

snmp command

Use this command to display and configure SNMP interface information.

Running the snmp command with no options displays all SNMP interface information. The following table shows the arguments for the options.

Table 1. snmp command.

The following table is a multi-row three column table consisting of the options, option descriptions, and associated values for the options.

OptionDescriptionValues
-aSNMPv1 agenton, off
Note
To enable the SNMPv1 agent, the following criteria must be met:
  • IMM2 contact specified using the -cn command option.
  • IMM2 location specified using the -l command option.
  • At least one SNMP community name specified using one of the -cx command options.
  • At least one valid IP address is specified for each SNMP community using one of the -cxiy command options.
-a3SNMPv3 agenton, off
Note
To enable the SNMPv3 agent, the following criteria must be met:
  • IMM2 contact specified using the -cn command option.
  • IMM2 location specified using the -l command option.
-tSNMP trapson, off
-lIMM2 locationString (limited to 47 characters).
Note
  • Arguments containing spaces must be enclosed in quotation marks. No leading or trailing spaces are allowed in arguments.
  • Clear the IMM2 location by specifying no argument or by specifying an empty string as the argument, such as "".
-cnIMM2 contact nameString (limited to 47 characters).
Note
  • Arguments containing spaces must be enclosed in quotation marks. No leading or trailing spaces are allowed in arguments.
  • Clear the IMM2 contact name by specifying no argument or by specifying an empty string as the argument, such as "".
-cxSNMP community x nameString (limited to 15 characters).
Note
  • x is specified as 1, 2, or 3 in the command option to indicate the community number.
  • Arguments containing spaces must be enclosed in quotation marks. No leading or trailing spaces are allowed in arguments.
  • Clear an SNMP community name by specifying no argument or by specifying an empty string as the argument, such as "".
-cxiySNMP community x IP address or hostname yValid IP address or hostname (limited to 63 characters).
Note
  • x is specified as 1, 2, or 3 in the command option to indicate the community number.
  • y is specified as 1, 2, or 3 in the command option to indicate the IP address or hostname number.
  • An IP address or hostname can only contain dots, underscores, minus signs, letters and digits. No embedded spaces or consecutive periods are allowed.
  • Clear an SNMP community IP address or hostname by specifying no argument.
-caxSNMPv3 community x access typeget, set, trap
Note
x is specified as 1, 2, or 3 in the command option to indicate the community number.
Syntax:
snmp [<em className="ph i">options</em>]
option:
-a <em className="ph i">state</em>
-a3 <em className="ph i">state</em>
-t <em className="ph i">state</em>
-l <em className="ph i">location</em>
-cn <em className="ph i">contact_name</em>
-c1 <em className="ph i">snmp_community_1_name</em>
-c2 <em className="ph i">snmp_community_2_name</em>
-c3 <em className="ph i">snmp_community_3_name</em>
-c1i1 <em className="ph i">community_1_ip_address_or_hostname_1</em>
-c1i2 <em className="ph i">community_1_ip_address_or_hostname_2</em>
-c1i3 <em className="ph i">community_1_ip_address_or_hostname_3</em>
-c2i1 <em className="ph i">community_2_ip_address_or_hostname_1</em>
-c2i2 <em className="ph i">community_2_ip_address_or_hostname_2</em>
-c2i3 <em className="ph i">community_2_ip_address_or_hostname_3</em>
-c3i1 <em className="ph i">community_3_ip_address_or_hostname_1</em>
-c3i2 <em className="ph i">community_3_ip_address_or_hostname_2</em>
-c3i3 <em className="ph i">community_3_ip_address_or_hostname_3</em>
-ca1 <em className="ph i">community_1_access_type</em>
-ca2 <em className="ph i">community_2_access_type</em>
-ca3 <em className="ph i">community_3_access_type</em>
Example:
system> snmp
-a Enabled
-a3 Enabled
-t Enabled
-l RTC,NC
-cn Snmp Test
-c1 public
-c1i1 192.44.146.244
-c1i2 192.44.146.181
-c1i3 192.44.143.16
-ca1 set
-ch1 specific
-c2 private
-c2i1 192.42.236.4
-c2i2
-c2i3
-ca2 get
-ch2 specific
-c3
-c3i1
-c3i2
-c3i3
-ca3 get
-ch3 ipv4only
system>