No part of this document may be reproduced or transmitted in any form or by any means without prior written
consent of Huawei Technologies Co., Ltd.
Trademarks and Permissions
and other Huawei trademarks are trademarks of Huawei Technologies Co., Ltd.
All other trademarks and trade names mentioned in this document are the property of their respective holders.
Notice
The purchased products, services and features are stipulated by the contract made between Huawei and the
customer. All or part of the products, services and features described in this document may not be within the
purchase scope or the usage scope. Unless otherwise specified in the contract, all statements, information,
and recommendations in this document are provided "AS IS" without warranties, guarantees or representations
of any kind, either express or implied.
The information in this document is subject to change without notice. Every effort has been made in the
preparation of this document to ensure accuracy of the contents, but all statements, information, and
recommendations in this document do not constitute the warranty of any kind, express or implied.
Huawei Technologies Co., Ltd.
Address:Huawei Industrial Base
Bantian, Longgang
Shenzhen 518129
People's Republic of China
Website:http://www.huawei.com
Email:support@huawei.com
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
Quidway S2700 Series Ethernet Switches
Configuration Guide - Network ManagementAbout This Document
About This Document
Intended Audience
This document provides the basic concepts, configuration procedures, and configuration
examples in different application scenarios of the Network Management feature supported by
the S2700.
This document describes how to configure the Network Management feature.
This document is intended for:
lData configuration engineers
lCommissioning engineers
lNetwork monitoring engineers
lSystem maintenance engineers
Symbol Conventions
The symbols that may be found in this document are defined as follows.
Symbol
Description
Indicates a hazard with a high level of risk, which if not
avoided, will result in death or serious injury.
Indicates a hazard with a medium or low level of risk, which
if not avoided, could result in minor or moderate injury.
Indicates a potentially hazardous situation, which if not
avoided, could result in equipment damage, data loss,
performance degradation, or unexpected results.
Indicates a tip that may help you solve a problem or save
time.
Provides additional information to emphasize or supplement
important points of the main text.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
1.1 Introduction to SNMP........................................................................................................................................2
1.2.3 (Optional) Controlling the NM Station's Access to the Device...............................................................11
1.2.4 (Optional) Enabling the SNMP Extended Error Code Function.............................................................12
1.2.5 (Optional) Configuring the Trap Function..............................................................................................13
1.2.6 (Optional) Configuring the Constant Interface Index Feature.................................................................14
1.2.7 Checking the Configuration.....................................................................................................................15
1.3 Configuring a Device to Communicate with an NM Station by Running SNMPv2c......................................15
1.3.1 Establishing the Configuration Task.......................................................................................................16
1.3.3 (Optional) Controlling the NM Station's Access to the Device...............................................................19
1.3.4 (Optional) Enabling the SNMP Extended Error Code Function.............................................................21
1.3.5 (Optional) Configuring the Trap Function..............................................................................................21
1.3.6 (Optional) Configuring the Constant Interface Index Feature.................................................................24
1.3.7 Checking the Configuration.....................................................................................................................25
1.4 Configuring a Device to Communicate with an NM Station by Running SNMPv3........................................25
1.4.1 Establishing the Configuration Task.......................................................................................................26
1.4.3 (Optional) Controlling the NM Station's Access to the Device...............................................................29
1.4.4 (Optional) Enabling the SNMP Extended Error Code Function.............................................................31
1.4.5 (Optional) Configuring the Trap Function..............................................................................................32
1.4.6 (Optional) Configuring the Constant Interface Index Feature.................................................................33
1.4.7 Checking the Configuration.....................................................................................................................34
2.1 Introduction to LLDP.......................................................................................................................................47
2.2 LLDP Feature Supported by the S2700............................................................................................................50
2.3.1 Establishing the Configuration Task.......................................................................................................53
2.3.2 Enabling Global LLDP............................................................................................................................54
2.3.3 (Optional) Disabling LLDP on an Interface............................................................................................54
2.3.4 (Optional) Configuring an LLDP Management Address........................................................................55
2.3.5 (Optional) Configuring the TLV in the LLDPDU...................................................................................56
2.3.7 (Optional) Enabling the LLDP Trap Function........................................................................................60
2.3.8 Checking the Configuration.....................................................................................................................61
3.1 Introduction to HGMP......................................................................................................................................80
3.2 HGMP Features Supported by the S2700.........................................................................................................82
3.3.4 Creating a Cluster....................................................................................................................................89
3.3.5 Adding a Member Switch........................................................................................................................92
3.3.6 (Optional) Deleting or Quitting a Cluster................................................................................................93
3.3.7 (Optional) Deleting a Member Switch....................................................................................................94
3.3.8 Checking the Configuration.....................................................................................................................95
3.5.1 Clearing the NDP Statistics...................................................................................................................108
3.5.2 Monitoring the Operation Status of the HGMP Cluster........................................................................108
Quidway S2700 Series Ethernet Switches
Configuration Guide - Network ManagementContents
3.6.2 Example for Configuring the Interconnection of FTP Servers and Devices in and out of the HGMP Cluster
(in NAT Mode)...............................................................................................................................................119
3.6.3 Example for Configuring the Interconnection of FTP Servers and Devices in and out of the HGMP Cluster
(in Non-NAT Mode).......................................................................................................................................129
3.6.4 Example for Configuring Devices in the HGMP Cluster to Access the Outside SNMP Host (in NAT
4.1 Introduction to NTP........................................................................................................................................210
4.2 NTP Supported by the S2700.........................................................................................................................212
5.3 Performing Ping and Tracert Operations........................................................................................................247
5.3.1 Establishing the Configuration Task.....................................................................................................248
5.3.2 Checking Network Connectivity Through the Ping Operation.............................................................248
5.3.3 Locating Faults on the Network Through the Tracert Operation..........................................................249
5.4 Debugging Ping and Tracert...........................................................................................................................250
6.1 Introduction to NQA.......................................................................................................................................255
6.2 Comparisons Between NQA and Ping...........................................................................................................255
6.3 NQA Server and NQA Clients.......................................................................................................................256
6.4 NQA Supported by the S2700........................................................................................................................257
6.5 Configuring the ICMP Test............................................................................................................................258
6.5.1 Establishing the Configuration Task.....................................................................................................258
6.5.2 Configuring ICMP Test Parameters......................................................................................................259
6.5.3 Checking the Configuration...................................................................................................................260
6.6 Configuring the FTP Download Test.............................................................................................................261
6.6.1 Establishing the Configuration Task.....................................................................................................261
6.6.2 Configuring the FTP Download Test Parameters..................................................................................262
6.6.3 Checking the Configuration...................................................................................................................263
6.7 Configuring the FTP Upload Test..................................................................................................................264
6.7.1 Establishing the Configuration Task.....................................................................................................264
6.7.2 Configuring the FTP Upload Test Parameters......................................................................................265
6.7.3 Checking the Configuration...................................................................................................................267
6.8 Configuring the HTTP Test............................................................................................................................268
6.8.1 Establishing the Configuration Task.....................................................................................................268
6.8.2 Configuring HTTP Test Parameters......................................................................................................269
6.8.3 Checking the Configuration...................................................................................................................270
6.9 Configuring the DNS Test..............................................................................................................................271
6.9.1 Establishing the Configuration Task.....................................................................................................271
6.9.2 Configuring the DNS Test Parameters..................................................................................................271
6.9.3 Checking the Configuration...................................................................................................................273
6.10 Configuring the Traceroute Test...................................................................................................................273
6.10.1 Establishing the Configuration Task...................................................................................................273
6.10.2 Configuring Parameters for a Traceroute Test....................................................................................274
6.10.3 Checking the Configuration.................................................................................................................275
6.11 Configuring the SNMP Query Test..............................................................................................................276
6.11.1 Establishing the Configuration Task...................................................................................................276
6.11.2 Configuring the SNMP Query Test Parameters..................................................................................277
6.11.3 Checking the Configuration.................................................................................................................278
6.12 Configuring the TCP Test.............................................................................................................................279
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
Quidway S2700 Series Ethernet Switches
Configuration Guide - Network ManagementContents
6.12.1 Establishing the Configuration Task...................................................................................................279
6.12.2 Configuring the TCP Server................................................................................................................279
6.12.3 Configuring the TCP Client.................................................................................................................280
6.12.4 Checking the Configuration.................................................................................................................281
6.13 Configuring the UDP Test............................................................................................................................282
6.13.1 Establishing the Configuration Task...................................................................................................282
6.13.2 Configuring the UDP Server...............................................................................................................283
6.13.3 Configuring the UDP Client................................................................................................................283
6.13.4 Checking the Configuration.................................................................................................................285
6.14 Configuring the Jitter Test............................................................................................................................285
6.14.1 Establishing the Configuration Task...................................................................................................286
6.14.2 Configuring the Jitter Server...............................................................................................................287
6.14.3 Configuring the Jitter Client................................................................................................................287
6.14.4 Checking the Configuration.................................................................................................................289
6.15 Configuring Universal NQA Test Parameters..............................................................................................290
6.15.1 Establishing the Configuration Task...................................................................................................290
6.15.2 Configuring Universal Parameters for the NQA Test Instance...........................................................290
6.15.3 Checking the Configuration.................................................................................................................294
6.16.3 Checking the Configuration.................................................................................................................297
6.17 Configuring the Trap Function.....................................................................................................................297
6.17.1 Establishing the Configuration Task...................................................................................................297
6.17.2 Sending Trap Messages When Test Failed..........................................................................................298
6.17.3 Sending Trap Messages When Probes Failed......................................................................................299
6.17.4 Sending Trap Messages When Probes Are Complete.........................................................................300
6.17.5 Sending Trap Messages When the Transmission Delay Exceeds Thresholds....................................301
6.17.6 Checking the Configuration.................................................................................................................301
7.1 Introduction to RMON...................................................................................................................................331
7.2 RMON Suported by the S2700.......................................................................................................................331
The Simple Network Management Protocol (SNMP) is a standard network management protocol
widely used on TCP/IP networks. It uses a central computer (a network management station)
that runs network management software to manage network elements. There are three SNMP
versions, SNMPv1, SNMPv2c, and SNMPv3. Users can choose to configure one or more
versions if needed.
1.1 Introduction to SNMP
SNMP provides a set of standard protocols for the communication between the network
management station (NM station) and devices, allowing the NM station to normally manage
devices and receive alarms reported by the devices.
1.2 Configuring a Device to Communicate with an NM Station by Running SNMPv1
After SNMPv1 is configured, a managed device and an NM station can run SNMPv1 to
communicate with each other. To ensure normal communication, you need to configure both
sides. This section describes only the configurations on a managed device (the agent side). For
details about configurations on an NM station, see the pertaining NM station operation guide.
1.3 Configuring a Device to Communicate with an NM Station by Running SNMPv2c
After SNMPv2c is configured, a managed device and an NM station can run SNMPv2c to
communicate with each other. To ensure normal communication, you need to configure both
sides. This section describes only the configurations on a managed device (the agent side). For
details about configurations on an NM station, see the pertaining NM station operation guide.
1.4 Configuring a Device to Communicate with an NM Station by Running SNMPv3
After SNMPv3 is configured, a managed device and an NM station can run SNMPv3 to
communicate with each other. To ensure normal communication, you need to configure both
sides. This section describes only the configurations on a managed device (the agent side). For
details about configurations on an NM station, see the pertaining NM station operation guide.
1.5 SNMP Configuration Examples
This section provides several configuration examples of SNMP. The configuration roadmap in
the examples will help you understand the configuration procedures. Each configuration
example provides information about the networking requirements, configuration notes, and
configuration roadmap.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
SNMP provides a set of standard protocols for the communication between the network
management station (NM station) and devices, allowing the NM station to normally manage
devices and receive alarms reported by the devices.
1.1.1 SNMP Overview
Get and Set operations can be performed on a managed device that runs the SNMP agent to
manage device objects by NM stations These objects are uniquely identified in the Management
Information Base (MIB).
As network services develop, more and more devices are deployed on existing networks. It is
some distance from the devices to the central equipment room where a network administrator
works. Once faults occur on the remote devices, it is impossible for the network administrator
to detect, locate and rectify faults immediately because the faults will not be reported by the
devices. This affects maintenance efficiency and greatly increases maintenance workload.
To solve this problem, equipment vendors have provided network management functions in
some products. The NM station then can query the status of remote devices, and devices can
send alarms to the NM station in the case of particular events.
SNMP operates at the application layer of the IP suite and defines how to transmit management
information between the NM station and devices. SNMP defines several device management
operations that can be performed by the NM station and allows devices to notify the NM station
of device faults by sending alarms.
An SNMP-managed network consists of three components: NM station, agent, and managed
device. The NM station uses the MIB to identify and manage device objects. The operations
used for device management include GetRequest, GetNextRequest, GetResponse, GetBulk,
SetRequest, and notification from the agent to the NM station. The following sections give details
on the components, MIB, and operations.
SNMP Components
Three components are used in SNMP device management:
lNM station: sends various query packets to query managed devices and receives alarms
from these devices.
lAgent: is a network-management process on a managed device. An agent has the following
functions:
– Receives and parses query packets sent from the NM station.
– Reads or writes management variables based on the query type, and generates and sends
– Sends an alarm to the NM station when triggering conditions defined on each protocol
response packets to the NM station.
module corresponding to the alarm are met. For example, the system view is displayed
or closed, or the device is restarted.
lManaged device: is managed by an NM station and generates and reports alarms to the NM
station.
Figure 1-1 shows the relationship between the NM station and agent.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
SNMP uses a hierarchical naming convention to identify managed objects and to distinguish
between managed objects. This hierarchical structure is similar to a tree with the nodes
representing managed objects, Figure 1-2 shows a managed object that can be identified by the
path from the root to the node representing it.
Figure 1-2 Structure of a MIB tree
As shown in Figure 1-2, object B is uniquely identified by a string of numbers, {1.2.1.1}. Such
a number string is called an Object Identifier (OID). A MIB tree is used to describe the hierarchy
of data in a MIB that collects the definitions of variables on the managed devices.
A user can use a standard MIB or define a MIB based on certain standards. Using a standard
MIB can reduce the costs on proxy deployment and therefore reduce the costs on the entire
network management system.
SNMP Operations
SNMP uses Get and Set operations to replace a complex command set. The operations described
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
GetRequestRetrieves the value of a variable. The NM station sends the
request to a managed device to obtain the value of an object
on the device.
GetNextRequestRetrieves the value of the next variable. The NM station
sends the request to a managed device to obtain the status
of the next object on the device.
GetResponseResponds to GetRequest, GetNextRequest, and
SetRequest operations. It is sent from the managed device
to the NM station.
GetBulkIs an NMS-to-agent request, equaling continuous GetNext
operations.
SetRequestSets the value of a variable. The NM station sends the
request to a managed device to adjust the status of an object
on the device.
TrapReports an event to the NM station.
1.1.2 SNMP Features Supported by the S2700
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
This section compares SNMP versions in terms of their support for features and usage scenarios
to provide a reference for your SNMP version selection during network deployment.
The S2700 supports SNMPv1, SNMPv2c, and SNMPv3. Table 1-2 lists the features supported
by SNMP, and Table 1-3 shows the support of different SNMP versions for the features. Table
1-4 describes the usage scenarios of SNMP versions, which will help you choose a proper version
for the communication between an NM station and managed devices based on the network
operation conditions.
When multiple NM stations using different SNMP versions manage the same device in a network,
SNMPv1, SNMPv2c, and SNMPv3 can all be configured on the device for its communication with all the
NM stations.
Table 1-2 Description of features supported by SNMP
FeatureDescription
Access controlThis function is used to restrict a user's device
administration rights. It gives specific users
the rights to manage specified objects on
devices and therefore provides fine
management.
Authentication and encryptionPackets transmitted between the NM station
and managed devices are authenticated and
encrypted. This prevents data packets from
being intercepted or modified, improving
data sending security.
Error codeError codes are used to identify particular
faults. They help an administrator quickly
locate and rectify faults. The larger the variety
of error codes, the more greatly they help an
administrator in device management.
TrapTraps are sent from managed devices to the
NM station. These traps allow an
administrator to discover device faults
immediately.
The managed devices do not require the
acknowledgement from the NM station after
sending traps.
Inform
Informs are sent from managed devices to the
NM station.
The managed devices require the
acknowledgement from the NM station after
sending informs. If a managed device does
not receive an acknowledgement after
sending an inform, it will resend the inform
to the NM station and generate alarm logs.
Even if the NM station restarts, it can still
synchronize the informs sent during the
restart process.
If the device does not receive an
acknowledgement from the NM station after
sending an inform, it will store the inform in
its memory. In this regard, using informs may
consume lots of system resources.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
Get-next operation in batches. In a large-scale
network, GetBulk reduces the administrator's
workload and improves management
efficiency.
Table 1-3 Different SNMP versions' support for the features
FeatureSNMPv1SNMPv2cSNMPv3
Access controlCommunity-name-
based access control
supported
Authentication and
Not supportedNot supportedSupported, and the
encryption
Community-namebased access control
supported
User or user-groupbased access control
supported
supported
authentication and
encryption modes are
as follows:
Authentication
mode:
l MD5
l SHA
Encryption mode:
DES56
Error code
6 error codes
supported
16 error codes
supported
16 error codes
supported
TrapSupportedSupportedSupported
InformNot supportedSupportedNot supported
GetBulkNot supportedSupportedSupported
Table 1-4 Usage scenarios of different SNMP versions
Version
Usage Scenario
SNMPv1This version is applicable to small-scale
networks whose networking is simple and
security requirements are low or whose
security and stability are good, such as
campus networks and small enterprise
networks.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
large-scale networks whose security
requirements are not strict or whose security
is good (for example, VPNs) but whose
services are so busy that traffic congestion
may occur.
Using informs can ensure that the messages
sent from managed devices are received by
the NM station.
SNMPv3
If you plan to build a new network, choose an SNMP version based on your usage scenario. If
you plan to expand or upgrade an existing network, choose an SNMP version to match the SNMP
version running on the NM station to ensure the normal communication between managed
devices and the NM station.
This version is applicable to networks of
various scales, especially the networks that
have strict requirements on security and can
be managed only by authorized
administrators, such as the scenario where
data between the NM station and managed
devices needs to be transmitted over a public
network.
1.2 Configuring a Device to Communicate with an NM
Station by Running SNMPv1
After SNMPv1 is configured, a managed device and an NM station can run SNMPv1 to
communicate with each other. To ensure normal communication, you need to configure both
sides. This section describes only the configurations on a managed device (the agent side). For
details about configurations on an NM station, see the pertaining NM station operation guide.
The NM station manages a device in the following manners:
lSends requests to the managed device to perform the GetRequest, GetNextRequest,
GetResponse, GetBulk, or SetRequest operation, obtaining data and setting values.
lReceives alarms from the managed device and locates and rectify device faults based on
the alarm information.
In the following configuration, after basic SNMP functions are configured, the NM station can
manage the device in these manners. For details on how to configure finer management such as
accurate access control or alarm module specification, see the following configuration
procedures.
1.2.1 Establishing the Configuration Task
Before configuring a device to communicate with an NM station by running SNMPv1,
familiarize yourself with the applicable environment, complete the pre-configuration tasks, and
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
obtain the data required for the configuration. This will help you complete the configuration task
quickly and accurately.
Applicable Environment
SNMP needs to be deployed in a network to allow the NM station to manage network devices.
If the network has a few devices and its security is good, such as a campus network or a small
enterprise network, SNMPv1 can be deployed to ensure the normal communication between the
NM station and managed devices.
Pre-configuration Tasks
Before configuring a device to communicate with an NM station by running SNMPv1, complete
the following task:
lConfiguring a routing protocol to ensure that the switch and NM station are routable
Data Preparation
Before configuring a device to communicate with an NM station by running SNMPv1, you need
the following data.
No.
1SNMP version, SNMP community name, destination address of alarm messages,
2(Optional) ACL number, IP address of the NM station, and MIB object
3(Optional) Name of the alarm-sending module, source address of trap messages,
4(Optional) Number of interfaces indexed by fixed numbers
Data
administrator's contact information and location, and SNMP packet size
queue length for trap messages, and lifetime of trap messages
1.2.2 Configuring Basic SNMPv1 Functions
After basic SNMP functions are configured, an NM station can perform basic operations such
as Get and Set operations on a managed device, and the managed device can send alarms to the
NM station.
Context
Steps 3, 4, and 5 are mandatory for the configuration of basic SNMP functions. After the
configurations are complete, basic SNMP communication can be conducted between the NM
station and managed device.
Procedure
Step 1 Run:
system-view
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
By default, the SNMP agent function is disabled. Running any command with the parameter
snmp-agent can enable the SNMP agent function, so this step is optional.
Step 3 Run:
snmp-agent sys-info version v1
The SNMP version is set.
By default, SNMPv3 is enabled.
After SNMPv1 is enabled on the managed device, the device supports both SNMPv1 and
SNMPv3. This means that the device can be monitored and managed by NM stations running
SNMPv1 or SNMPv3.
Step 4 Run:
snmp-agent community { read | write } community-name
The community name is set.
After the community name is set, if no MIB view is configured, the NM station that uses the
community name has rights to access objects in the Viewdefault view (1.3.6.1).
l read needs to be configured in the command if the NM station administrator needs the read
permission in a specified view in some cases. For example, a low-level administrator needs
to read certain data.
l write needs to be configured in the command if the NM station administrator needs the read
and write permissions in a specified view in some cases. For example, a high-level
administrator needs to read and write certain data.
Step 5 Choose either of the following commands as needed to configure a destination IP address for
the alarms and error codes sent from the device.
l To configure a destination IPv4 address for the alarms and error codes sent from the device,
The descriptions of the command parameters are as follows:
l The default destination UDP port number is 162. In some special cases (for example, port
mirroring is configured to prevent a well-known port from being attacked), the parameter
udp-port can be used to specify a non-well-known UDP port number. This ensures normal
communication between the NM station and managed device.
l If the alarms sent from the managed device to the NM station need to be transmitted over a
public network, the parameter public-net needs to be configured. If the alarms sent from the
managed device to the NM station need to be transmitted over a private network, the
parameter vpn-instance vpn-instance-name needs to be used to specify a VPN that will take
over the sending task.
l The parameter securityname identifies the alarm sender, which will help you learn the alarm
source.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
The equipment administrator's contact information or location is configured.
This step is needed if the NM station administrator needs to know equipment administrators'
contact information and locations when the NM station manages many devices. This will allow
the NM station administrator to quickly contact the equipment administrators for fault location
and rectification.
To configure both the equipment administrator's contact information and location, you need to
run the command twice to configure them separately.
Step 7 (Optional) Run:
snmp-agent packet max-size byte-count
The maximum size of an SNMP packet that the device can receive or send is set.
By default, the maximum size of an SNMP packet that the device can receive or send is 12000
bytes.
After the maximum size is set, the device will discard any SNMP packet that is larger than the
set size. The allowable maximum size of an SNMP packet for a device depends on the size of a
packet that the NM station can process; otherwise, the NM station cannot process the SNMP
packets sent from the device.
----End
Follow-up Procedure
After the configurations are complete, basic communication can be conducted between the NM
station and managed device.
lAccess control allows any NM station that uses the community name to monitor and manage
all the objects on the managed device.
lThe managed device sends alarms generated by the modules that are enabled by default to
the NM station.
If finer device management is required, follow directions below to configure a managed device:
lTo allow a specified NM station that uses the community name to manage specified objects
on the device, follow the procedure described in Controlling the NM Station's Access to
the Device.
lTo allow a specified module on the managed device to report alarms to the NM station,
follow the procedure described in Configuring the Trap Function.
lIf the NM station and managed device are both Huawei products, follow the procedure
described in Enabling the SNMP Extended Error Code Function to allow the device to
send more types of error codes. This allows more specific error identification and facilitates
your fault location and rectification.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
lIf the functions such as accounting and fault location need to be bound to specified
interfaces to prevent changes in interface indexes during device or interface restart, follow
the procedure described in Configuring the Constant Interface Index Feature.
1.2.3 (Optional) Controlling the NM Station's Access to the Device
This section describes how to specify an NM station and manageable MIB objects for SNMPbased communication between the NM station and managed device to improve communication
security.
Context
If a device is managed by multiple NM stations that use the same community name, note the
following points:
lIf all the NM stations that use the community name need to have rights to access the objects
in the Viewdefault view (1.3.6.1), skip the following steps.
lIf some of the NM stations that use the community name need to have rights to access the
objects in the Viewdefault view (1.3.6.1), skip Step 5.
lIf all the NM stations need to manage specified objects on the device, skip Steps 2, 3, and
4.
lIf some of the NM stations that use the community name need to manage specified objects
on the device, perform all the following steps.
Procedure
Step 1 Run:
Step 2 Run:
Step 3 Run:
Step 4 Run:
Step 5 Run:
system-view
The system view is displayed.
acl acl-number
A basic ACL is created to filter the NM station users that can manage the device.
l read needs to be configured in the command if the NM station administrator needs the read
permission in the specified view in some cases. For example, a low-level administrator needs
to read certain data. write needs to be configured in the command if the NM station
administrator needs the read and write permissions in the specified view in some cases. For
example, a high-level administrator needs to read and write certain data.
l cipher is used to display the community name in cipher text. It can be configured in the
command to improve security. If the parameter is configured, the administrator needs to
remember the community name. If the community name is forgotten, it cannot be obtained
by querying the device.
l If some of the NM stations that use the community name need to have rights to access the
objects in the Viewdefault view (1.3.6.1), mib-view view-name does not need to be
configured in the command.
l If all the NM stations that use the community name need to manage specified objects on the
device, acl acl-number does not need to be configured in the command.
l If some of the NM stations that use the community name need to manage specified objects
on the device, both mib-view and acl need to be configured in the command.
----End
Follow-up Procedure
After the access rights are configured, especially after the IP address of the NM station is
specified, if the IP address changes (for example, the NM station changes its location, or IP
addresses are reallocated due to network adjustment), you need to change the IP address of the
NM station in the ACL. Otherwise, the NM station cannot access the device.
1.2.4 (Optional) Enabling the SNMP Extended Error Code Function
This section describes how to enable the extended SNMP error code function when both the NM
station and managed device are Huawei products. After this function is enabled, more types of
error codes are provided to help you locate and rectify faults more quickly and accurately.
Procedure
Step 1 Run:
system-view
The system view is displayed.
Step 2 Run:
snmp-agent extend error-code enable
The SNMP extended error code function is enabled.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
By default, SNMP standard error codes are used. After the extended error code function is
enabled, extended error codes can be sent to the NM station.
----End
1.2.5 (Optional) Configuring the Trap Function
This section describes how to specify the alarms to be sent to the NM station, which will help
you to locate important problems. After relevant parameters are set, the security of alarm sending
can be improved.
The source interface for trap messages is specified.
NOTE
If the snmp-agent trap enable command is run to enable the trap functions of all modules, or the snmpagent trap enable feature-name command is run to enable three or more trap functions of a module, note
the following points:
l To disable the trap functions of all modules, you need to run the snmp-agent trap disable command.
l To restore the trap functions of all modules to the default status, you need to run the undo snmp-agent
trap enable or undo snmp-agent trap disable command.
l To disable one trap function of a module, you need to run the undo snmp-agent trap enable feature-
name command.
After the source interface is specified, its IP address becomes the source IP address of trap
messages. Configuring the IP address of the local loopback interface as the source interface is
recommended, which can ensure device security.
The source interface specified on the switch for trap messages must be consistent with that
specified on the NM station; otherwise, the NM station will not accept the trap messages sent
from the switch.
Step 5 Run:
snmp-agent trap queue-size size
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
The length of the queue storing trap messages to be sent to the destination host is set.
The queue length depends on the number of generated trap messages. If the switch frequently
generates trap messages, a longer queue length can be set to prevent trap messages from being
lost.
Step 6 Run:
snmp-agent trap life seconds
The lifetime of every trap message is set.
The lifetime of every trap message depends on the number of generated trap messages. If the
switch frequently generates trap messages, a longer lifetime can be set for every trap message
to prevent trap messages from being lost.
----End
1.2.6 (Optional) Configuring the Constant Interface Index Feature
This section describes how to configure the constant interface index feature. This feature allows
some interface indexes remain unchanged in the case of interface deletion or addition, system
restart, or hardware or software configuration change to meet the need of some functions such
as accounting and fault diagnosis that require fixed interfaces.
Procedure
Step 1 Run:
Step 2 Run:
Step 3 Run:
system-view
The system view is displayed.
ifindex constant
The constant interface index feature is enabled.
After the feature is enabled, the indexes for all the existing interfaces and newly created interfaces
are fixed. If the system needs to restart, the save command must be run to save interface
configurations; otherwise, the interface indexes will change after the system is restarted.
set constant-ifindex max-number number
The maximum number of interfaces indexed by fixed numbers is set.
If interfaces are frequently added or deleted during system operation, the interface index file
stored in the device may have a great size and consume too many system resources. Setting the
maximum number of interfaces indexed by fixed numbers can prevent the interface index file
from exceeding an expected size.
After the maximum number of interfaces indexed by fixed numbers is set, the system will allocate
fixed indexes to interfaces within the specified value range. If the specified value is smaller than
the number of interfaces configured on the device, the system allocates fixed interface indexes
to the interfaces enabled earlier. The interfaces enabled later are not indexed by fixed numbers.
By default, a maximum of 131070 interfaces can be indexed by fixed numbers. If the value is
set to 0, no interfaces will be indexed by fixed numbers.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
set constant-ifindex subinterface { dense-mode | sparse-mode }
The memory distribution mode for the sub-interface index is set.
When a sub-interface is created, the system generates an index image file for the sub-interface
in the memory in a specified mode. You may use various sub-interface numbering modes, such
as the continuous mode or the discontinuous mode. In real-world situations, one of the following
distribution modes can be used as needed:
l Sparse mode: applies to discontinuous sub-interface numbering.
l Dense mode: applies to continuous sub-interface numbering.
----End
1.2.7 Checking the Configuration
After SNMPv1 functions are configured, you can view the SNMPv1 configurations.
Prerequisite
Procedure
The configurations of basic SNMPv1 functions are complete.
lRun the display snmp-agent community command to check the configured community
name.
lRun the display snmp-agent sys-info version command to check the enabled SNMP
version.
lRun the display acl acl-number command to check the rules in the specified ACL.
lRun the display snmp-agent mib-view command to check the MIB view.
lRun the display snmp-agent sys-info contact command to check the equipment
administrator's contact information.
lRun the display snmp-agent sys-info location command to check the location of the
device.
lRun the display snmp-agent extend error-code status command to check whether the
SNMP extended error code feature is enabled.
lRun the display constant-ifindex configuration command to check the constant interface
index function and relevant configuration information.
----End
1.3 Configuring a Device to Communicate with an NM
Station by Running SNMPv2c
After SNMPv2c is configured, a managed device and an NM station can run SNMPv2c to
communicate with each other. To ensure normal communication, you need to configure both
sides. This section describes only the configurations on a managed device (the agent side). For
details about configurations on an NM station, see the pertaining NM station operation guide.
The NM station manages a device in the following manners:
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
lSends requests to the managed device to perform the GetRequest, GetNextRequest,
GetResponse, GetBulk, or SetRequest operation, obtaining data and setting values.
lReceives alarms from the managed device and locates and rectify device faults based on
the alarm information.
In the following configuration, after basic SNMP functions are configured, the NM station can
manage the device in these manners. For details on how to configure finer management such as
accurate access control or alarm module specification, see the following configuration
procedures.
1.3.1 Establishing the Configuration Task
Before configuring a device to communicate with an NM station by running SNMPv2c,
familiarize yourself with the applicable environment, complete the pre-configuration tasks, and
obtain the data required for the configuration. This will help you complete the configuration task
quickly and accurately.
Applicable Environment
SNMP needs to be deployed in a network to allow the NM station to manage network devices.
If your network is a large scale with many devices and its security requirements are not strict or
its security is good (for example, a VPN network) but services on the network are so busy that
traffic congestion may occur, SNMPv2c can be deployed to ensure communication between the
NM station and managed devices.
Pre-configuration Tasks
Before configuring a device to communicate with an NM station by running SNMPv2c, complete
the following task:
lConfiguring a routing protocol to ensure that the switch and NM station are routable
Data Preparation
Before configuring a device to communicate with an NM station by running SNMPv2c, you
need the following data.
No.
1SNMP version, SNMP community name, address of the alarm destination host,
2(Optional) ACL number, IP address of the NM station, MIB object
Data
administrator's contact information and location, and SNMP packet size
3(Optional) Name of the alarm-sending module, source address of trap messages,
queue length for trap messages, lifetime of trap messages, expiry time of informs,
allowable number of inform retransmissions, allowable maximum number of informs
to be acknowledged, aging time of log messages, and allowable maximum number
of log messages about the trap and inform events in the log buffer
4(Optional) Number of interfaces indexed by fixed numbers
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
After basic SNMP functions are configured, an NM station can perform basic operations such
as Get and Set operations on a managed device, and the managed device can send alarms to the
NM station.
Context
Steps 3, 4, and 5 are mandatory for the configuration of basic SNMP functions. After the
configurations, basic SNMP communication can be conducted between the NM station and
managed device.
Procedure
Step 1 Run:
system-view
The system view is displayed.
Step 2 (Optional) Run:
snmp-agent
The SNMP agent function is enabled.
By default, the SNMP agent function is disabled. Running any command with the parameter
snmp-agent can enable the SNMP agent function, so this step is optional.
Step 3 Run:
snmp-agent sys-info version v2c
The SNMP version is set.
By default, SNMPv3 is enabled.
After SNMPv2c is enabled on the managed device, the device supports both SNMPv2c and
SNMPv3. This means that the device can be monitored and managed by NM stations running
SNMPv2c and SNMPv3.
Step 4 Run:
snmp-agent community { read | write } community-name
The community name is set.
After the community name is set, if no MIB view is configured, the NM station that uses the
community name has rights to access objects in the Viewdefault view (1.3.6.1).
l read needs to be configured in the command if the NM station administrator needs the read
l write needs to be configured in the command if the NM station administrator needs the read
permission in a specified view in some cases. For example, a low-level administrator needs
to read certain data.
and write permissions in a specified view in some cases. For example, a high-level
administrator needs to read and write certain data.
Step 5 Choose one of the following commands as needed to configure the destination IP address for
the alarms and error codes sent from the device.
l If the network is an IPv4 network, configure the device to send either traps or informs to the
NM station.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
The differences between traps and informs are as follows:
l The traps sent by the managed device do not need to be acknowledged by the NM station.
l The informs sent by the managed device need to be acknowledged by the NM station. If no
acknowledgement message from the NM station is received within a specified time period, the
managed device will resend the inform until the number of retransmissions reaches the maximum.
When the managed device sends an inform, it records the inform in the log. If the NM station and
link between the NM station and managed device recovers from a fault, the NM station can still
learn the inform sent during the fault occurrence and rectification.
In this regard, informs are more reliable than traps, but the device may need to buffer a lot of informs
because of the inform retransmission mechanism and this may consume many memory resources.
If the network is stable, using traps is recommended. If the network is unstable and the device's memory
capacity is sufficient, using informs is recommended.
– To configure a destination IP address for the traps and error codes sent from the device,
The descriptions of the command parameters are as follows:
l The default destination UDP port number is 162. In some special cases (for example, port
mirroring is configured to prevent a well-known port from being attacked), the parameter
udp-port can be used to specify a non-well-known UDP port number. This ensures normal
communication between the NM station and managed device.
l If the alarms sent from the managed device to the NM station need to be transmitted over a
public network, the parameter public-net needs to be configured. If the alarms sent from the
managed device to the NM station need to be transmitted over a private network, the
parameter vpn-instance vpn-instance-name needs to be used to specify a VPN that will take
over the sending task.
l The parameter securityname identifies the alarm sender, which will help you learn the alarm
source.
l If the NM station and managed device are both Huawei products, the parameter private-
netmanager can be configured to add more information to alarms, such as the alarm type,
alarm sequence number, and alarm sending time. The information will help you locate and
rectify faults more quickly.
The equipment administrator's contact information or location is configured.
This step is needed if the NM station administrator needs to know equipment administrators'
contact information and locations when the NM station manages many devices. This will allow
the NM station administrator to quickly contact the equipment administrators for fault location
and rectification.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
To configure both the equipment administrator's contact information and location, you need to
run the command twice to configure them separately.
Step 7 (Optional) Run:
snmp-agent packet max-size byte-count
The maximum size of an SNMP packet that the device can receive or send is set.
By default, the maximum size of an SNMP packet that the device can receive or send is 12000
bytes.
After the maximum size is set, the device will discard any SNMP packet that is larger than the
set size. The allowable maximum size of an SNMP packet for a device depends on the size of a
packet that the NM station can process; otherwise, the NM station cannot process the SNMP
packets sent from the device.
----End
Follow-up Procedure
After the configurations are complete, basic communication can be conducted between the NM
station and managed device.
lAccess control allows any NM station that uses the community name to monitor and manage
all the objects on the managed device.
lThe managed device sends alarms generated by the modules that are open by default to the
NM station.
If finer device management is required, follow directions below to configure the managed
device:
lTo allow a specified NM station that uses the community name to manage specified objects
of the device, follow the procedure described in Controlling the NM Station's Access to
the Device.
lTo allow a specified module on the managed device to report alarms to the NM station,
follow the procedure described in Configuring the Trap FunctionConfiguring the Trap
Function.
lIf the NM station and managed device are both Huawei products, follow the procedure
described in Enabling the SNMP Extended Error Code Function to allow the device to
send more types of error codes. This allows more specific error identification and facilitates
your fault location and rectification.
lIf the functions such as accounting and fault location need to be bound to specified
interfaces to prevent changes in interface indexes during device or interface restart, follow
the procedure described in Configuring the Constant Interface Index Feature.
1.3.3 (Optional) Controlling the NM Station's Access to the Device
This section describes how to specify an NM station and manageable MIB objects for SNMPbased communication between the NM station and managed device to improve communication
security.
Context
If a device is managed by multiple NM stations that use the same community name, note the
following points:
Issue 01 (2011-07-15)Huawei Proprietary and Confidential
need to be managed by the NM station, excluded needs to be specified in the related command
to exclude these MIB objects.
managed by the NM station, included needs to be specified in the related command to include
these MIB objects.
*
The NM station's access rights are specified.
l read needs to be configured in the command if the NM station administrator needs the read
permission in the specified view in some cases. For example, a low-level administrator needs
to read certain data. write needs to be configured in the command if the NM station
administrator needs the read and write permissions in the specified view in some cases. For
example, a high-level administrator needs to read and write certain data.
Issue 01 (2011-07-15)Huawei Proprietary and Confidential