DHCP in failover Mode config replication
Glenn.Satchell at uniq.com.au
Mon May 18 14:25:01 UTC 2009
>Date: Fri, 15 May 2009 15:51:05 -0400
>Subject: DHCP in failover Mode config replication
>From: Carlos Dias <cmdias at gmail.com>
>To: dhcp-users at lists.isc.org
>X-BeenThere: dhcp-users at lists.isc.org
>I was just wondering how most of you manage/replicate the config files
>between your servers in failover mode ?
>A script ? (Any examples)
>I have 2 server with version 4.0.1
For failover I use the "include "filename";" command. There are three
1. failover peer declaration for the primary server,
2. failover peer declaration for the secondary server,
3. the rest of the configuration, which should be identical for both servers.
There are two ways to approach this:
1. Put the failover peer declaration in dhcpd.conf and include a file
with the remainder of the configuration. This second file will be
identical for both hosts.
2. The reverse of above: put the common configuration in
dhcpd.conf and include a separate file with the failover peer
So, the only replication required is the file with the common
configuration statements. Depending on how you modify the file you
a) have it copied as part of the update process,
b) manually copy it to the other host,
c) have a scheduled job to copy it at regular intervals.
If the file is modified by the copy, then dhcpd needs to be restarted
on the other host.
At one site that I looked after that had multiple servers, we manually
editted the particular piece of configuration, then used Makefiles to
assemble dhcpd.conf, copy it to remote hosts, and restart dhcpd.
This is not a very difficult problem. You can use your favourite copy
tools, eg ftp, scp, rsync to get the file over. Then ssh or rsync could
be used to remotely run the required stop/start commands. Most scripts
to do this would be fairly simple.
More information about the dhcp-users