< Home

dhcp snooping check dhcp-rate

Function

The dhcp snooping check dhcp-rate command sets the maximum rate of sending DHCP messages to the processing unit.

The undo dhcp snooping check dhcp-rate command restores the default maximum rate of sending DHCP messages to the processing unit.

By default, the maximum rate of sending global DHCP messages to the processing unit is 100 pps, which is the same as the maximum rate of sending DHCP messages on interfaces to the processing unit.

Format

In the system view:

dhcp snooping check dhcp-rate rate [ vlan { vlan-id1 [ to vlan-id2 ] } &<1-10> ]

undo dhcp snooping check dhcp-rate

In the VLAN view and interface view:

dhcp snooping check dhcp-rate rate

undo dhcp snooping check dhcp-rate

Parameters

Parameter Description Value

rate

Specifies the maximum rate of sending DHCP messages to the processing unit.

The value is an integer that ranges from 1 to 100, in pps.

vlan { vlan-id1 [ to vlan-id2 ] } &<1-10>

Specifies the maximum rate of sending DHCP messages from a specified VLAN to the processing unit.
  • vlan-id1 specifies the first VLAN ID.
  • to vlan-id2 specifies the last VLAN ID. vlan-id2 must be larger than vlan-id1.

If this parameter is not specified, the command takes effect on all the DHCP messages.

The value is an integer that ranges from 1 to 4094.

Views

System view, VLAN view, Ethernet interface view, GE interface view, XGE interface view, 25GE interface view, MultiGE interface view, 40GE interface view, 100GE interface view, Eth-Trunk interface view, port group view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

After DHCP snooping is enabled, the device sends all the received DHCP Request messages and Reply messages to the processing unit. If the rate of sending DHCP messages is high, processing efficiency of the processing unit is affected. After the device is enabled to check the rate of sending DHCP messages to the processing unit, run the dhcp snooping check dhcp-rate command to set the maximum rate of sending DHCP messages to the processing unit. DHCP messages that exceed the rate are discarded.

Prerequisites

The device has been enabled to check the rate of sending DHCP messages to the processing unit using the dhcp snooping check dhcp-rate enable command.

Precautions

If the maximum rates of sending DHCP messages to the processing unit are set in the system view, VLAN view, and interface view, the smallest value takes effect.

Example

# In the system view, set the maximum rate of sending DHCP messages to the processing unit to 50 pps.

<HUAWEI> system-view
[HUAWEI] dhcp enable
[HUAWEI] dhcp snooping enable
[HUAWEI] dhcp snooping check dhcp-rate enable
[HUAWEI] dhcp snooping check dhcp-rate 50
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >