Create Amazon EBS snapshots
You can create a point-in-time snapshot of an EBS volume and use it as a baseline for new volumes or for data backup. If you make periodic snapshots of a volume, the snapshots are incremental—the new snapshot saves only the blocks that have changed since your last snapshot.
Snapshots occur asynchronously; the point-in-time snapshot is created immediately, but the
status of the snapshot is pending
until the snapshot is complete (when all of the
modified blocks have been transferred to Amazon S3), which can take several hours for large initial
snapshots or subsequent snapshots where many blocks have changed. While it is completing, an
in-progress snapshot is not affected by ongoing reads and writes to the volume.
You can take a snapshot of an attached volume that is in use. However, snapshots only
capture data that has been written to your Amazon EBS volume at the time the snapshot command is
issued. This might exclude any data that has been cached by any applications or the operating
system. If you can pause any file writes to the volume long enough to take a snapshot, your
snapshot should be complete. However, if you can't pause all file writes to the volume, you
should unmount the volume from within the instance, issue the snapshot command, and then
remount the volume to ensure a consistent and complete snapshot. You can remount and use your
volume while the snapshot status is pending
.
To make snapshot management easier, you can tag your snapshots during creation or add tags afterward. For example, you can apply tags describing the original volume from which the snapshot was created, or the device name that was used to attach the original volume to an instance. For more information, see Tag your Amazon EC2 resources.
Snapshot encryption
Snapshots that are taken from encrypted volumes are automatically encrypted. Volumes that are created from encrypted snapshots are also automatically encrypted. The data in your encrypted volumes and any associated snapshots is protected both at rest and in motion. For more information, see Amazon EBS encryption.
By default, only you can create volumes from snapshots that you own. However, you can share your unencrypted snapshots with specific AWS accounts, or you can share them with the entire AWS community by making them public. For more information, see Share an Amazon EBS snapshot.
You can share an encrypted snapshot only with specific AWS accounts. For others to use your shared, encrypted snapshot, you must also share the CMK key that was used to encrypt it. Users with access to your encrypted snapshot must create their own personal copy of it and then use that copy. Your copy of a shared, encrypted snapshot can also be re-encrypted using a different key. For more information, see Share an Amazon EBS snapshot.
Multi-volume snapshots
You can create multi-volume snapshots, which are point-in-time snapshots for all, or some, of the volumes attached to an instance.
By default, when you create multi-volume snapshots from an instance, Amazon EBS creates snapshots of all the volumes (root and data (non-root)) that are attached to the instance. However, you can choose to create snapshots of a subset of the volumes that are attached to the instance.
You can tag your multi-volume snapshots as you would a single volume snapshot. We recommend you tag your multiple volume snapshots to manage them collectively during restore, copy, or retention. You can also choose to automatically copy tags from the source volume to the corresponding snapshots. This helps you to set the snapshot metadata, such as access policies, attachment information, and cost allocation, to match the source volume.
After the snapshots are created, each snapshot is treated as an individual snapshot. You can perform all snapshot operations, such as restore, delete, and copy across Regions or accounts, just as you would with a single volume snapshot.
Multi-volume, crash-consistent snapshots are typically restored as a set. It is helpful to identify the snapshots that are in a crash-consistent set by tagging your set with the instance ID, name, or other relevant details.
After creating your snapshots, they appear in your EC2 console created at the exact point-in-time.
If any one snapshot for the multi-volume snapshot set fails, all of the other snapshots
display an error status and a createSnapshots
CloudWatch event with a result of
failed
is sent to your AWS account. For more information, see
Create snapshots (createSnapshots).
Amazon Data Lifecycle Manager
You can create snapshot lifecycle policies to automate the creation and retention of snapshots of individual volumes and multi-volume snapshots of instances. For more information, see Amazon Data Lifecycle Manager.
Considerations
The following considerations apply to creating snapshots:
-
When you create a snapshot for an EBS volume that serves as a root device, we recommend that you stop the instance before taking the snapshot.
-
You cannot create snapshots from instances for which hibernation is enabled, or from hibernated instances. If you create a snapshot or AMI from an instance that is hibernated or has hibernation enabled, you might not be able to connect to a new instance that is launched from the AMI, or from an AMI that was created from the snapshot.
-
Although you can take a snapshot of a volume while a previous snapshot of that volume is in the
pending
status, having multiplepending
snapshots of a volume can result in reduced volume performance until the snapshots complete. -
There is a limit of one
pending
snapshot for a singlest1
orsc1
volume, or fivepending
snapshots for a single volume of the other volume types. If you receive aConcurrentSnapshotLimitExceeded
error while trying to create multiple concurrent snapshots of the same volume, wait for one or more of thepending
snapshots to complete before creating another snapshot of that volume. -
When a snapshot is created from a volume with an AWS Marketplace product code, the product code is propagated to the snapshot.
-
When creating multi-volume snapshot sets from instances, you can specify up to 127 data (non-root) volumes to exclude. The maximum number of Amazon EBS volumes that you can attach to an instance depends on the instance type and instance size. For more information, see Instance volume limits.
Create a snapshot
To create a snapshot from the specified volume, use one of the following methods.
Create a multi-volume snapshot
When you create a multi-volume snapshot set from an instance, you can choose whether to copy the tags from the source volume to the corresponding snapshot. You can specify whether to create a snapshot of the root volume. You can also specify whether to create snapshots of all the data (non-root) volumes that are attached to the instance, or whether to create snapshots of a subset of those volumes.
Considerations
-
Multi-volume snapshots support up to 128 Amazon EBS volumes for each instance, which includes the root volume and up to 127 data (non-root) volumes. The maximum number of Amazon EBS volumes that you can attach to an instance depends on the instance type and instance size. For more information, see Instance volume limits.
To create a snapshot from the volumes of an instance, use one of the following methods.
If all of the snapshots complete successfully, a createSnapshots
CloudWatch event
with a result of succeeded
is sent to your AWS account. If any one snapshot for
the multi-volume snapshot set fails, all of the other snapshots display an error status and a
createSnapshots
CloudWatch event with a result of failed
is sent to your
AWS account. For more information, see Create snapshots (createSnapshots).
Work with EBS snapshots
You can copy snapshots, share snapshots, and create volumes from snapshots. For more information, see the following: