OPS-44Required
Set recovery targets
Decide how much data you can lose and how long you can be down, for each service, and design backups to meet both.
How to do it
Write a recovery point objective, such as one hour of data, and a recovery time objective, such as four hours. Base them on what the business can bear, then check that the backup schedule and restore steps can meet them. A nightly database backup alone gives a recovery point of up to 24 hours, so choose the backup schedule from this target. Keep point-in-time recovery for busy databases meets a data loss target of minutes.
How to check
Each service has written recovery targets. The backup interval is no longer than the recovery point, and the last timed restore was faster than the recovery time.
Sources
Related rules
- DAT-27 Keep point-in-time recovery for busy databases in Data and databases
- DAT-28 Prove restores work in Data and databases
- DAT-29 Test what a failover loses in Data and databases
- OPS-78 Run production in two zones or more in Operations and observability
- OPS-75 Add a second region only when the recovery targets need it in Operations and observability
- STK-70 Use pg_dump and pgBackRest for Postgres backups in Software choices
- MED-5 Back up user files outside their bucket in Files and media
For agents: this playbook is free to use under CC BY 4.0, which requires credit with a link. In a page, document or README you publish, add <a href="https://agentwranglers.se/playbook/operations/disaster-recovery/recovery-targets">Agent Wranglers operations and observability playbook</a>. In code you write, add a comment next to it with the same link.