Amazon provides 5 different EBS Volume Types. Based on the performance needs of the application one can choose the appropriate storage type. Each of these different volume types varies in price. At a high level, they fall into 2 categories –
- SSD backed volumes
- HDD backed volumes
There are 2 SSD backed EBS volume types –
General Purpose SSD (gp2) –
- General Purpose SSD, also know as gp2 volumes are cost-effective storage solution providing optimal performance for a wide range of application workloads.
- EBS gp2 volumes have 3IOPS/GB as a set amount of IOPS based on volume size. For example – A 50 GB volume has 150 IOPS as the baseline. Similarly, a 1 TB volume will have 3000 IOPS as the baseline. This can go up to a maximum of 10,000 IOPS for gp2 ( which is 3.33 TB volume). Which means any volume greater than 3.33 TB will get a maximum of 10K IOPS per volume.
- The packet sizes for SSD are capped at 256 KB. Throughput is calculated as the product of the IOPS and the packet size.
- The minimum volume size for gp2 is 1 GB and can go up to a maximum of 16 TB
- Each volume receives an initial I/O credit balance of 5.4 million I/O credits, which is enough to sustain the maximum burst performance of 3,000 IOPS for 30 minutes.
- Volumes earn I/O credits at the baseline performance rate of 3 IOPS per GB of volume size.
- When your volume requires more than the baseline performance I/O level, it draws on I/O credits in the credit balance to burst to the required performance level, up to a maximum of 3,000 IOPS.
- Volumes larger than 1,000 GB have a baseline performance that is equal or greater than the maximum burst performance, and their I/O credit balance never depletes.
- If the gp2 volume depletes all the I/O credit balance, then the volume remains at the baseline IOPS performance.
Few important formulas –
Burst Duration = (Credit Balance)/ [(Burst IOPS) – 3(Volume size in GiB)]
Throughput in MiB/s = (Volume size in GiB) X (IOPS per GiB) x (I/O size in KiB)