Problem with multiple DHCP servers on the same segment
If the network is configured to obtain IP addresses automatically, if there is only one DHCP server, the DHCP server will be a single point of failure, and if the DHCP server goes down, all the servers configured to automatically obtain IP addresses will fail. clients will not be able to connect to the network.
Redundant DHCP servers can eliminate single points of failure, but they are not without problems. Here, I will explain the problem.
If there are multiple DHCP servers on the same segment, the client will receive multiple DHCP Offers. The client selects one of them and sends a DHCP Request.
You may think that there is no problem because you choose one of them, but if you install multiple DHCP servers, you need to pay attention to the assignment of the IP address of the DHCP server.
If the IP address leasing range of each DHCP server overlaps, depending on how the leases are made, there will be clients with overlapping IP addresses on the same network.
As a result, the network becomes confused and communication becomes difficult. To solve these problems, each DHCP server must be configured with non-overlapping lease ranges.
But there are also problems. That is, setting IP address pools so that lease ranges do not overlap reduces the number of available IP addresses.
If you have two DHCP servers, the IP address pools must be halved or the lease ranges will overlap, resulting in half the available IP addresses.
When installing multiple DHCP servers, it is necessary to take this into account when planning IP addressing.
Placement of DHCP server
Here, I will explain the placement of the DHCP server.
DHCP client sends DHCP Discover to get information such as IP address. This DHCP Discover is a broadcast.
See the diagram below. What happens if the DHCP server is installed beyond the router?
Since routers block broadcasts instead of forwarding them, DHCP Discover will not reach the DHCP server beyond the router.
As a result, the DHCP client cannot deliver DHCP Discover to the DHCP server, so it times out and cannot connect to the network because it cannot obtain an IP address.
Blocking broadcasts by routers means that you need a DHCP server for each network.
By using DHCP, even if IP-related parameter settings can be automated, the number of DHCP servers will increase. Operation and management of the server is difficult, and the advantage is halved.
Once you set up a DHCP server, you can't leave it alone. The OS needs to be updated, and as the number of devices increases, the frequency of malfunctions and failures also increases, and maintenance is also required.
If you can automatically distribute and centrally manage each network with one DHCP server, there are great advantages in terms of management and cost!
Therefore, a function called "DHCP relay agent" is provided. By using this function, it becomes possible to relay DHCP broadcast requests.