Introducing Amazon EBS Volume Clones: Create an immediate copy of your EBS volumes | Amazon Web Services

As someone who worked in Sun Microsystems, where the ZFS was invented, I have always loved working with storage systems that offer immediate volume copies for my development and testing needs.

Today I am excited that I can share that AWS brings similar abilities to Amazon Elastic Block Store (Amazon EBS) with the launch of Amazon EBS Volume Clones, new skills that allow you to create immediate copies of EBS points in the same availability zone.

Many customers must make copies of their production data to support development and test activities in a separate non -production environment. Until now, this process has required an EBS image (stored in Amazon Simple Storage Service (Amazon S3)) and then creating a new volume from this image. Although this approach works, the process creates operational direction due to multiple steps.

With the Amazon EBS Volume Clones, you can now create copies of your EBS volumes with a single click on the API or by clicking on the console. Copied volumes are available in seconds and provide immediate access to your data with a single -digit millisecond latency. As a result, volume clones are particularly useful for quick setting of testing environment with production data or creating temporary copies of databases for development purposes.

Let me show you how voice clones work
For this post I created a small instance of Amazon Elastic Compute Cloud (Amazon EC2) with connected volume. I created a file in a root file system with a command echo "Hello CopyVolumes" > hello.txt.

To start a copy, I opened the browser on the AWS Management console and walked EC2, Elastic trade with blocks, Bundles. I choose the volume I want to copy.

Note that only encrypted volumes can be copied at the time of publication of this post.

On Action Menu, I will select Volume choice.

Copy Volume - Initiate

I will also choose the details of the target volume. Can i change that Typical volume and adjust Size, IOPSand Permeability parameters.parameters. I choose Volume Start the volume clone operation.

Copy the volume - parameters

The copied bundle enters into Creation Indicate and will be available in seconds. Then I can connect it to the EC2 instance and start using it immediately.

The data blocks are copied from the source bundle and written in a copy of the volume in the background. The bundle remains in Initialization Indicate until the process is completed. Can i watch his progress using describe-volume-status API. The initialization operation does not affect the power of the source volume. I can normally use this during the copy process.

I like that the copied volume is available immediately. I don’t have to wait to complete its initialization. During the initialization phase, my copied volume provides performance based on the lowest Z: base line of 3,000 IOP and 125 MIB/s, provided by the power of the source or the power -to -copy.

Upon completion of the initialization, the copied volume becomes fully independent of the source volume and adds its fully provided performance.

Copy the volume - initializationI can alternatively use the AWS command line interface (AWS cli) to start a copy:

aws ec2 copy-volumes                          \
     --source-volume-id vol-1234567890abcdef0 \
     --size 500                               \
     --volume-type gp3

After creating a copy of the volume, I attach it to the EC2 instance and attach it. I can check the file I created at the start is present.

I first connect the bundle from my laptop using attach-volume command:

aws ec2 attach-volume \
         --volume-id 'vol-09b700e3a23a9b4ad' \
         --instance-id 'i-079e6504ad25b029e'   \
         --device '/dev/sdb'

Then I join the instance and enter the following commands:

$ sudo lsblk -f
NAME          FSTYPE FSVER LABEL UUID                                 FSAVAIL FSUSE% MOUNTPOINTS
nvme0n1                                                                              
├─nvme0n1p1   xfs          /     49e26d9d-0a9d-4667-b93e-a23d1de8eacd    6.2G    22% /
└─nvme0n1p128 vfat   FAT16       3105-2F44                               8.6M    14% /boot/efi
nvme1n1                                                                              
├─nvme1n1p1   xfs          /     49e26d9d-0a9d-4667-b93e-a23d1de8eacd                
└─nvme1n1p128 vfat   FAT16       3105-2F44     

$ sudo mount -t xfs /dev/nvme1n1p1 /data

$ df -h
Filesystem        Size  Used Avail Use% Mounted on
devtmpfs          4.0M     0  4.0M   0% /dev
tmpfs             924M     0  924M   0% /dev/shm
tmpfs             370M  476K  369M   1% /run
/dev/nvme0n1p1    8.0G  1.8G  6.2G  22% /
tmpfs             924M     0  924M   0% /tmp
/dev/nvme0n1p128   10M  1.4M  8.7M  14% /boot/efi
tmpfs             185M     0  185M   0% /run/user/1000
/dev/nvme1n1p1    8.0G  1.8G  6.2G  22% /data

$ cat /data/home/ec2-user/hello.txt 
Hello CopyVolumes

What to know
Volume clones make copies in the same availability zone as your source bundle. Using encrypted bundles, you can create copies and the size of your copy must be straight or greater than the source volume.

Volume clones create copies of your bundles, just like images. For the consistency of the application, you must pause the I/O Application before creating a copy. For example, with PostgreSQL databases you can use pg_start_backup() and pg_stop_backup() He writes to the pause and creates a consistent copy. You can use the operating system level on Linux with XFS xfs_freeze To temporarily suspend and restore access to the file system and ensure that all updates in the cache are written to the disk.

Although voice clones create copies of point-in-time, it complements rather than replaces EBS images for backup purposes. EBS images remain a recommended backup and data protection solution against AZ and volume. Images provide Amazon additional backups S3 with 11 nine durability compared to volume clones that maintain EBS volume (99.999% for IO2, 99.9% for other types of volume). Consider using loud clones specifically for testing and developmental scenarios where you need immediate access to volume copies.

Copied volumes exist independently of their source bundles and continue to cause standard EBS volumes while deleting them. If you want to effectively manage costs, implement management rules to identify and remove copied volumes that are no longer needed for your development or test activities.

Prices and availability
Volume clones support all EBS volumes and work with volumes in the same AWS account and availability zone. This new ability is available in all AWS commercial regions, selected local zones and AWS Govcloud (USA).

For prices, you charge you a one -time GIB fee of the source volume at the start and standard EBS price for a new volume.

Particularly valuable volume clones are continuous integration for work load and scenarios. For example, you can quickly create a copy of your production database to test new features or problems with problems without affecting your production environment or waiting for the hydration of Amazon S3 data.

If you want to start with the Amazon EBS Volume Clones, visit the Amazon EBS section on the console, or see the EBS documentation. I look forward to hearing how you use this ability to improve development procedures.

– seb

Leave a Comment