The dhcp snooping alarm threshold command configures an alarm threshold for the number of dropped ARP packets, IP packets, DHCP reply packets (received on the untrusted interface), and DHCP request packets in a VLAN. In addition, you can configure the percentage threshold for the maximum number of DHCP snooping users.
The undo dhcp snooping alarm threshold command restores the default setting.
The dhcp snooping alarm enable command enables the alarm function for the scenario in which the number of dropped ARP packets, IP packets, DHCP reply packets (dropped on the untrusted interface), and DHCP request packets reaches the threshold or the user number reaches the threshold.
The undo dhcp snooping alarm enable command disables DHCP snooping alarm on an interface.
By default:
dhcp snooping alarm { { ip | arp | dhcp-chaddr | dhcp-request | dhcp-reply } { enable | threshold threshold } | user-limit { enable | threshold user-threshold } }
undo dhcp snooping alarm { ip | arp | dhcp-chaddr | dhcp-request | dhcp-reply | user-limit } enable
undo dhcp snooping alarm { ip | arp | dhcp-chaddr | dhcp-request | dhcp-reply | user-limit } threshold
Parameter | Description | Value |
---|---|---|
ip |
Indicates the alarm threshold for the number of dropped IP packets. |
- |
arp |
Indicates the alarm threshold for the number of dropped ARP packets. |
- |
dhcp-chaddr |
Indicates the alarm threshold for the number of dropped DHCP packets with the client hardware address (CHADDR) field value mismatching the source MAC address in the Ethernet frame header. |
- |
dhcp-request |
Indicates the alarm threshold for the number of dropped DHCP request packets. |
- |
dhcp-reply |
Indicates the alarm threshold for the number of dropped DHCP reply packets on an untrusted interface. The DHCP reply packets include DHCP Offer, ACK, and NAK packets. |
- |
threshold threshold |
Specifies an alarm threshold. |
The alarm threshold for the number of discarded packets in a VLAN ranges from 1 to 1000. The default value is 100. |
threshold user-threshold |
Specifies an alarm threshold, in percentage. |
The percentage threshold at which the maximum number of DHCP snooping users triggers an alarm ranges from 1 to 100. The default value is 100. |
user-limit |
Indicates the percentage threshold for the maximum number of DHCP snooping users. |
- |
Usage Scenario
In the VLAN view, this command is only used to configure the alarm threshold for the maximum number of dropped packets in a VLAN and the percentage threshold for the maximum number of DHCP snooping users.
The configuration of the alarm threshold for dropped packets in a VLAN can be one of the following situations:Prerequisites
Precautions
When an interface is added to a VLAN not using default, trunk, VLAN-stacking, or VLAN-mapping mode, delete the configured alarm threshold in the VLAN and interface views.
<HUAWEI> system-view [~HUAWEI] dhcp snooping enable [*HUAWEI] vlan 100 [*HUAWEI-vlan100] dhcp snooping enable [*HUAWEI-vlan100] quit [*HUAWEI] interface GigabitEthernet 0/1/6 [*HUAWEI-GigabitEthernet0/1/6] portswitch [*HUAWEI-GigabitEthernet0/1/6] port default vlan 100 [*HUAWEI-GigabitEthernet0/1/6] quit [*HUAWEI] vlan 100 [*HUAWEI-vlan100] dhcp snooping max-user-number 3000 interface GigabitEthernet 0/1/6 [*HUAWEI-vlan100] dhcp snooping alarm user-limit enable [*HUAWEI-vlan100] dhcp snooping alarm user-limit threshold 50 interface GigabitEthernet 0/1/6
<HUAWEI> system-view [~HUAWEI] dhcp snooping enable [*HUAWEI] vlan 100 [*HUAWEI-vlan100] dhcp snooping enable [*HUAWEI-vlan100] dhcp snooping alarm arp threshold 200
<HUAWEI> system-view [~HUAWEI] dhcp snooping enable [*HUAWEI] vlan 100 [*HUAWEI-vlan100] dhcp snooping enable [*HUAWEI-vlan100] dhcp snooping max-user-number 3000 [*HUAWEI-vlan100] dhcp snooping alarm user-limit enable [*HUAWEI-vlan100] dhcp snooping alarm user-limit threshold 50