Dashboard
Courses
Problems
Badges
Theme
Sign inStart free
Courses/Reliability and Failure
Lesson 19 of 24

RPO, RTO and disaster recovery

Set explicit targets for data loss and downtime, and pick a recovery strategy that meets them at a sensible cost.

15 min read

Two numbers drive the design

Recovery point objective (RPO) is the maximum data loss you accept, measured in time: an RPO of 5 minutes means losing up to the last 5 minutes of writes. Recovery time objective (RTO) is how long until service is restored. Both should come from the business: a social feed might accept an RPO of minutes and an RTO of an hour; a payment ledger needs an RPO of zero and an RTO of minutes. Different data within one system often deserves different targets.

From targets to mechanisms

Each target maps onto concrete choices. Tighter targets cost more in money, latency and complexity, so do not buy an RPO of zero for data that can be rebuilt.

  • RPO of hours: periodic snapshots
  • RPO of seconds to minutes: asynchronous replication or continuous log shipping
  • RPO of zero: synchronous replication to a second location before acknowledging writes
  • RTO of hours: restore from backup into new infrastructure
  • RTO of minutes or less: running standby with automatic or one-command failover

Disaster recovery tiers

Strategies trade cost for speed. Backup and restore keeps only data copies elsewhere and rebuilds everything on demand: cheap, with an RTO of hours. Pilot light keeps the data replicated and a minimal core running, scaling up during a disaster. Warm standby runs a scaled-down full copy that can take traffic within minutes. Active-active serves traffic from multiple sites all the time, so losing one is a capacity event rather than a recovery: the fastest and most expensive option.

Practise the disaster

DR plans rot. Infrastructure changes, runbooks reference deleted scripts, the standby is missing a service added last quarter, and the person who knew the steps has left. Run DR exercises at least yearly, ideally by actually failing over production traffic. Automate failover where possible, because during a real regional outage your consoles, CI and even chat tools may be degraded too. A drill also measures your real RTO, which is usually longer than the planned one.

Key takeaways

  • RPO bounds data loss; RTO bounds downtime; set both per data type
  • An RPO of zero requires synchronous replication before acknowledging writes
  • Backup-and-restore, pilot light, warm standby and active-active trade cost against RTO
  • An unpractised DR plan will fail; exercise it with real failovers

Sign in to track lessons and earn badges.

Backups and restore drillsMulti-AZ versus multi-region

Challenge checkpoint

Course: 0/24 lessons · 0/10 challenges0%

Build it on the canvas, pass the review (70+) and mark it complete to count it toward the course badge.

  1. 8/10Design a Payment LedgerBuild a double-entry ledger with idempotent transfers, fenced writers and an RPO of zero.MAJORHardPRO
All 10 challenges →