$linuxjunkies
>

failover

also: automatic failover, failover mechanism

Automatic switching from a failed system or service to a backup or redundant one, ensuring continuous availability without manual intervention.

Failover is a high-availability mechanism that detects when a primary system, server, or service fails and automatically transfers its workload to a standby replacement. This happens transparently to users and applications, minimizing downtime and service disruption.

Common failover scenarios include database replication (switching to a replica when the primary dies), load balancing across multiple web servers, or using heartbeat monitoring between nodes in a cluster. For example, in a two-node PostgreSQL setup with streaming replication, if the primary database crashes, the standby is promoted to primary and clients reconnect automatically.

Failover requires three key components: detection (monitoring the primary's health), decision logic (determining when to switch), and automation (promoting the backup without human action). Tools like keepalived, pacemaker, and cloud provider auto-scaling implement failover for different infrastructure levels.

Related terms