The dhcp server conflict auto-recycle interval command enables automatic reclaim of conflicting IP addresses in the interface address pool and configures the interval for the automatic reclaim.
The undo dhcp server conflict auto-recycle interval command disables automatic reclaim of conflicting IP addresses in the interface address pool and deletes the configured interval for the automatic reclaim.
By default, automatic reclaim of conflicting IP addresses in the interface address pool is disabled.
dhcp server conflict auto-recycle interval day day [ hour hour [ minute minute ] ]
undo dhcp server conflict auto-recycle interval
Parameter |
Description |
Value |
---|---|---|
day day |
Specifies the interval for the automatic reclaim, in days. |
The value is an integer that ranges from 0 to 999, in days. The default value is 0. |
hour hour |
Specifies the interval for the automatic reclaim, in hours. |
The value is an integer that ranges from 0 to 23, in hours. The default value is 0. |
minute minute |
Specifies the interval for the automatic reclaim, in minutes. |
The value is an integer that ranges from 0 to 59, in minutes. The default value is 0. |
Usage Scenario
This command is used on a DHCP server. When a DHCP server allocates IP addresses to clients, IP address conflict may occur because IP addresses of some hosts have been manually configured. In this case, the DHCP server considers these IP addresses as conflicting IP addresses, and allocates available IP addresses from the conflicting IP addresses to clients only after available IP addresses in the address pool are used up. To reclaim conflicting IP addresses promptly, the administrator can run this command to enable automatic reclaim and specify the reclaim interval.
Prerequisites
IP addresses in the interface address pool have been configured using the ip address command.
The DHCP server function has been enabled on the interface using the dhcp select interface command.
# Enable automatic reclaim for conflicting IP addresses in the address pool on VLANIF 100, and set the interval for automatic reclaim to one day.
<HUAWEI> system-view [HUAWEI] dhcp enable [HUAWEI] interface vlanif 100 [HUAWEI-Vlanif100] ip address 192.168.1.1 24 [HUAWEI-Vlanif100] dhcp select interface [HUAWEI-Vlanif100] dhcp server conflict auto-recycle interval day 1
<HUAWEI> system-view [HUAWEI] dhcp enable [HUAWEI] interface gigabitethernet 0/0/1 [HUAWEI-GigabitEthernet0/0/1] undo portswitch [HUAWEI-GigabitEthernet0/0/1] ip address 192.168.1.1 24 [HUAWEI-GigabitEthernet0/0/1] dhcp select interface [HUAWEI-GigabitEthernet0/0/1] dhcp server conflict auto-recycle interval day 1