This chapter describes three methods to connect Huawei Router to the NMS.
You can connect a device to the NMS using SNMPv1, SNMPv2c, or SNMPv3.
Prerequisite
- The device is running properly.
- An IP address has been configured for the interface connecting the device to the NMS.
- A reachable route exists between Huawei ME60 and the NMS.
Data preparation
Below lists the data required for connecting the device to the NMS.
Item | Data | Remarks |
|---|
SNMP version of the ME60 | V1/V2C/V3 | The value can be v1, v2c, or v3. |
IP address of the NMS | 192.167.1.10 | None. |
Parameters of SNMPv1, including SNMP read and write community names and the ACL number. | - read community name: comaccess
- write community name: mgr
- ACL number: 2000
| None. |
Parameters of SNMPv2c, including SNMP read and write community names and the ACL number. | - read community name: comaccess
- write community name: mgr
- ACL number: 2001
| None. |
Parameters of SNMPv3, including SNMP group and user names and the ACL number. | - SNMP group name: NMS
- SNMP user name: John
- ACL number: 2002
| None. |
NOTE:SNMPv3 is recommended because it provides more secure functions than other SNMP protocols
Procedure
- Configure SNMPv1.
- Configure basic functions of SNMPv1 on the ME60.
# Configure SNMP version.
<HUAWEI> system-view[HUAWEI] snmp-agent[HUAWEI] snmp-agent sys-info version v1
# Set the SNMP community name: the read community name of ME60 is comaccess comaccessand the write community name is mgr. For details, see snmp-agent community.
[HUAWEI] snmp-agent community read comaccess acl 2000[HUAWEI] snmp-agent community write mgr acl 2000
- Configure access control in SNMPv1. For more information, please refer to rule (basic ACL view).
[HUAWEI] acl 2000[HUAWEI-acl-basic-2000] rule permit source 192.167.1.10 0[HUAWEI-acl-basic-2000] quit
- Configure trap functions and set the IP address of the trap server to be the IP address of the NMS, 192.167.1.10.
NOTE:The trap function must be configured so that the NMS can receive the alarms from the device.
[HUAWEI] snmp-agent trap enable[HUAWEI] snmp-agent target-host trap address udp-domain 192.167.1.10 params securityname comaccess v1 private-netmanager
- Configure SNMPv2c.
- Configure basic functions of SNMPv2c on the ME60.
# Configure SNMP version.
<HUAWEI> system-view[HUAWEI] snmp-agent[HUAWEI] snmp-agent sys-info version v2c
# Set the SNMP community name: the read community name of ME60 is comaccess and the write community name is mgr. For details, see snmp-agent community.
[HUAWEI] snmp-agent community read comaccess acl 2001[HUAWEI] snmp-agent community write mgr acl 2001
- Configure Community-Name-based access control in SNMPv2c. For more information, see rule (basic ACL view).
[HUAWEI] acl 2001[HUAWEI-acl-basic-2001] rule permit source 192.167.1.10 0[HUAWEI-acl-basic-2001] quit
- Configure trap functions and set the IP address of the trap server to be the IP address of the NMS, 192.167.1.10. For more information, see snmp-agent target-host trap.
NOTE:The trap function must be configured so that the NMS can receive the alarms from the device.
[HUAWEI] snmp-agent trap enable[HUAWEI] snmp-agent target-host trap address udp-domain 192.167.1.10 params securityname comaccess v1 private-netmanager
- Configure SNMPv3.
- Configure basic functions of SNMPv3 on the ME60. ME60
# Configure SNMP version.
<HUAWEI> system-view[HUAWEI] snmp-agent[HUAWEI] snmp-agent sys-info version v3
- Configure User-based access control in SNMPv3.
# Configure an SNMP user group, and the user group name is NMS.
[HUAWEI] snmp-agent group v3 NMS
# Configure user information. For example, Add a user named John to the SNMP group named Johngroup, with the security level being authentication, the authentication protocol being HMAC-MD5-96 and the password being hello. For more information, see the command snmp-agent usm-user.
[HUAWEI] snmp-agent usm-user v3 John Johngroup authentication-mode md5 hello
# Configure a basic ACL. For more information, see the command rule (basic ACL view).
[HUAWEI] acl 2002[HUAWEI-acl-basic-2002] rule permit source 192.167.1.10 0[HUAWEI-acl-basic-2002] quit
# Apply the ACL based on the user. For more information, see the command snmp-agent usm-user.
[HUAWEI] snmp-agent usm-user v3 John NMS acl 2002
- Configure trap functions and set the IP address of the trap server to be the IP address of the NMS, 192.167.1.10. For more information, see the command snmp-agent target-host trap.
NOTE:The trap function must be configured so that the NMS can receive the alarms from the device.
[HUAWEI] snmp-agent trap enable[HUAWEI] snmp-agent target-host trap address udp-domain 192.167.1.10 params securityname comaccess v3 private-netmanager
Commissioning Results
After the configurations of the ME60 and the NMS are complete, you can access the ME60 through the NMS.