77
Switch(Config)#snmp-server
2.4.3.6 snmp-server enable traps
Command: snmp-server enable traps
no snmp-server enable traps
Function:
Enable the switch to send Trap message; the “
no snmp-server enable traps
”
command disables the switch to send Trap message.
Command mode:
Global Mode
Default:
Trap message is disabled by default.
Usage Guide:
When Trap message is enabled, if Down/Up in device ports or of system
occurs, the device will send Trap messages to NMS that receives Trap messages.
Example 1:
Enable to send Trap messages.
Switch(config)#snmp-server enable traps
Example 2:
Disable to send Trap messages.
Switch(config)#no snmp-server enable trap
2.4.3.7 snmp-server host
Command: snmp-server host {<ipv4-addr>|<ipv6-addr>} {v1|v2c|{v3
{NoauthNopriv|AuthNopriv|AuthPriv}}} <user-string>
no snmp-server host {<ipv4-addr>|<ipv6-addr>} {v1|v2c|{v3
{NoauthNopriv|AuthNopriv |AuthPriv}}} <user-string>
Function:
As for the v1/v2c versions this command configures the IP address and trap
community character string of the network manage station receiving the SNMP Trap
message. And for v3 version, this command is used for receiving the network manage
station IP address and the Trap user name and safety level; the “no” form of this
command cancels this IP address.
Command Mode:
Global Mode
Parameter: <ipv4-addr>|<ipv6-addr>
is the IP address of the NMS managing station
which receives Trap message.
v1|v2c|v3 is the
version number when sending the trap
NoauthNopriv|AuthNopriv|AuthPriv
is the safety level v3 trap is applied, which may be
non encrypted and non authentication, non encrypted and authentication, encrypted and
authentication.
<
user-string>
is the community character string applied when sending the Trap
message at v1/v2, and will be the user name at v3
Usage Guide:
The Community character string configured in this command is the default
community string of the RMON event group. If the RMON event group has no community
character string configured, the community character string configured in this command