dhcpv6 relay link-address

Function

The dhcpv6 relay link-address command configures a DHCPv6 relay gateway address.

The undo dhcpv6 relay link-address command restores the default DHCPv6 relay gateway address.

By default, a DHCPv6 relay agent selects the first configured global unicast address from an interface with DHCPv6 relay enabled as its gateway address.

Format

dhcpv6 relay link-address ipv6-address

undo dhcpv6 relay link-address ipv6-address

Parameters

Parameter Description Value
ipv6-address

Specifies an IPv6 address as the gateway address.

The value is a 32-digit hexadecimal number, in the format of X:X:X:X:X:X:X:X.

Views

100GE interface view, 10GE interface view, 25GE interface view, 400GE interface view, 40GE interface view, 50GE interface view, Eth-Trunk interface view, FlexE sub-interface view, FlexE interface view, GE optical interface view, GE interface view, GE electrical interface view, Global VE sub-interface view, VBDIF interface view, VE sub-interface view, VLANIF interface view, Sub-interface view

Default Level

2: Configuration level

Task Name and Operations

Task Name Operations
dhcp write

Usage Guidelines

Usage Scenario

The IPv6 address of the first DHCPv6 relay agent is used as the DHCPv6 relay gateway address for clients and is carried in the link-address field in DHCPv6 relay messages. The DHCPv6 server uses the link-address field to determine the network segment on which a client resides so that the server can assign an IPv6 address on this network segment to the client.

If a DHCPv6 relay gateway address is not configured, the DHCPv6 relay interface randomly selects a global unicast address as the gateway address, which does not facilitate proper address planning and allocation. To allow clients connecting to a DHCPv6 relay interface to obtain IPv6 addresses on the same network segment, run the dhcpv6 relay link-address command to configure a gateway address. Then the DHCPv6 relay interface uses this configured gateway address for all DHCPv6 request messages it receives.

Precautions

The configured DHCPv6 relay gateway address must be a global unicast address of the DHCPv6 relay interface.

An interface can have only one IPv6 address configured as the DHCPv6 relay gateway address. If a gateway address has been configured for an interface and the dhcpv6 relay link-address command is run, the newly configured gateway address replaces the original one.

Example

# Configure 2001:db8::4 as the DHCPv6 relay gateway address for DHCPv6 messages received on GE 0/1/0.
<HUAWEI> system-view
[~HUAWEI] interface GigabitEthernet 0/1/0
[~HUAWEI-GigabitEthernet0/1/0] dhcpv6 relay link-address 2001:db8::4
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >