dhcp relay server-address

Use dhcp relay server-address to specify DHCP servers on the DHCP relay agent.

Use undo dhcp relay server-address to remove DHCP servers.

Syntax

dhcp relay server-address ip-address [ public | vpn-instance vpn-instance-name ]

undo dhcp relay server-address [ ip-address [ public | vpn-instance vpn-instance-name ] ]

Default

No DHCP server is specified on the DHCP relay agent.

Views

Interface view

Predefined user roles

network-admin

mdc-admin

Parameters

ip-address: Specifies the IP address of a DHCP server. The DHCP relay agent forwards DHCP packets received from DHCP clients to this DHCP server.

public: Specifies that the DHCP server is on the public network. If you do not specify this keyword, whether the DHCP server belongs to the public network or a VPN depends on the DHCP client location.

vpn-instance vpn-instance-name: Specifies the name of the MPLS L3VPN instance to which the DHCP server belongs. The instance name is a case-sensitive string of 1 to 31 characters. If you do not specify this option, whether the DHCP server belongs to the public network or a VPN depends on the DHCP client location.

Usage guidelines

The specified IP address of the DHCP server must not reside on the same subnet as the IP address of the DHCP relay agent interface. Otherwise, the DHCP clients might fail to obtain IP addresses.

You can specify a maximum of eight DHCP servers on an interface. The DHCP relay agent forwards the packets from the clients to all the specified DHCP servers.

If you specify an MPLS L3VPN, the DHCP relay agent forwards DHCP requests to the DHCP server in this VPN.

If you do not specify an IP address, the undo dhcp relay server-address command removes all DHCP servers on the interface.

Examples

# Specify DHCP server address 1.1.1.1 on VLAN-interface 10.

<Sysname> system-view
[Sysname] interface vlan-interface 10
[Sysname-Vlan-interface10] dhcp relay server-address 1.1.1.1

Related commands

dhcp select relay

display dhcp relay interface