fbpx
Search
Close this search box.

AWS Snapshots: Understanding and Using EBS and RDS Snapshots

How AWS Snapshots Work: top use cases and best practices
AWS provides two snapshot types: EBS and RDS. Each serves specific purposes, enabling users to back up and restore data for different AWS storage services.
Share This Post

What Are AWS Snapshots? 

AWS offers two primary types of snapshots: EBS Snapshots and RDS Snapshots. EBS snapshots are used to back up block storage volumes attached to EC2 instances, while RDS snapshots are designed for backing up relational databases within RDS. Both snapshot types play a critical role in ensuring data durability and availability, providing a straightforward way to restore data in the event of corruption, failures, or other disruptions.

What Are AWS EBS Snapshots?

AWS EBS snapshots are backups of EBS volumes, which are block storage devices used with Amazon EC2 instances. These snapshots capture the state of an EBS volume at a specific point in time and are stored in Amazon S3. The first snapshot of a volume is a full backup, capturing all the data on the volume. Subsequent snapshots are incremental, storing only the blocks that have changed since the previous snapshot.

What Are AWS RDS Snapshots?

AWS RDS snapshots are backups of Amazon RDS databases. These snapshots capture the entire database, including the engine configuration and data, at a specific point in time. Unlike EBS snapshots, which are primarily concerned with block storage, RDS snapshots focus on the backup and recovery of entire database instances. Like EBS snapshots, RDS snapshots are stored in Amazon S3.

This is part of a series of articles about AWS disaster recovery.

In this article:

How EBS Snapshots Work: Snapshot Lifecycle

The lifecycle of an Amazon EBS snapshot involves several stages, from creation to deletion:

  1. Creation: The snapshot creation process starts with a request from the user or an automated policy. AWS captures the current state of the EBS volume at a block level. However, AWS does not automatically quiesce the application or the operating system running on the EC2 instance during the snapshot creation process. This means that unless you stop or freeze the application, the snapshot may not be application-consistent (i.e., there may be in-flight data that isn’t captured in the snapshot).
    • Tip: For mission-critical applications like databases, it’s important to ensure application-consistent backups. Using N2WS Backup & Recovery, you can create application-consistent snapshots that quiesce applications before capturing the snapshot, ensuring that your backups are fully consistent and recoverable.
  2. Storage: While AWS snapshots are priced and billed separately from Amazon S3, they are not stored in S3 as user-accessible objects. Instead, AWS uses an internal storage system for EBS snapshots that is optimized for incremental backups and pricing purposes. They remain there until they are either deleted by the user or as part of a lifecycle policy. During this phase, snapshots can be used to create new EBS volumes, shared with other AWS accounts, or copied to different regions.
  3. Incremental backups: For subsequent snapshots of the same volume, AWS only saves the blocks that have changed since the last snapshot. This incremental approach reduces storage costs and speeds up the snapshot process.
  4. Retention and deletion: Snapshots can be retained indefinitely, but to manage costs, users often implement retention policies. AWS provides lifecycle management tools that automate the deletion of snapshots based on user-defined policies, such as retaining snapshots for a specific number of days or keeping a fixed number of the most recent snapshots.
  5. Restoration: When a snapshot is used to create a new EBS volume, AWS reconstructs the volume using the data stored in the snapshot. However, the new volume is not automatically attached to an EC2 instance. It is created as a standalone EBS volume, which you must manually attach to an instance to make it usable. While this can restore the data, it adds steps to recover the full operational state of an instance, especially in production environments.
    • Tip: With N2WS Backup & Recovery, you can automate the entire recovery process, including not only the restoration of EBS volumes but also all associated network configurations—such as security groups, elastic IPs, and VPC settings—so you can rapidly restore to a fully-functioning, production-ready state. This ensures you meet your RTO requirements and minimize downtime, making N2WS an ideal solution for fast, complete disaster recovery.

How RDS Snapshots Work

