DHCP Relay Overview
The Dynamic Host Configuration Protocol (DHCP) is a standardized client/server network protocol that dynamically assigns IPv4 addresses and other related configuration information to network devices.
DHCP provides an automated way to distribute and update IPv4 addresses and other configuration information on a network. A DHCP server provides this information to a DHCP client through the exchange of a series of messages, known as the DHCP conversation or the DHCP transaction. If the DHCP server and DHCP clients are located on different subnets, a DHCP relay agent is used to facilitate the conversation.
The RBFS DHCP relay agent handles all DHCP packets received on logical interfaces with the relay agent functionality enabled. This includes all DHCP broadcast and unicast packets to ensure that the whole DHCP communication between client and server can be tracked for operational and security reasons. The DHCP packets received from clients will than be forwarded to one or more DHCP servers to support high availability.
All DHCP packets send from the relay agent to the configured DHCP servers will be send with the IP address of the gateway interface (giaddr) or a dedicated source address per server. This allows to better traverse firewalls between relay agent and server.
Supported Platforms
Not all features are necessarily supported on each hardware platform. Refer to the Platform Guide for the features and the sub-features that are or are not supported by each platform.
DHCP Relay Agent
The following are the operation steps involved by the DHCP relay agent with multiple clients and servers:
-
DHCP client sends DISCOVER packets onto the LAN.
-
DHCP relay agent receives the DISCOVER packet, creates a client binding and forwards it to the configured server(s) in different subnets.
-
DHCP server replies with OFFER packet.
-
DHCP relay agent on receiving the OFFER, sends it to the client based on the binding.
-
DHCP client sends a REQUEST after receiving the OFFER.
-
DHCP relay agent forwards the REQUEST to the configured server(s).
-
Selected DHCP server replies to the REQUEST with an ACK.
-
DHCP relay agent receives the ACK and forward it to client.
-
Client will start using the IP and configuration after receiving the ACK.
-
DHCP relay agent listen to the unicast communication between the client and server and update the bindings.
DHCP Relay in Proxy Mode
The proxy mode is an enhancement for the DHCP relay function to hide and protect the actual DHCP servers from the clients. For servers this mode is transparent but for clients it seems that the relay agent is the server and the actual servers are not visible anymore.
The following are the operation steps involved by the DHCP relay agent in proxy mode with multiple clients and servers:
-
DHCP client sends DISCOVER packets onto the LAN.
-
DHCP relay agent receives the DISCOVER packet, creates a client binding and forwards it to the configured server(s) in different subnets.
-
DHCP server replies with OFFER packet.
-
DHCP relay agent on receiving OFFERs from multiple servers, select the OFFER from the first server, replaces the server identifier with relay agent address, update the binding and sends it to the client.
-
DHCP client sends a REQUEST to relay agent address after receiving the OFFER.
-
DHCP relay agent forwards the REQUEST to the configured server(s).
-
Selected DHCP server replies to the REQUEST with an ACK.
-
DHCP relay agent receives the ACK, replaces the server identifier with relay agent address and forward it to client.
-
Client will start using the IP and configuration after receiving the ACK.
-
Client request the relay agent for the lease renewals, which relay agent will forward to the selected server.
In all the steps above, the client remains unaware of the actual DHCP server.