< Home

snmp-agent udp-port

Function

The snmp-agent udp-port command changes the number of the port monitored by the SNMP Agent.

The undo snmp-agent udp-port command restores the configurations to default.

Format

snmp-agent udp-port port-num

undo snmp-agent udp-port

Parameters

Parameter Description Value
port-num Specifies the number of the port to be monitored by an SNMP Agent. The value is an integer that can be 161 or ranges from 1025 to 65535.

Views

System view

Default Level

3: Management level

Usage Guidelines

By default, the SNMP Agent monitors port 161.

Usage Scenario

An SNMP Agent is an agent process on a device. By default, the SNMP Agent monitors port 161 on a device and responds to the NMS request, helping the NMS to manage the device. However, security risks exist because the monitored port is fixed. For example, all attack packets may be forwarded to that port, causing network congestion.

The snmp-agent udp-port command can be used to change the number of the port monitored by the SNMP Agent, to improve the security of the device.

Configuration Impact

After the snmp-agent udp-port command is used to change the port number, the SNMP Agent monitors a new port. The original SNMP connection is closed and the NMS has to connect to the device with a new port number.

Precautions

The specified port number must be the same as the one configured using the snmp-agent udp-port command. Otherwise, the NMS cannot be connected to the device.

Example

# Configure the SNMP Agent to monitor port 1057.

<sysname> system-view
[sysname] snmp-agent udp-port 1057
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >