dhcp snooping max-user-number (VLAN view)

Function

The dhcp snooping max-user-number command configures the maximum number of DHCP snooping users in a specified VLAN or on an interface in a VLAN.

The undo dhcp snooping max-user-number command cancels the configuration.

By default, a maximum of 4096 DHCP clients are permitted to access in a VLAN or on an interface in a VLAN.

Format

dhcp snooping max-user-number max-user-number [ interface { interface-type interface-number | interface-name } ]

undo dhcp snooping max-user-number [ interface { interface-type interface-number | interface-name } ]

Parameters

Parameter Description Value
max-user-number

Indicates the maximum number of users.

The value is a decimal integer ranging from 1 to 4096.

interface interface-type interface-number

Specifies the type and number of an interface. The supported interface types are Ethernet, GE, and Eth-Trunk.

-

Views

VLAN view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
dhcp write

Usage Guidelines

Usage Scenario

When entries in the DHCP snooping binding table that is dynamically generated reach the maximum limit, no user can obtain an IP address.

To prevent malicious IP address application, you can configure the maximum number of users either in a VLAN or on the specified interface of a VLAN.

The user can change the maximum number of DHCP snooping users. Only the current setting takes effect.

Prerequisites

Before running this command, run the dhcp snooping enable command in the system view to enable DHCP snooping globally.

Example

# Set the maximum number of users on GE 0/1/0 in VLAN 100 to 200.
<HUAWEI> system-view
[~HUAWEI] dhcp snooping enable
[*HUAWEI] vlan 100
[*HUAWEI-vlan100] quit
[*HUAWEI] interface GigabitEthernet 0/1/0
[*HUAWEI-GigabitEthernet0/1/0] portswitch
[*HUAWEI-GigabitEthernet0/1/0] port default vlan 100
[*HUAWEI-GigabitEthernet0/1/0] quit
[*HUAWEI] vlan 100
[*HUAWEI-vlan100] dhcp snooping enable
[*HUAWEI-vlan100] dhcp snooping max-user-number 200 interface GigabitEthernet 0/1/0
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >