High availability is a system design that minimizes downtime by eliminating single points of failure. Measured in 'nines' – 99.9% (8.7h downtime/year), 99.99% (52min/year), 99.999% (5min/year). Requires: redundant components, automatic failover, health monitoring, and tested recovery procedures.
High availability engineering ensures systems remain operational despite individual component failures. The availability percentage represents uptime commitment: 99.9% (three nines) allows 8.7 hours downtime per year, 99.99% (four nines) allows 52 minutes, and 99.999% (five nines) allows 5.2 minutes. Achieving each additional nine requires exponentially more investment. HA requires eliminating every single point of failure (SPOF): multiple application servers behind load balancers, database replication with automatic failover, redundant network paths, multi-AZ deployment, and redundant power/cooling. HA is not just redundancy – it requires: automatic detection (health checks, heartbeats), automatic recovery (failover without human intervention), and isolation (failure in one component does not cascade). Testing is critical: regularly kill instances (chaos engineering), test failover procedures, and measure actual recovery time. Many teams claim HA but have never tested their failover – the first real failure reveals untested assumptions.
Load Balancer
A load balancer distributes incoming traffic across multiple backend servers to prevent any single server from becoming overwhelmed. Layer 4 (TCP) load balancers route by IP/port. Layer 7 (HTTP) load balancers can route by URL path, headers, or cookies. Health checks remove failed backends automatically.
Failover
Failover is the automatic transfer of traffic from a failed primary system to a standby replica. Database failover promotes a replica to primary. DNS failover routes to a backup IP. Load balancer failover removes failed backends. Recovery time (RTO) depends on detection speed and promotion mechanism – seconds for load balancer, minutes for database.
Disaster Recovery (DR)
Disaster recovery is the plan and infrastructure for restoring service after catastrophic failure (region outage, data center loss, ransomware). Defined by RPO (how much data loss is acceptable) and RTO (how quickly service must resume). DR requires cross-region replication, tested runbooks, and regular drills.