Create an Amazon EBS volume
You can create an Amazon EBS volume and then attach it to any EC2 instance in the same Availability Zone. If you create an encrypted EBS volume, you can only attach it to supported instance types. For more information, see Supported instance types.
If you are creating a volume for a high-performance storage scenario, you should make sure
to use a Provisioned IOPS SSD volume (io1
or io2
) and attach it to an instance with enough bandwidth to
support your application, such as an EBS-optimized instance. The same advice holds for
Throughput Optimized HDD (st1
) and Cold HDD (sc1
) volumes. For more information, see Amazon EBS–optimized instances.
Note
If you create a volume for use with a Windows instance, and it's larger than 2048 GiB
(or is a volume that's smaller than 2048 GiB but might be increased later), ensure that you
configure the volume to use GPT partition tables. For more information, see Windows support for hard disks that are larger than 2 TB.
Empty EBS volumes receive their maximum performance the moment that they are available and do not require initialization (formerly known as pre-warming). However, storage blocks on volumes that were created from snapshots must be initialized (pulled down from Amazon S3 and written to the volume) before you can access the block. This preliminary action takes time and can cause a significant increase in the latency of an I/O operation the first time each block is accessed. Volume performance is achieved after all blocks have been downloaded and written to the volume. For most applications, amortizing this cost over the lifetime of the volume is acceptable. To avoid this initial performance hit in a production environment, you can force immediate initialization of the entire volume or enable fast snapshot restore. For more information, see Initialize Amazon EBS volumes.
Important
If you create an io2
volume with a size greater than 16
TiB or
with IOPS greater than 64,000
in a Region where EBS Block Express is supported,
the volume automatically runs on Block Express. io2
Block Express volumes can be attached to supported
instances only. For more information, see io2
Block Express volumes.
Methods of creating a volume
-
Create and attach EBS volumes when you launch instances by specifying a block device mapping. For more information, see Launch an instance using the new launch instance wizard and Block device mappings.
-
Create an empty EBS volume and attach it to a running instance. For more information, see Create an empty volume below.
-
Create an EBS volume from a previously created snapshot and attach it to a running instance. For more information, see Create a volume from a snapshot below.
Create an empty volume
Empty volumes receive their maximum performance the moment that they are available and do not require initialization.
You can create an empty EBS volume using one of the following methods.
Create a volume from a snapshot
Volumes created from snapshots load lazily in the background. This means that there is no need to wait for all of the data to transfer from Amazon S3 to your EBS volume before the instance can start accessing an attached volume and all its data. If your instance accesses data that hasn't yet been loaded, the volume immediately downloads the requested data from Amazon S3, and then continues loading the rest of the volume data in the background. Volume performance is achieved after all blocks are downloaded and written to the volume. To avoid the initial performance hit in a production environment, see Initialize Amazon EBS volumes.
New EBS volumes that are created from encrypted snapshots are automatically encrypted. You can also encrypt a volume on-the-fly while restoring it from an unencrypted snapshot. Encrypted volumes can only be attached to instance types that support EBS encryption. For more information, see Supported instance types.
You can create a volume from a snapshot using one of the following methods.