Backup and Recovery Concepts: Failures, RPO and RTO
The DBA's Most Important Job
Everything else can be fixed later, but lost data cannot. A good DBA is judged by one question: *can you get the data back?* A backup you have never restored is only a hope, not a backup.
Types of Failures
| Failure | Example | Fix |
|---|---|---|
| Statement failure | Insert violates a constraint | Oracle rolls back the statement. Fix the SQL. |
| User process failure | Client crashes | PMON cleans up automatically |
| User error | Someone drops a table or deletes data | Flashback, or point-in-time recovery |
| Instance failure | Server power cut, memory crash | SMON recovers at next startup using redo |
| Media failure | Disk dies, datafile deleted | Restore from backup, then recover using redo |
| Disaster | Data center lost | Standby database, offsite backups |
Restore vs Recover
| Word | Meaning |
|---|---|
| Restore | Copy files back from the backup |
| Recover | Apply redo to bring them up to date |
Simple example: Your document gets corrupted. Restore means opening last night's saved copy. Recover means redoing the edits you made since then using your typing history (redo).
Backup Types
| Type | Meaning |
|---|---|
| Cold (consistent) backup | Database is shut down. Simple but needs downtime. |
| Hot (online) backup | Database is running. Needs ARCHIVELOG mode. |
| Full backup | Copies all used blocks |
| Incremental level 0 | Same as full, the base for incrementals |
| Incremental level 1 | Only blocks changed since the last backup |
| Logical backup | Data Pump export of objects and rows |
| Physical backup | RMAN copies of datafiles |
RPO and RTO
| Term | Question | Example |
|---|---|---|
| RPO (Recovery Point Objective) | How much data can we afford to lose? | At most 15 minutes |
| RTO (Recovery Time Objective) | How long can we be down? | At most 2 hours |
Your backup plan is built from these two numbers. A tiny RPO needs archived redo kept safe or a standby database. A tiny RTO needs fast restore storage or standby.
A Typical Strategy
| When | What |
|---|---|
| Sunday | Incremental level 0 (full) |
| Monday to Saturday | Incremental level 1 |
| Every 15-60 minutes | Back up archived redo logs |
| Monthly | Test a full restore on another server |
The 3-2-1 rule: Keep 3 copies of your data, on 2 different kinds of storage, with 1 copy off-site.
Never skip this: Test restores regularly. Many companies discover their backups are unusable only on the day they need them.
Conclusion
Know your failure types, choose RPO and RTO with the business and build a backup plan that you actually test.
Quick Summary: Restore = copy files back, recover = apply redo. RPO is data loss, RTO is downtime.

