All Products
Search
Document Center

Elastic Compute Service:Copy a snapshot

Last Updated:Sep 01, 2023

You can copy snapshots within the same region or across different regions to back up data. You can encrypt snapshot copies when you copy snapshots.

Note

The Copy and Encrypt Snapshot feature is supported in the China (Hangzhou), China (Shanghai), China (Beijing), China (Shenzhen), China (Hong Kong), and Singapore regions.

Prerequisites

  • A snapshot is created. For information about how to create snapshots, see Create a snapshot of a disk.

  • Key Management Service (KMS) is activated before you copy a snapshot to create an encrypted snapshot copy. For more information, see Activate KMS.

Use scenarios

Snapshot replication is applicable to the following scenarios:

  • DevOps scenarios

    You can copy snapshots to start business in new regions or migrate business systems to new regions. This helps you reduce O&M costs and improve data availability.

  • Inter-region or cross-region backup scenarios

    Snapshot replication helps meet the requirements for compliance audit and improvement of business reliability. In the event of a disaster, you can restore your business systems by using new snapshots in another region. This reduces recovery time objectives (RTOs) and recovery point objectives (RPOs).

The following table describes the differences between copy scenarios and copy and encryption scenarios.

Scenario

Usage

Security

Procedure

Copy scenarios

Unencrypted snapshots are copied across regions to back up data or create disks based on the unencrypted snapshot copies in the destination regions.

Unencrypted snapshots can be accessed directly.

Copy scenarios

Copy and encryption scenarios

  • Unencrypted snapshots are copied within the same region to create encrypted snapshot copies.

  • The encrypted snapshot copies that reside in the same region as the source snapshots can use different encryption keys.

  • Unencrypted snapshots are copied to different regions to create the encrypted snapshot copies. You can use the encrypted snapshot copies to back up data or create disks in the destination regions.

  • The encrypted snapshot copies that reside in different regions from the source snapshots can use different encryption keys.

Encrypted snapshots can only be accessed by using encryption keys. This can prevent the sensitive snapshot data from unauthorized access. Encrypted snapshots provide a higher level of security, ensuring better protection for data privacy and security.

Copy and encryption scenarios

Precautions

When you copy snapshots, take note of the items described in the following table.

Item

Description

Replication fee

  • After a snapshot is copied to a destination region, a snapshot copy is generated in the region, which incurs a data transfer fee. You are charged the data transfer fee for snapshot replication. In addition, you are charged for the snapshot copy based on the snapshot size and storage duration. For more information, see Snapshots.

    Note

    The first time a disk snapshot is copied, all data stored in the disk is copied. All subsequent copies of the snapshot in the same region are incremental copies. Snapshots are billed based on snapshot sizes. Incremental copies can significantly reduce the sizes of snapshots to be copied.

  • You are charged for encryption keys that are used to encrypt snapshots. For more information, see Billing of KMS.

Replication efficiency

It is much faster to copy a snapshot than an image, and snapshot replication can be used to bypass capacity constraints. If you want to copy a large image, we recommend that you copy its associated snapshot to the destination region and create an image based on the snapshot copy in the region.

  • For information about how to copy a snapshot, perform the following procedure described in this topic.

  • For information about how to create an image, see Create a custom image from a snapshot.

Others

Tags added to source snapshots cannot be copied together with the source snapshots.

New snapshot (snapshot copy) limit

The ID of a snapshot copy is different from that of its source snapshot. The snapshot copy cannot be used to restore disks created by the source snapshot.

Procedure

  1. Log on to the ECS console.

  2. In the left-side navigation pane, choose Storage & Snapshots > Snapshots.

  3. In the upper-left corner of the top navigation bar, select a region. 地域

  4. Find the snapshot that you want to copy and click Copy Snapshot in the Actions column.

  5. In the Copy Snapshot dialog box, configure parameters based on your copy scenarios.

    Copy scenarios

    Parameter

    Required

    Description

    Copy Type

    Yes

    Select Copy.

    Destination Region

    Yes

    Select a destination region. The region must be different from the region where the source snapshot resides.

    Snapshot Name

    Yes

    Enter a name for the new snapshot.

    Description

    No

    Enter a description for the new snapshot. We recommend that you enter information such as the purpose and environment of the new snapshot to facilitate subsequent management.

    Tag

    No

    Add tags to the new snapshot. The tags can facilitate subsequent management of the new snapshot.

    Note

    When you copy a snapshot, the tags of the source snapshot cannot be copied together to the snapshot copy.

    Copy and encryption scenarios

    Parameter

    Required

    Description

    Copy Type

    Yes

    Select Copy and Encrypt.

    Note

    Snapshots that are taken for encrypted disks are also encrypted. If the snapshot that you want to copy is an encrypted snapshot, you must select Copy and Encrypt.

    Destination Region

    Yes

    Select a destination region. The region can be the same region as the source snapshot or a different region.

    Encryption Key

    Yes

    Select a key to use to encrypt the new snapshot. Select Default Service CMK or a custom customer master key (CMK) from the drop-down list.

    • Default Service CMK: the default key generated by Key Management Service (KMS).

    • Custom CMK: a key that you created in KMS by using the bring your own key (BYOK) feature. For more information, see Create a CMK.

    Note

    The first time you select an encryption key, click Go to Authorize and follow on-screen tips to attach the AliyunECSDiskEncryptDefaultRole role to grant Elastic Compute Service (ECS) access to your KMS resources.

    Snapshot Name

    Yes

    Enter a name for the new snapshot.

    Description

    No

    Enter a description for the new snapshot. We recommend that you enter information such as the purpose and environment of the new snapshot to facilitate subsequent management.

    Tag

    No

    Add tags to the new snapshot. The tags can facilitate subsequent management of the new snapshot.

    Note

    When you copy a snapshot, the tags of the source snapshot cannot be copied together to the snapshot copy.

  6. Confirm and select the message related to snapshot replication fees, and then click Confirm to copy the source snapshot.

    Note

    When the new snapshot is being created in the destination region, Processing is displayed in the Progress column. You can click Delete Snapshot in the Actions column to cancel the snapshot copying task.

    1. In the upper-left corner of the top navigation bar, select the destination region. Then, on the Snapshots page, find the new snapshot.

    2. Choose image.png > Delete Snapshot in the Actions column.

  7. (Optional) Switch to the destination region and view the information of the new snapshot.

    新快照
    • When the snapshot copying task is complete, Successful is displayed in the Progress column corresponding to the new snapshot, as shown in the red box marked ① in the preceding figure.

    • Move the pointer over Snapshot Copy in the Creation Method column corresponding to the new snapshot, as shown in the red box marked ② in the preceding figure. The ID of the source snapshot is displayed.

    • Check the Encrypted/Unencrypted column to determine whether the new snapshot is encrypted, as shown in the red box marked ③ in the preceding figure.

What to do next

You can use the new snapshot to perform the following operations:

  • Create ECS instances or disks.

    Create ECS instances or disks based on the new snapshot in the destination region to quickly restore data. For more information, see Create a disk from a snapshot.

  • Create a custom image.

    If the source snapshot is a system disk snapshot, create a custom image from the new snapshot in the destination region and then use the custom image to create ECS instances that contain the application environments from the source snapshot. For more information, see Create a custom image from a snapshot.