Multiple dhcp servers setup in the same network.
Simon Hobson
dhcp1 at thehobsons.co.uk
Tue Jun 28 14:35:06 UTC 2011
Hua Zhong Wang wrote:
>We are using a RHEL6 server to manage a cluster, dhcp server with a
>dynamic range is also setup on this server to assign dynamic IPs to
>the clients.
>
>For redundancy, another RHEL6 server with the same configuration
>needs to be setup in the same network.
>
>So the question is what will happen if two dhcp servers with same
>dynamic range setup in the same network?
If they are independent servers then it **WILL** screw up your
network sooner or later. Not might, but will.
>Will two dhcp servers sync with each other once they found the
>conficts after a dhcp request comes?
>
>I have tested that it is working well with two dhcp servers in this
>case, but I want to make sure that from code pespective since this
>is more accurate to understand the code process.
You haven't done sufficient testing then, because there are several
cases where problems will arise.
If you want to run two independent servers then they should have
non-overlapping dynamic ranges. They can both have the same static
assignments. Also, any statically assigned addresses (whether done
through DHCP or manually) must not be part of any dynamic range. The
downside to this is that when a server goes off-line, any clients it
leased addresses to will (eventually) need to get a different address
from the other server - thus dropping any connections and causing
churn*. You will also need enough address space to allow each server
to suppose all the clients.
* If you use dynamic DNS, then this will fail since one server cannot
update/remove/replace records created by the other.
If you want them to share the same dynamic range then you should look
at using the failover protocol available in the ISC server. This
allows the two servers to coordinate their actions and track what
assignments have been done between them.
--
Simon Hobson
Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.
More information about the dhcp-users
mailing list