The lifecycle of an Amazon RDS snapshot involves several stages, similar to EBS snapshots but tailored for relational database storage:

  1. Creation: An RDS snapshot can be created manually by the user or automatically by setting up automated backup schedules. When a snapshot is initiated, AWS captures the state of the entire RDS database instance, including the database engine configuration, schema, and data at that specific point in time. It’s important to note that RDS snapshots do not inherently ensure application-level consistency—for highly transactional databases, you may need to pause writes to achieve a consistent backup state.
  2. Storage: RDS snapshots are stored using an internal AWS mechanism that utilizes Amazon S3 infrastructure but does not incur S3 storage pricing. These snapshots remain in storage until they are deleted by the user or through automated lifecycle management. Users can specify retention policies to manage how long these snapshots are kept.
  3. Incremental backups: While automated RDS backups after the first snapshot are incremental, capturing only the changes since the last backup, manual RDS snapshots are always full backups. This means that manual snapshots will store the complete state of the database instance at the time of creation, regardless of any previous snapshots.
    1. Clarification: If you’re relying on manual snapshots for backups, remember that they’re always full, so keep an eye on storage costs, especially for large databases. Automating the backup process with N2WS can optimize storage usage and help manage incremental backups effectively.
  4. Retention and deletion: Users can manage snapshot retention to control costs and compliance. RDS provides automated backup retention settings, which can be adjusted to retain snapshots for a specified number of days. Manual snapshots, however, must be explicitly deleted by the user or through automated scripts.
  5. Restoration: When restoring from an RDS snapshot, a new database instance is created using the data stored in the snapshot. This ensures the new instance reflects the exact state of the database at the time the snapshot was taken. Restoration can be done in the same AWS region or to a different region, providing flexibility for disaster recovery and backup strategies. However, the restored instance is not configured to immediately take over production workloads. You’ll need to configure network settings, access controls, and possibly rename the restored instance.
    1. Tip: N2WS Backup & Recovery accelerates recovery by not only automating the instance restoration process but also cloning all associated configurations. This allows you to bring the database back online in a production-ready state within minutes, reducing downtime and ensuring continuity.
  6. Copying and sharing: RDS snapshots can be copied to other AWS regions, which is useful for cross-region disaster recovery. Additionally, users can share manual snapshots with other AWS accounts, enabling collaborative access or handoff of database snapshots.

Related content: Read our guide to AWS disaster recovery plan

Tips from the Expert
Picture of Sebastian Straub
Sebastian Straub
Sebastian is the Principle Solutions Architect at N2WS with more than 20 years of IT experience. With his charismatic personality, sharp sense of humor, and wealth of expertise, Sebastian effortlessly navigates the complexities of AWS and Azure to break things down in an easy-to-understand way.

Amazon Snapshots Pricing 

Amazon EBS Snapshots Pricing

Amazon EBS snapshots offer flexible pricing based on storage tier and data usage. The two primary tiers are the Standard tier and the Archive tier, each with distinct cost structures.

Standard tier pricing:

  • Storage cost: $0.05 per GB-month.
  • Restore cost: Free.

The Standard tier snapshots are stored incrementally, which means you are billed only for the blocks of data that have changed since the last snapshot. This approach minimizes storage costs and is suitable for regularly accessed data.

Archive tier pricing:

  • Storage cost: $0.0125 per GB-month.
  • Restore cost: $0.03 per GB of data retrieved.

Archive tier snapshots are full copies of your EBS volume data. Unlike the Standard tier, the Archive tier requires you to pay for all data blocks stored, not just the changed ones. This tier is for long-term storage of snapshots that are infrequently accessed. 

There is a minimum retention period of 90 days, and any snapshots deleted or restored before this period ends will incur a pro-rated charge for the remaining days. Additional costs apply when retrieving data from the Archive tier.

Amazon RDS Snapshots Pricing

RDS snapshots are stored in Amazon S3, and the cost is based on the total storage size of the snapshot. 

  • Storage cost: $0.095 per GB-month, which means you are billed based on the amount of storage your snapshot consumes each month. This cost applies to both manual snapshots and automated backups that AWS generates.
  • Cost for exporting snapshot data: $0.010 per GB of snapshot size. The data can be exported to Amazon S3 in Parquet format, which is a storage-efficient format that facilitates quicker data access and analysis. This lets you save on storage and improve performance for analytics workloads.

Primary Use Cases for AWS Snapshots 

Data Backup

Snapshots are effective for data backup. They offer a reliable means to secure important data managed by EC2 instances or RDS databases. Regularly scheduled snapshots create backup points, allowing organizations to recover entire systems or individual files rapidly in case of data loss or corruption.

