CLI Reference DHCP Configuration Commands
The configuration example below enables the CLASS to allocate
addresses.
Ruijie(config)# ip dhcp use class
lease
Use this command to define the lease time of the IP address that the DHCP server assigns to the client in the
DHCP address pool configuration mode. The no form of this command can be used to restore it to the default
configuration. The lease time ranges from 1 minute to 365 days and 23 hours 59 minutes.
lease { days [ hours ] [ minutes ] | infinite }
no lease
(Optional) Lease time in hours. It is necessary to
define the days before defining the hours.
(Optional) Lease time in minutes. It is necessary
to define the days and hours before defining the
minutes.
The lease is infinite for the static address pool. And the lease of other
address pools is 1 day by default.
DHCP address pool configuration mode.
When the lease is getting near to expire, the DHCP client will send
the request of renewal of lease. In general, the DHCP server will
allow the renewal of lease of the original IP address.
The configuration example below sets the DHCP lease to 1 hour.
lease 0 1
The configuration example below sets the DHCP lease to 1 minute.
lease 0 0 1
Enable the DHCP client to access
the IP address.