Setting up failover is fairly straightforward. There are several guides and howtos on the Internet. I used the following:
ISC: A Basic Guide to Configuring DHCP Failover, and
Steven Diver: ISC DHCP Failover Configuration
Here are the important sections of the respective configuration files. The Main Router has the IP address 192.168.19.1 and the Backup Router has 192.168.19.44.
# dhcpd.conf
#
# Configuration file for ISC dhcpd
#
# Configuration of failover
#
failover peer "failover-partner" {
primary;
address 192.168.19.1;
peer address 192.168.19.44;
max-response-delay 60;
max-unacked-updates 10;
mclt 3600;
split 128;
load balance max seconds 3;
}
.....
# Subnet specification for unknown clients, primarily on the WLAN
subnet 192.168.19.0 netmask 255.255.255.0 {
pool {
failover peer "failover-partner" ;
range 192.168.19.241 192.168.19.253;
}
# .254 is reserved for the 'floating' IP address of VRRP
}
# Subnet specification for IOT devices on VLAN 2
subnet 172.19.2.0 netmask 255.255.255.0 {
pool {
failover peer "failover-partner" ;
range 172.19.2.10 172.19.2.99;
option domain-name-servers 1.1.1.1;
option ntp-servers 0.dk.pool.ntp.org;
option ntp-servers 1.dk.pool.ntp.org;
}
}
......
The configuration of the Backup Router is almost identical to the Main Router, the difference being the specification of the partner and it not having the line 'split 128'.
# dhcpd.conf
#
# Configuration file for ISC dhcpd
#
# Configuration of failover
#
failover peer "failover-partner" {
secondary;
address 192.168.19.44;
peer address 192.168.19.1;
max-response-delay 60;
max-unacked-updates 10;
load balance max seconds 3;
}
......