
170
[Agent] snmp-agent mib-view included test ifTable
[Agent] snmp-agent group v3 managev3group privacy read-view test write-view test
# Assign the NMS (SNMPv3 group
managev3group
) read-only access to the objects under the
system
node (OID 1.3.6.1.2.1.1) and
hh3cUIMgt
node (OID 1.3.6.1.4.1.25506.2.2) in the
test
view.
[Agent] snmp-agent mib-view included test 1.3.6.1.2.1.1
[Agent] snmp-agent mib-view included test 1.3.6.1.4.1.25506.2.2
[Agent] snmp-agent group v3 managev3group privacy read-view test
# Add the user
managev3user
to the SNMPv3 group
managev3group
, and set the authentication
algorithm to
sha
, authentication key to
123456TESTauth&!
, encryption algorithm to
aes128
, and
privacy key to
123456TESTencr&!
.
[Agent] snmp-agent usm-user v3 managev3user managev3group simple authentication-mode
sha 123456TESTauth&! privacy-mode aes128 123456TESTencr&!
# Configure contact and physical location information for the agent.
[Agent] snmp-agent sys-info contact Mr.Wang-Tel:3306
[Agent] snmp-agent sys-info location telephone-closet,3rd-floor
# Enable notifications, specify the NMS at 1.1.1.2 as a trap destination, and set the username to
managev3user
for the traps.
[Agent] snmp-agent trap enable
[Agent] snmp-agent target-host trap address udp-domain 1.1.1.2 params securityname
managev3user v3 privacy
2.
Configure the SNMP NMS:
{
Specify SNMPv3.
{
Create the SNMPv3 user
managev3user
.
{
Enable both authentication and privacy functions.
{
Use SHA-1 for authentication and AES for encryption.
{
Set the authentication key to
123456TESTauth&!
and the privacy key to
123456TESTencr&!
.
{
Set the timeout time and maximum number of retries.
For information about configuring the NMS, see the NMS manual.
NOTE:
The SNMP settings on the agent and the NMS must match.
Verifying the configuration
# Try to get the value of
sysName
from the agent. The get attempt succeeds.
Send request to 1.1.1.1/161 ...
Protocol version: SNMPv3
Operation: Get
Request binding:
1: 1.3.6.1.2.1.1.5.0
Response binding:
1: Oid=sysName.0 Syntax=OCTETS Value=Agent
Get finished