Organizations leverage snapshots to meet regulatory compliance, maintaining a history of data states. This allows retrieval of data from specific points in time, assisting in audits, legal inquiries, and other compliance requirements. The incremental nature of snapshots also optimizes storage use, making data backup more cost-efficient.

Disaster Recovery

In the event of catastrophic failures, snapshots enable rapid restoration of services with minimal downtime. By regularly updating snapshots, businesses can ensure that their recovery point objectives (RPOs) and recovery time objectives (RTOs) are met.

Snapshots can be taken across multiple regions, providing an added layer of redundancy. This cross-region capability ensures that data can be restored even if an entire AWS region suffers an outage. The automated snapshot features in AWS enable a seamless disaster recovery strategy, minimizing manual intervention and errors.

Dev/Test

Snapshots play an important role in development and testing environments. They allow for the creation of consistent environments quickly and efficiently. Developers can create snapshots of production environments and replicate them for testing, ensuring that tests are conducted on accurate data representations.

This process significantly speeds up development cycles, reduces errors, and enhances productivity. By utilizing snapshots, teams can experiment with different configurations and recover easily from any unintended changes or errors, ensuring a smooth and continuous development pipeline.

Tip: With N2WS, you can schedule regular snapshots of your production environment and easily create clones of those environments for dev/test purposes. This eliminates the need for manual intervention and provides a streamlined way to spin up or tear down environments as needed, maximizing team efficiency.

Best Practices for Using AWS Snapshots 

Regularly Schedule Snapshots

Regular scheduling of snapshots is crucial to maintain up-to-date backups and ensure data recovery capabilities. For EBS volumes, AWS provides the Data Lifecycle Manager (DLM), which allows you to automate the creation and retention of EBS snapshots according to specified schedules. This ensures that critical data is backed up regularly without manual intervention, reducing the risk of data loss due to human error.

For RDS databases, AWS supports automated backups, where you can define the backup window and retention period. Automated snapshots can be scheduled to occur daily, capturing the state of the database at regular intervals. This regular scheduling is essential for maintaining up-to-date backups, especially for databases with frequent data changes.

Implement Retention Policies

Retention policies help manage storage costs and ensure compliance by controlling how long snapshots are retained. For EBS snapshots, retention policies can be configured using the DLM, allowing you to retain snapshots for a specific number of days or keep a certain number of the most recent snapshots. This approach helps prevent snapshot sprawl and reduces costs by automatically deleting older, unnecessary snapshots.

For RDS snapshots, automated backup retention settings can be specified, determining how long automated backups are kept before deletion. Manual RDS snapshots, however, are retained until explicitly deleted by the user. Implementing clear retention policies for both types of snapshots ensures that storage is used efficiently, and compliance requirements are met without incurring unnecessary costs.

Use Tags for Organization

Organizing snapshots using tags is a best practice that simplifies management and improves visibility. EBS snapshots can be tagged with metadata such as environment (e.g., production, development), project name, or cost center. This tagging helps in tracking and managing resources, making it easier to identify and filter snapshots based on specified criteria.

RDS snapshots also support tagging, allowing you to categorize and identify snapshots based on various attributes. Tags can enable automation scripts for snapshot management and provide a clear view of which snapshots belong to which databases or projects. Using a consistent tagging strategy ensures that snapshots are well-organized and easy to manage.

Encrypt Snapshots for Security

Encrypting snapshots adds an essential layer of security, protecting sensitive data from unauthorized access. EBS snapshots can be encrypted using AWS Key Management Service (KMS). When creating an encrypted EBS snapshot, you can specify a customer-managed key (CMK) to control access to the data. Encrypting snapshots ensures that data at rest is secure and complies with security standards.

For RDS snapshots, encryption can also be applied using AWS KMS. You can encrypt snapshots of encrypted RDS databases or even choose to encrypt unencrypted snapshots during the copy process. Encrypting RDS snapshots ensures that both the database and its backups are secure, providing comprehensive protection for sensitive data.

Tip: N2WS Backup & Recovery supports cross-region and cross-account backup and recovery of encrypted snapshots, which AWS Backup cannot perform. This is especially important for disaster recovery strategies requiring encrypted data to be restored in different regions or accounts.

