196
<Sysname> system-view
[Sysname] snmp-agent group v3 testGroup privacy
[Sysname] snmp-agent usm-user v3 testUser testGroup simple authentication-mode sha
123456TESTauth&! privacy-mode aes128 123456TESTencr&!
For an NMS to access the MIB objects in default view, make sure the following configurations are the
same on both the NMS and the SNMP agent:
SNMP protocol version.
SNMPv3 username.
Authentication algorithm.
Privacy algorithm.
Plaintext authentication and privacy keys.
# Specify engine ID 123456789A for the NMS at 10.1.1.1. Create SNMPv3 group testGroup and
specify the authentication with privacy security model for the group. Add user testUser to the group.
Specify NMS at 10.1.1.1 as the target host. Specify authentication algorithm HMAC-SHA1,
encryption algorithm AES, plaintext-form authentication key 123456TESTauth&!, and plaintext-form
encryption key 123456TESTencr&! for the user.
<Sysname> system-view
[Sysname] snmp-agent remote 10.1.1.1 engineid 123456789A
[Sysname] snmp-agent group v3 testGroup privacy
[Sysname] snmp-agent usm-user v3 remoteUser testGroup remote 10.1.1.1 simple
authentication-mode sha 123456TESTauth&! privacy-mode aes128 123456TESTencr&!
In RBAC mode:
# Create SNMPv3 user testUser with user role network-operator. Specify authentication algorithm
HMAC-SHA1 and plaintext-form authentication key 123456TESTplat&! for the user.
<Sysname> system-view
[Sysname] snmp-agent usm-user v3 testUser user-role network-operator simple
authentication-mode sha 123456TESTplat&!
For an NMS to have read-only access to all MIB objects, make sure the following configurations are
the same on both the NMS and the SNMP agent:
SNMP protocol version.
SNMPv3 username.
Authentication algorithm and key.
Related commands
display snmp-agent usm-user
snmp-agent calculate-password
snmp-agent group
snmp-agent remote
snmp-agent usm-user v3 user-role
snmp-agent usm-user v3 user-role
Use snmp-agent usm-user v3 user-role to assign a user role to an SNMPv3 user created in RBAC
mode.
Use undo snmp-agent usm-user user-role to remove a user role.