Linux

Where Is the keepalived Config File?

keepalived reads keepalived.conf in /etc/keepalived with VRRP instances and health checks inside.

Last updated

keepalived configures failover from one file in /etc/keepalived. The keepalived.conf file defines VRRP instances with priorities and virtual IPs. Health check scripts referenced inside gate mastership per node.

Conf.d snippets extend it on distributions that enable includes. Priorities decide the initial master while weights shift on script results. Test failover by stopping the service, never by editing live.

Where keepalived stores this, by platform

Linux
/etc/keepalived/keepalived.conf

VRRP instances with priorities and virtual IPs live here. Health scripts sit beside it by reference. Reload to apply without full restart.

Frequently asked questions

How do I add a virtual IP?

Add it to the virtual_ipaddress block of the instance, then reload. Gratuitous ARP announces the move. Keep priorities distinct across nodes.

Why does mastership flap?

Health scripts disagree or multicast breaks between nodes. Check script exit codes and firewall paths first. Timers tune sensitivity afterward.

Notice an outdated path? Let us know.