Monitor Snapshot Costs

Monitoring snapshot costs is critical to prevent unexpected expenses and optimize budget allocations. For EBS snapshots, keep track of the number of snapshots, their sizes, and the associated costs using AWS Cost Explorer and AWS Budgets. By analyzing snapshot usage patterns, you can identify opportunities to delete obsolete snapshots or move less frequently accessed snapshots to lower-cost storage tiers like the EBS Snapshot Archive.

RDS snapshot costs can also be monitored using AWS billing tools. Regularly reviewing snapshot storage costs allows you to adjust retention policies, delete outdated manual snapshots, and manage automated backup settings to align with budget constraints. Additionally, setting budget alerts can help you stay within your desired spending limits, avoiding unexpected charges at the end of the month.

Tutorial: Creating a AWS EBS Snapshot

Create a Snapshot

Creating an AWS EBS snapshot involves capturing a point-in-time image of an EBS volume, which can be used for data backup, recovery, and replication. 

This is the basic process:

  1. Open the Amazon EC2 Console: In the AWS Console, navigate to Amazon EC2. In the navigation pane, click on Snapshots, then select Create snapshot.
  2. Choose resource type: Under Resource type, select Volume.
  3. Select the volume: In the Volume ID dropdown, choose the EBS volume you wish to snapshot.
  4. Encryption status: The Encryption field shows if the selected volume is encrypted. If encrypted, the snapshot will use the same encryption key. If not, the snapshot will remain unencrypted.
  5. Add Description (Optional): Provide a brief description for the snapshot to help identify it later.
  6. Add Tags (Optional): To assign custom tags to the snapshot, click Add tag and enter the key-value pairs. You can add up to 50 tags.
  7. Create Snapshot: Click Create snapshot to initiate the process.

Creating Multi-Volume Snapshots

For instances with multiple attached volumes, you can create a multi-volume snapshot set. This is useful for ensuring consistent backups of all attached volumes.

  1. Open the Amazon EC2 Console: In the AWS Console, navigate to Amazon EC2. In the navigation pane, click on Snapshots, then select Create snapshot.
  2. Choose resource type: Under Resource type, select Instance.
  3. Provide Description: Enter a description for the snapshots. This description applies to all snapshots in the set.
  4. Include/Exclude Volumes: By default, the root volume and all attached data volumes are included. To exclude the root volume, check Exclude root volume. To exclude specific volumes, check Exclude specific data volumes, then deselect the volumes you do not want to snapshot.
  5. Copy Tags (Optional): To automatically copy tags from the source volumes to the snapshots, check Copy tags from source volume.
  6. Add Additional Tags (Optional): Click Add tag to enter key-value pairs for additional custom tags. You can add up to 50 tags.
  7. Create Snapshot: Click Create snapshot to start the multi-volume snapshot creation process.

During creation, the snapshots are managed together. If any snapshot fails, all related snapshots will also fail. You can monitor progress and status using CloudWatch Events.

For advanced users looking to automate the snapshot process, instead of manually scripting with AWS CLI or SDK, consider using N2WS Backup & Recovery. N2WS allows you to automate scheduled snapshots and lifecycle management across multiple AWS accounts and regions, without the need for custom scripts. This not only reduces manual effort but also provides a user-friendly interface for managing backups, ensuring faster recovery times and simplified disaster recovery planning.

Go Beyond AWS Snapshots with N2WS Backup for AWS

AWS Snapshots provide robust backup, disaster recovery, and cost management capabilities, but managing them efficiently is crucial for cloud operations. N2WS Backup & Recovery for AWS offers an all-in-one solution that automates cross-region snapshots, optimizes storage costs, and simplifies compliance. Download our free Disaster-Proof Backup Checklist to ensure your data backup strategy isn’t missing any critical components.

Next step

The easier way to automate aws snapshots

Allowed us to save over $1 million in the management of AWS EBS snapshots...

N2WS vs AWS Backup

Why chose N2WS over AWS Backup? Find out the critical differences here.

N2WS in comparison to AWS Backup, offers a single console to manage backups across accounts or clouds. Here is a stylized screenshot of the N2WS dashboard.