How do I use snapshots or clones with Storage Gateway to recover my volume data?

5 minute read
0

I want to use snapshots or clones to recover my data to an AWS Storage Gateway volume.

Short description

To recover cached volumes, you can either use Amazon Elastic Block Store (Amazon EBS) snapshots or clones. However, it's a best practice to use an Amazon EBS snapshot to maintain specific recovery points in time, or directly recover to an Amazon EBS volume.

Note: Amazon EBS volume types gp2, gp3, or io1 can support up to 16 TiB snapshots. The io2 express volume type can support up to a maximum of 32 TiB. For more information, see Quotas for volumes.

Resolution

Take a snapshot of your Storage Gateway cached volume

Complete the following steps:

  1. Open the Storage Gateway console.
  2. In the navigation pane, choose Volumes, and then select the volume that you want to take a snapshot of.
  3. Choose Actions, and then choose Create EBS snapshot.
  4. In Snapshot description, enter a name for the snapshot, and then choose Create EBS snapshot.
  5. Wait for the snapshot's Status to change from Pending to Available.
    Note: The time it takes for the snapshot to be available depends on the size of the volume. If you're using an on-premises Storage Gateway appliance, then the time depends on the size of the volume and the available network bandwidth.
  6. (Optional) To take snapshots on a reoccurring schedule, complete the following steps:
    Choose Actions.
    Choose Edit snapshot schedule.
    Choose a start time and recurrence.
    Enter a description, and then choose Save.
    Note: It's a best practice to activate a snapshot schedule at the required frequency.

Recover the Storage Gateway cached volume from the EBS snapshot

Complete the following steps:

  1. Open the Amazon Elastic Compute Cloud (Amazon EC2) console.
  2. In EBS snapshots, select the name of your snapshot.
  3. Choose the Description tab, and then note the snapshot ID.
  4. In the navigation pane, for AWS Region, select the Region that your snapshot is in.
    Note: (Optional) to restore the snapshot to a volume in a different Region, first copy the snapshot to the destination Region. Then, restore the snapshot to a volume in the destination Region.
  5. Open the Storage Gateway console.
  6. In the navigation pane, choose Volumes, and then choose Create volume.
  7. On the Create volume page, select the gateway that you want to use for the volume, and then enter the capacity. 
    Note: Enter a capacity that's the same size as or larger than the EBS snapshot.
  8. In Volume contents, choose Based on EBS snapshot, and then enter the EBS snapshot ID.
  9. For iSCSI target, enter a name, and then choose Create Volume.
  10. (Optional) In Configure CHAP authentication, you can choose Skip. However, It's a best practice to have a highly secure iSCSI authentication.

Use the snapshot to create a new Amazon EBS volume

Complete the following steps:

  1. Open the Amazon EC2 console.
  2. In the navigation pane, choose Volumes, and then choose Create Volume.
  3. On the Create Volume page, for Volume Type, choose General Purpose SSD or Provisioned IOP SSD.
    Note: If you choose cold HHD, throughput optimized HDD, or Magnetic, then you might experience performance issues.
  4. Choose Snapshot ID, and then for Size (GiB), enter the size.
    Note: If you specify both a volume size and a snapshot ID, then the size must be equal to or greater than the snapshot size.
  5. For IOPS, enter the maximum number of input/output operations per second (IOPS) for your use case.
  6. Select your Availability Zone, and then choose Create volume.
    Note: You can attach Amazon EBS volumes only to EC2 instances in the same Availability Zone.

(Optional) Create a clone from the most recent recovery point

If you choose to use a clone to recover the new volume, then you don't need to create and store EBS snapshots beforehand. Storage Gateway automatically creates recovery points for your cached volumes. However, the recovery point might not have the expected data because Storage Gateway recovers data from one recovery point in time. To view the last recovery point in time, review the TimeSinceLastRecoverPoint metric in Amazon CloudWatch. For more information, see Cloning a cached volume from a recovery point.

For recoveries, it might be faster to create and access the clone. With a clone, Storage Gateway instantly creates the new volume, and then copies the data from the initial volume in the background.

To create a clone from the most recent recovery point, complete the following steps:

  1. Open the Storage Gateway console.
  2. In the navigation pane, choose Volumes, and then choose Create volume.
  3. In Gateway, choose the Volume gateway, and then enter the capacity.
  4. In Volume contents, choose Clone from last volume recovery point.
  5. In Source volume, select the volume that you want to clone.
  6. In iSCSI target, enter a name, and then choose Create volume.
  7. (Optional) In Configure CHAP authentication, you can choose Skip. However, it's a best practice to have a highly secure iSCSI authentication.
  8. In the navigation pane, choose Volumes, and then verify that the new volume is available and ready to use.

Related information

Create Amazon EBS snapshots

What is Volume Gateway?

AWS OFFICIAL
AWS OFFICIALUpdated 21 hours ago