CLI Reference Guide-R05

Table Of Contents
Chapter 27
| DHCP Commands
DHCP Relay Option 82
– 809 –
Command Mode
Global Configuration
Usage Guidelines
Using this command with or without any keywords will enable DHCP Option 82
information relay. You must also specify the IP address for at least one active
DHCP server (with the ip dhcp relay server command). Otherwise, the switchs
DHCP relay agent will not be able to forward client requests to a DHCP server.
DHCP provides a relay agent information option for sending information about
its DHCP clients or the relay agent itself to the DHCP server. Also known as
DHCP Option 82, it allows compatible DHCP servers to use this information
when assigning IP addresses, or to set other services or policies for clients.
When Option 82 is enabled, the requesting client (or an intermediate relay
agent that has used the information fields to describe itself) can be identified in
the DHCP request packets forwarded by the switch and in reply packets sent
back from the DHCP server. Depending on the selected frame format set for the
remote-id by this command, this information may specify the MAC address, IP
address, or an arbitrary string for the requesting device (that is, the relay agent
in this context).
By default, the relay agent also fills in the Option 82 circuit-id field with
information indicating the local interface over which the switch received the
DHCP client request, including the VLAN ID, stack unit, and port. This allows
DHCP client-server exchange messages to be forwarded between the server
and client without having to flood them onto the entire VLAN.
DHCP request packets received by the switch are handled as follows:
If a DHCP relay server has been set on the switch, when the switch receives
a DHCP request packet without option 82 information from the
management VLAN or a non-management VLAN, it will add option 82 relay
information and the relay agent’s address to the DHCP request packet, and
then unicast it to the DHCP server.
If a DHCP relay server has been set on the switch, when the switch receives
a DHCP request packet with option 82 information from the management
VLAN or a non-management VLAN, it will process it according to the
configured relay information option policy:
If the policy is “replace,” the DHCP request packets option 82 content
(the RID and CID sub-option) is replaced with information provided by
the switch. The relay agent address is inserted into the DHCP request
packet, and the switch then unicasts this packet to the DHCP server.
If the policy is “keep,” the DHCP request packet's option 82 content will
be retained. The relay agent address is inserted into the DHCP request
packet, and the switch then unicasts this packet to the DHCP server.
If the policy is “drop,” the original DHCP request packet is flooded onto
the VLAN which received the packet but is not relayed.