![H3C SR6600 SPE-FWM Command Reference Manual Download Page 134](http://html1.mh-extra.com/html/h3c/sr6600-spe-fwm/sr6600-spe-fwm_command-reference-manual_574801134.webp)
126
Parameters
v1
: Specifies SNMPv1.
v2c
: Specifies SNMPv2c.
user-name
: User name, a case-sensitive string of 1 to 32 characters.
group-name
: Group name, a case-sensitive string of 1 to 32 characters.
acl
acl-number
: Specifies a basic ACL to filter NMSs by source IPv4 address. The
acl-number
argument
represents a basic ACL number in the range of 2000 to 2999. Only the NMSs with the IPv4 addresses
permitted in the ACL can use the specified username (community name) to access the SNMP agent.
acl ipv6
ipv6-acl-number
: Specifies a basic ACL to filter NMSs by source IPv6 address. The
ipv6-acl-number
argument represents a basic ACL number in the range of 2000 to 2999. Only the NMSs
with the IPv6 addresses permitted in the ACL can use the specified username (community name) to
access the SNMP agent.
Usage guidelines
Make sure you have created the SNMPv1 or SNMPv2c group.
When you create an SNMPv1 or SNMPv2c user, the system automatically creates a read-only
community that has the same name as the SNMPv1 or SNMPv2c username. To change the access right
of this community to write access, use the
snmp-agent community
command or the
snmp-agent group
{
v1
|
v2c
} command. To display the SNMPv1 and SNMPv2c communities created in this way, use the
display snmp-agent community
command.
The
snmp-agent usm-user
{
v1
|
v2c
} command enables managing SNMPv1 and SNMPv2c users in the
same way as managing SNMPv3 users. It does not affect the way of configuring SNMPv1 and
SNMPv2c communities on the NMS.
This command is supported only in non-FIPS mode.
Examples
# Add the user
userv2c
to the SNMPv2c group
readCom
so an NMS can use the protocol SNMPv2c and
the read-only community name
userv2c
to access the SNMP agent.
<Sysname> system-view
[Sysname] snmp-agent sys-info version v2c
[Sysname] snmp-agent group v2c readCom
[Sysname] snmp-agent usm-user v2c userv2c readCom
# Add the user
userv2c
in the SNMPv2c group
readCom
so only the NMS at 1.1.1.1 can use the protocol
SNMPv2c and read-only community name
userv2c
to access the SNMP agent.
<Sysname> system-view
[Sysname] acl number 2001
[Sysname-acl-basic-2001] rule permit source 1.1.1.1 0.0.0.0
[Sysname-acl-basic-2001] rule deny source any
[Sysname-acl-basic-2001] quit
[Sysname] snmp-agent sys-info version v2c
[Sysname] snmp-agent group v2c readCom
[Sysname] snmp-agent usm-user v2c userv2c readCom acl 2001
Related commands
•
display snmp-agent community
•
snmp-agent group
Summary of Contents for SR6600 SPE-FWM
Page 8: ...vi Index 254 ...