< Home

ip relay address (upgrade-compatible command)

Function

Using the ip relay address command, you can configure DHCP server addresses on a VLANIF interface enabled with DHCP relay.

Using the undo ip relay address command, you can delete the configured DHCP server addresses.

By default, no DHCP server address is configured on a VLANIF interface enabled with DHCP relay.

Format

ip relay address ip-address

undo ip relay address { ip-address | all }

Parameters

Parameter

Description

Value

ip-address

Specifies the IP address of a DHCP server.

The value is in dotted decimal notation.

all

Deletes all the DHCP server addresses configured on an interface.

-

Views

VLANIF interface view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

The ip relay address command is applicable to DHCP relay agents. When a DHCP client needs to send a DHCP request packet to a DHCP server on a different network segment by using a DHCP relay agent, run the ip relay address command on the DHCP relay agent to configure a DHCP server address.

Prerequisites

DHCP relay has been enabled on the VLANIF interface by using the dhcp select relay command.

Precautions

If you run the ip relay address command multiple times, multiple DHCP server addresses are configured.

Example

# Configure DHCP server addresses 10.2.2.2 on VLANIF100 enabled with DHCP relay.

<HUAWEI> system-view
[HUAWEI] dhcp enable
[HUAWEI] interface vlanif 100
[HUAWEI-Vlanif100] dhcp select relay
[HUAWEI-Vlanif100] ip relay address 10.2.2.2
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >