The ip relay address command configures DHCP server addresses on an interface enabled with DHCP relay.
The undo ip relay address command deletes the configured DHCP server addresses.
By default, no DHCP server address is configured on an interface.
| Parameter | Description | Value |
|---|---|---|
| ip-address | Specifies the IP address of the DHCP server. | The value is in dotted decimal notation. |
| all | Deletes all DHCP server addresses configured on an interface. | - |
Usage Scenario
The ip relay address command is applicable to DHCP relay. When a DHCP client needs to send a DHCP Request packet to a DHCP server on a different network segment using a DHCP relay, run the ip relay address command on the DHCP relay to configure a DHCP server address.
Precautions
You can configure up to 20 DHCP server addresses on each interface enabled with DHCP relay.
When multiple DHCP server addresses are configured on an interface, the FW forwards the DHCP request to each DHCP server and forwards the first DHCP response received to the client.
# Specify IP addresses of two DHCP servers on GigabitEthernet 0/0/1.
<sysname> system-view [sysname] dhcp enable [sysname] interface GigabitEthernet 0/0/1 [sysname-GigabitEthernet0/0/1] ip relay address 10.3.3.1 [sysname-GigabitEthernet0/0/1] ip relay address 10.3.3.2 [sysname-GigabitEthernet0/0/1] dhcp select relay