The Amazon EBS (Amazon Elastic Block Store) is a scalable, easy-to-use block storage service.
Paired with EC2, it is designed for high-performance and transaction-intensive workloads.
It achieves this by providing volumes that are mounted as disks on EC2 instances for onward usage with frequently changing data.
These volumes are flexible helping you keep your data available, encrypted, and stored for backups.
To meet the different needs of its users, AWS makes available two major categories of EBS Volume for EC2 instances: SSD-based and HDD-based volumes. You can have a look at the major differences between the different types of volumes here and here.
Today, we will be examining two main SSD volumes:
- io2 Block Express, the new, performance-optimized EBS volume perfect for high-efficiency transactional applications like the SAP HANA, Microsoft SQL Server, and SAS Analytics.
- gp3, the general purpose, cost-optimized EBS volume perfect for transactional applications such as virtual desktops and test environments.
The io2 Block Express EBS Volume
Amazon announced the general availability of the io2 Block Express EBS Volume for EC2 instances, the io2 Block Express volume allows users to get the best-performing block storage when deploying applications and databases that require the most intense I/O performance. Previously, this was not straightforward as developers had to attach multiple EBS volumes to a single instance to meet the desired throughput, IOPS, and capacity level.
Compared to the traditional io2 volumes that offer up to 64K IOPS capability, 1GB/s throughput, and single-digit millisecond latency, the io2 Block Express volume quadruples the capacity by providing up to 256,000 IOPS, 4 GB/s, and sub-millisecond latency.
The gp3 EBS Volume
The new gp3 general SSD EBS Volume for EC2 instances is an upgrade to the widely used gp2 volume. It allows users to provision storage capacity for the same workloads at a lower cost.
Like the gp2 EBS volume, gp3 has the same volume size, max throughput/instance, and max IOPS/Volume and Instance.
However, the gp3 has 4x the max throughput per volume (1 GB/s) than that of gp2 ( 250 MB/s).
With the previous gp2 volume, users had to configure a bigger storage volume if they needed a higher IOPS and throughput.
This is not the case with the pay-as-you-go format of the gp3, users don’t need to provide more capacity to increase performance and pay for only additional resources used.
With the gp3 EBS volume, users can run medium-sized databases such as Oracle, MySQL, Cassandra, and other latency-sensitive applications at lower storage costs compared to gp2.
AWS cost optimization: gp3 and io2 block express EBS Volumes
There are several factors one has to consider before choosing the best EBS volume. Whatever the choice, cost optimization — reducing cloud spending without compromising performance has to be the goal.
Cost and Performance
For applications requiring the highest performance with throughput requirements greater than 16,000 IOPS, the io2 block express volume is the obvious choice. The Max IOPS/Volume volume for the gp3 volume is 16,000 whilst the io2 block express can go as high as 256,000.
Price per provisioned IOPS per month (Performance)
$0.065 up to 32,000 IOPS
$0.046 from 32,001 to 64,000 IOPS
$0.032 > for greater than 64,000 IOPS
For companies that need moderately high performance — where the majority of AWS users fall in — the gp3 is the best EBS volume for them.
They, however, have to make sure that their applications require 16,000 IOPS or less and that the throughput volume doesn’t exceed 1000 MB/s.
Choosing the gp3 for such scenarios results in;
- Significant cost savings. The storage price for gp3 is $0.08/GB-month compared to the io2 block express of $0.125/GB-month. The gp3 also comes with some free IOPS volumes which means companies that select gp3 stand to incur even lesser provisioning costs.
- No drop in performance. The durability differences ( 99.8% — 99.9% for gp3 and 99.999% for io2 block express) are insignificant for the aforementioned performance levels.
Migration
Amazon has made migrating from one EBS Volume to another quite easy. It can be done while in an in-use state and result in little or no downtime i.e. without detaching the volume or restarting the instance.
There are two recommended ways of performing the migration.
1. Elastic Volume
An existing feature of EBS, Elastic Volume enables you to change EBS volume or type without incurring an additional cost. Your costs however start rising once the newly selected volume starts running. There are however some requirements and limitations which you have to pay attention to.
For example, to migrate to a General purpose SSD volume like gp3 with Elastic Volume, follow the steps below:
- Open the Amazon EC2 console and select the volume you want to modify