Study guide
Technical reference and lesson notes
Amazon RDS and Aurora Backup and Recovery
Purpose of This Lesson
This lesson explains how Amazon RDS and Amazon Aurora protect database data through automated backups, transaction logs, manual snapshots, point-in-time recovery, and cross-Region backup copies. The key operational skill is selecting the right backup mechanism for recovery speed, retention, and regional resilience.
Key Concepts
- Automated RDS backups: RDS creates a backup snapshot during a configured backup window and uploads transaction logs to Amazon S3 approximately every five minutes.
- Point-in-time recovery (PITR): RDS restores a backup and replays transaction logs to recreate the database at a selected time within the retention period.
- Automated backup retention: RDS supports a retention period from 0 through 35 days. A value of
0disables automated backups; it does not prevent manual snapshots. - Manual snapshots: A manual snapshot is a full backup of the database. It does not expire automatically and remains until it is deleted.
- Restore behavior: Restoring an RDS backup creates a new DB instance with a different endpoint. Applications must be redirected to the new endpoint if the restored database replaces the original.
- Backup eligibility: The DB instance must be in the
availablestate for automated backups to occur. - Aurora backups: Aurora uses continuous, incremental backups and supports point-in-time restoration within its retention period. Automated backups cannot be disabled for an Aurora DB cluster.
- Maintenance window: RDS uses a separate configurable window for operating-system and database patching. Some maintenance operations may require the database to be taken offline.
RDS Backup and Recovery Mechanics
Automated backups
An RDS DB instance has a configurable backup window with a start time and duration. The window should be scheduled when database activity is lower, such as overnight, because the beginning of the backup can cause a brief I/O interruption and may place some load on the system. The window must be long enough for the backup to complete.
During automated protection:
- A backup snapshot is created during the backup window.
- Transaction logs are captured approximately every five minutes.
- The snapshot and logs are stored in Amazon S3 as part of the managed backup process.
- During recovery, RDS restores the snapshot and replays transaction logs to the requested point in time.
The available recovery range is limited by the configured retention period and the latest available backup data. Automated backups do not operate while the DB instance is not in the available state.
Retention and point-in-time recovery
The automated backup retention period can be from 0 to 35 days:
- 0 days: Automated backups are disabled.
- 1–35 days: RDS retains automated backup data for the selected period.
- 35 days: The latest 35 days of automated backup data are retained.
PITR is useful when the recovery target is between scheduled full backups. RDS uses the latest suitable snapshot and replays transaction logs until the requested time. The result is a new DB instance rather than a change to the original instance.
Manual snapshots
Manual snapshots, sometimes simply called RDS snapshots, capture the entire database for a single-AZ DB instance. They are not governed by the automated backup retention period and do not expire automatically. This makes them appropriate for long-term retention, provided the organization manages their storage and associated cost.
A manual snapshot still involves a brief I/O suspension while the snapshot is taken. For Multi-AZ deployments, the source of that I/O impact depends on the engine and configuration described in the lesson:
- For Multi-AZ SQL Server, I/O activity is briefly suspended on the primary node.
- For Multi-AZ MariaDB, MySQL, Oracle, and PostgreSQL, the snapshot is taken from the standby.
Parameter and option groups
RDS DB instances are automatically associated with default DB parameter and option groups. These can be modified when the database requires non-default configuration. When planning a restore, configuration dependencies such as these groups should be considered as part of the target instance design.
Cross-Region automated backups
RDS automated backups can be configured for replication to another AWS Region. This provides protection against a complete regional failure. If the primary Region becomes unavailable, the backup in the other Region can be used to bring up a replacement database instance with a new endpoint.
Aurora Backup Behavior
Aurora backup management is performed at the DB cluster level rather than for an individual RDS DB instance.
- Aurora backups are continuous and incremental.
- Aurora supports restoration to any point in time within the configured retention period.
- The default Aurora backup retention period is one day, regardless of whether the cluster was created through the console, API, or CLI.
- Automated backups cannot be disabled for an Aurora DB cluster.
- The retention period is managed by the DB cluster.
- AWS Backup can also be used to manage Aurora cluster backups.
Aurora manual snapshots capture the entire DB cluster. Like RDS manual snapshots, they do not expire automatically and are suitable for longer-term retention. Aurora snapshot data can also be exported to Amazon S3. Automated backups and manual DB cluster snapshots can be copied within the same Region or across Regions, and shared snapshots can be copied as well.
Aurora automated backups are removed when their retention period ends, when automated backups are disabled for the cluster, and when the DB cluster is deleted. To preserve a backup beyond the automated retention lifecycle, copy it to a manual snapshot before it is removed.
Exam- or Assessment-Relevant Takeaways
- Distinguish automated backups from manual snapshots: automated backups support PITR and have a 0–35-day retention setting; manual snapshots are full backups that do not expire automatically.
- A retention period of
0disables RDS automated backups but does not disable the ability to create manual snapshots. - RDS restoration creates a new DB instance and endpoint. It does not restore over the existing instance.
- Choose a backup window outside peak business activity because backup initiation can cause a brief I/O interruption.
- Use cross-Region backup replication or snapshot copying when the recovery requirement includes protection from regional failure.
- Aurora automated backups cannot be disabled, have a default one-day retention period, and are controlled at the cluster level.
- For long-term Aurora retention, copy an automated backup or cluster snapshot to a manual snapshot.
- Do not confuse the backup window with the maintenance window. Backups protect data; maintenance handles operating-system and database patching.
Tool / Feature Decision Guide
| Requirement | Appropriate feature | Reason |
|---|---|---|
| Recover an RDS database to a time between backups | Automated backups with PITR | RDS replays transaction logs to the requested time within retention. |
| Keep a backup beyond the automated retention period | Manual snapshot | Manual snapshots do not expire automatically. |
| Disable RDS automated backup activity | Set automated backup retention to 0 | Manual snapshots remain available even when automated backups are disabled. |
| Protect against a complete Region failure | Cross-Region automated backup replication or snapshot copying | A second Region provides a recovery source if the primary Region fails. |
| Preserve an Aurora backup for long-term use | Copy it to a manual DB cluster snapshot | Aurora automated backups are removed under specified lifecycle conditions, while manual snapshots do not expire automatically. |
| Export Aurora snapshot data for external use in AWS storage | Export the snapshot to Amazon S3 | Aurora supports snapshot export to S3. |
| Schedule database patching | Configure the maintenance window | Patching and related maintenance occur during this separate window. |
Common Traps / Misconceptions
- “A restore brings the original DB instance back.” It creates a new instance with a different endpoint.
- “A zero-day retention period means no backups of any kind are possible.” It disables automated backups, but manual snapshots can still be created.
- “Automated backups are permanent.” They are subject to the configured retention period and lifecycle events.
- “Manual snapshots expire with automated backups.” Manual snapshots do not expire automatically.
- “The backup window and maintenance window are interchangeable.” They serve different purposes and should be planned separately.
- “Aurora uses the same backup controls as a standard RDS DB instance.” Aurora retention is managed by the DB cluster, and Aurora automated backups cannot be disabled.
- “A manual snapshot is only an incremental log backup.” It captures the entire database for an RDS instance or the entire Aurora DB cluster.
- “Any DB instance can be backed up at any time.” Automated backups require the instance to be in the
availablestate.
Real-World Engineer / Analyst Notes
- Schedule the backup window during a low-traffic period, but leave enough duration for the backup to complete.
- Treat a restored database as a new infrastructure object: plan for a new endpoint, configuration, connectivity, and application cutover.
- Use automated backups for operational recovery and PITR; use manual snapshots for deliberate milestones and longer retention.
- For regional resilience, verify that backup copies exist in the intended secondary Region rather than assuming a single-Region backup protects against regional loss.
- Before deleting an Aurora cluster or changing its automated backup lifecycle, create a manual cluster snapshot if the data must be retained.
- Include parameter groups and option groups in restoration planning because a restored instance may require configuration beyond the data itself.
- Remember that backups and maintenance can both affect operations, but their schedules and purposes are different.
Quick Reference Summary
- RDS automated backup retention:
0–35 days. - RDS retention
0: Automated backups off; manual snapshots still possible. - RDS transaction-log capture: Approximately every five minutes.
- RDS PITR: Restores to a selected time within retention by replaying logs.
- RDS restore result: New DB instance and new endpoint.
- Manual RDS snapshot: Full database backup; does not automatically expire.
- RDS backup prerequisite: DB instance must be
available. - Aurora backups: Continuous and incremental; cluster-level management.
- Aurora default retention: One day.
- Aurora automated backups: Cannot be disabled.
- Aurora manual snapshot: Full DB cluster snapshot; does not automatically expire.
- Cross-Region options: Replicate automated RDS backups or copy RDS/Aurora snapshots across Regions.
- Separate scheduling concepts: Backup window for backups; maintenance window for patching.
Flashcards
Q: A database must be restored to a time shortly before an accidental data change, not merely to the time of the last snapshot. Which RDS capability should be used and why?
A: Use point-in-time recovery from automated backups. RDS restores a snapshot and replays transaction logs to the selected time within the retention period.
Q: What does setting an RDS automated backup retention period to 0 do, and what remains possible?
A: It disables automated backups. Administrators can still create and retain manual snapshots.
Q: An administrator restores an RDS backup and expects the original DB instance endpoint to remain valid. What is the operational trap?
A: Restore creates a new DB instance with a different endpoint. Applications or connection configuration must be directed to the replacement instance.
Q: When should an RDS backup window generally be scheduled?
A: It should normally be scheduled during a lower-activity period, such as overnight, because backup initiation can cause a brief I/O interruption and add some system load.
Q: How do automated RDS backups support point-in-time recovery?
A: RDS creates a backup snapshot during the backup window and captures transaction logs approximately every five minutes. Recovery restores the snapshot and replays the logs to the requested time.
Q: What is the main retention difference between an automated RDS backup and a manual snapshot?
A: Automated backups are retained only for the configured 0–35-day period, while manual snapshots do not expire automatically and remain until deleted.
Q: A company needs recovery capability if an entire AWS Region fails. Which backup design should be considered?
A: Configure automated RDS backups to replicate to another Region or copy snapshots across Regions. The secondary-Region backup can support creation of a replacement database there.
Q: What state must an RDS DB instance be in for automated backups to occur?
A: The DB instance must be in the available state.
Q: How does Aurora’s backup model differ from standard RDS automated backup controls?
A: Aurora uses continuous, incremental, cluster-level backups, has a default one-day retention period, and does not allow automated backups to be disabled.
Q: An Aurora cluster backup must be retained beyond the automated lifecycle. What should be done?
A: Copy the backup or cluster snapshot to a manual DB cluster snapshot. Manual snapshots do not expire automatically.
Q: What does an Aurora manual snapshot capture?
A: It captures the entire Aurora DB cluster rather than an individual database instance.
Q: When is the maintenance window used instead of the backup window?
A: The maintenance window is used for operating-system and database patching, which may require the database to be taken offline. The backup window is for backup processing.
Practice Questions
Question 1
An operations team wants to recover an RDS database to any point during the past 14 days. It also wants to avoid backup-related activity during peak customer traffic. Which design best meets the requirements?
A. Set retention to 0 and create a snapshot during business hours
B. Set automated backup retention to 14 days and configure an off-peak backup window
C. Create one manual snapshot every 14 days with no backup window
D. Configure only a maintenance window during peak traffic
Correct answer: B
Explanation: Automated backups provide PITR within the retention period, and the backup window can be scheduled during lower activity. A manual snapshot alone does not provide the same transaction-log-based recovery range.
Question 2
A database instance was deleted, but the organization must retain its Aurora backup for several years. What should the engineer do before deletion?
A. Reduce the Aurora retention period to one day
B. Disable Aurora automated backups
C. Copy the backup to a manual DB cluster snapshot
D. Rely on the default automated backup lifecycle
Correct answer: C
Explanation: Aurora automated backups can be removed when the cluster is deleted or when their retention lifecycle ends. A manual cluster snapshot is not subject to automatic expiration.
Question 3
A regional outage has made the primary RDS deployment unavailable. The recovery plan requires creating the database in a secondary Region. Which capability directly supports this plan?
A. Changing the original DB instance’s endpoint
B. Replicating automated backups or copying snapshots to another Region
C. Extending the maintenance window in the primary Region
D. Setting automated backup retention to 0
Correct answer: B
Explanation: Cross-Region automated backup replication and snapshot copying provide backup data in another Region, where a replacement DB instance can be created.
Question 4
An engineer restores an RDS snapshot successfully, but the application still connects to the old database. What is the most likely cause?
A. RDS restores data into the original instance but requires a reboot
B. The backup window was configured incorrectly
C. The restore created a new DB instance with a different endpoint
D. Manual snapshots cannot be used for application recovery
Correct answer: C
Explanation: RDS restore creates a new instance and endpoint. The application connection configuration must be updated or redirected to the restored instance.
WordPress Metadata
Suggested Slug:
amazon-rds-aurora-backup-recovery
Meta Description:
Study automated backups, manual snapshots, point-in-time recovery, maintenance windows, cross-Region protection, and Aurora backup behavior for AWS CloudOps operations.
Tags:
Amazon RDS, Amazon Aurora, AWS Backup, database backups, point-in-time recovery, RDS snapshots, disaster recovery, cross-Region backup, AWS SOA-C03