Running DHCP as a single point of failure in your network is a recipe for disaster. When your sole DHCP server goes down, new devices cannot obtain IP addresses, existing leases eventually expire, and your entire network grinds to a halt. Self-hosted DHCP high availability ensures your network keeps handing out addresses even when hardware fails, services crash, or maintenance windows arrive.
This guide compares three proven approaches to DHCP high availability: the classic ISC DHCP failover protocol, the modern Kea DHCP HA architecture, and the lightweight Keepalived + dnsmasq combination. Each has different tradeoffs in complexity, scalability, and operational overhead.
Understanding DHCP High Availability
DHCP (Dynamic Host Configuration Protocol) is stateful by nature — the server must track which IP addresses are assigned to which clients, when leases expire, and what options (DNS servers, gateways, NTP servers) were handed out. This statefulness makes HA challenging: two DHCP servers must stay synchronized so they never hand out the same IP to two different clients.
There are three broad approaches to DHCP HA:
- Active-Active Failover — Both servers actively respond to DHCP requests and share a synchronized lease database.
- Active-Passive with Virtual IP — A primary server responds to all requests; a standby takes over the virtual IP if the primary fails.
- Split-Scope — Each server is responsible for a different range of the address pool, with no synchronization needed.
The solutions we cover span all three models, giving you options whether you need millisecond failover or simple redundancy.
ISC DHCP Failover Protocol
ISC DHCP (the dhcpd daemon) has been the gold standard for self-hosted DHCP for over two decades. Its built-in failover protocol provides true active-active high availability with lease synchronization between primary and secondary servers.
How It Works
The ISC DHCP failover protocol establishes a TCP connection between two DHCP servers. They communicate lease state changes in real-time, allowing both servers to respond to client requests. If one server goes offline, the other continues serving from the synchronized lease database. When the failed server returns, it resynchronizes automatically.
Docker Compose Configuration
| |
Primary Server Configuration (dhcpd-primary.conf)
| |
Secondary Server Configuration (dhcpd-secondary.conf)
| |
Pros and Cons
Pros:
- True active-active with real-time lease synchronization
- The
splitparameter controls load distribution between servers - Well-tested protocol with over 15 years of production use
- Automatic resynchronization when a failed server returns
Cons:
- ISC DHCP is in maintenance mode; no new features are being added
- Maximum of two servers per failover pair
- The failover protocol uses a proprietary binary format
- Configuration can be complex for beginners
Kea DHCP High Availability
Kea is the modern successor to ISC DHCP, developed by the same organization (ISC). It features a modular architecture, REST API, and a built-in high availability hook that supports both load-balancing and hot-standby modes.
How It Works
Kea HA uses a hook library (libdhcp_ha.so) that coordinates multiple Kea instances via HTTP REST API. Each server periodically sends heartbeat messages to its peers. If a peer stops responding, the remaining server takes over its workload. Unlike ISC DHCP’s proprietary failover protocol, Kea HA communicates over standard HTTPS.
Docker Compose Configuration
| |
Kea HA Configuration (kea-dhcp1.conf)
| |
Pros and Cons
Pros:
- Actively developed with regular releases (latest: 2.6.x series)
- REST API enables integration with orchestration tools
- Supports both load-balancing and hot-standby modes
- Can use MySQL or PostgreSQL backends for lease storage
- Native IPv6 support with HA
Cons:
- More resource-intensive than ISC DHCP
- Configuration is JSON-based (not the familiar ISC format)
- Requires the Control-agent component to be running
- HA hook library is only available in Kea 2.0+
Keepalived + dnsmasq (Active-Passive)
For smaller networks where simplicity matters more than active-active load distribution, combining dnsmasq with Keepalived provides reliable active-passive DHCP HA using a virtual IP address.
How It Works
Keepalived uses VRRP (Virtual Router Redundancy Protocol) to manage a floating virtual IP between two servers. The primary server holds the VIP and runs dnsmasq. If the primary fails, Keepalived on the secondary detects the VRRP timeout, claims the VIP, and starts its own dnsmasq instance.
Docker Compose Configuration
| |
Keepalived Health Check Script
| |
dnsmasq Configuration
| |
Pros and Cons
Pros:
- Extremely simple to deploy and understand
- dnsmasq also provides DNS, TFTP (for PXE boot), and NTP
- VRRP is a standard protocol supported by many vendors
- Can scale to more than 2 servers with VRRP priorities
- Low resource footprint
Cons:
- Active-passive only — the standby server is idle
- Lease database is NOT synchronized between servers (clients may get different IPs after failover)
- Failover takes 3-5 seconds (VRRP advertisement timeout)
- Not suitable for large networks with thousands of leases
Comparison Table
| Feature | ISC DHCP Failover | Kea HA | Keepalived + dnsmasq |
|---|---|---|---|
| HA Mode | Active-Active | Active-Active or Hot-Standby | Active-Passive |
| Max Servers | 2 | Unlimited | Unlimited |
| Lease Sync | Real-time (proprietary) | Real-time (HTTP REST) | None |
| Failover Time | < 1 second | < 3 seconds | 3-5 seconds |
| Configuration | ISC config format | JSON | dnsmasq config + VRRP |
| IPv6 Support | Yes | Yes (with HA) | Yes |
| Database Backend | File-based | File, MySQL, PostgreSQL | File-based |
| REST API | No | Yes (Control-agent) | No |
| Active Development | Maintenance mode only | Yes (ISC) | Yes (community) |
| Docker Support | community images | Official ISC images | Community images |
| Stars | Legacy (no GitHub) | 714+ | 4,000+ (dnsmasq) |
| Best For | Enterprise networks | Modern deployments | Small/medium networks |
Why Self-Host DHCP High Availability?
Running your own DHCP infrastructure gives you complete control over IP address assignment, option delivery, and network policies. Unlike cloud-managed DHCP services, self-hosted solutions keep your network operational even during internet outages. For organizations with strict data sovereignty requirements, keeping DHCP on-premises ensures no lease data leaves your network perimeter.
When combined with self-hosted DNS resolvers and overlay networks, you can build a fully autonomous network stack that operates independently of any external provider. Adding network traffic analysis on top gives you full visibility into how your DHCP-assigned addresses are being used.
Choosing the Right DHCP HA Solution
For most organizations, Kea HA is the recommended choice. It is actively developed by ISC, supports both active-active and hot-standby modes, and provides a REST API for automation. The JSON-based configuration may feel unfamiliar to ISC DHCP veterans, but the benefits — modern architecture, database backends, and ongoing development — far outweigh the learning curve.
ISC DHCP Failover remains a solid choice for existing deployments that already run ISC DHCP. If your current setup works, there is no urgent need to migrate — ISC DHCP will continue to receive security fixes even though no new features are planned.
Keepalived + dnsmasq is ideal for home labs, small offices, and situations where simplicity trumps feature richness. The active-passive model means the standby server is idle, but the operational simplicity makes it worth the tradeoff for networks under 200 clients.
FAQ
What is the difference between DHCP failover and DHCP high availability?
DHCP failover specifically refers to the ISC DHCP failover protocol — a proprietary binary protocol that synchronizes lease state between two servers. DHCP high availability is a broader term that encompasses any method of ensuring DHCP service continuity, including Kea HA, Keepalived/VRRP, split-scope configurations, and load balancer-based approaches.
Can I run three or more DHCP servers in a failover group?
ISC DHCP failover is limited to exactly two servers. Kea HA supports unlimited peers — you can configure three or more Kea instances in a load-balancing or hot-standby arrangement. Keepalived with VRRP also supports unlimited servers, each with a different priority level.
Do I need to synchronize lease databases between DHCP servers?
For active-active HA, yes — both servers must know which IPs are assigned to avoid conflicts. ISC DHCP and Kea HA handle this automatically. For active-passive setups (Keepalived + dnsmasq), synchronization is not needed because only one server is active at a time, but clients may receive different IPs after failover.
What happens when a failed DHCP server comes back online?
With ISC DHCP failover, the recovering server connects to its peer and requests a lease state update. The MCLT (Maximum Client Lead Time) parameter determines how many leases the peer will have handed out during the outage. With Kea HA, the recovering server contacts its peers via the REST API and resynchronizes its lease database. With Keepalived + dnsmasq, the recovering server simply becomes the standby — its old lease file is stale but harmless since it is not actively serving.
Can Kea HA use MySQL or PostgreSQL for lease storage?
Yes. Kea supports multiple lease database backends: memfile (CSV file), MySQL, PostgreSQL, and Cassandra. When using a shared database backend, lease state is inherently synchronized between servers, simplifying HA configuration.
Is dnsmasq suitable for production DHCP HA?
For small to medium networks (under 200 clients), yes. dnsmasq is widely deployed and reliable. However, the lack of lease synchronization between active and passive servers means clients may receive different IP addresses after failover, which can be problematic for services that depend on stable IP assignments.