SysPadLessons › storage lessons › EBS Volume

How EBS Volume works

Network-attached block storage for a single EC2 instance. Capped by BOTH provisioned IOPS and MB/s - small random I/O hits the IOPS wall, large sequential I/O hits the throughput wall. gp3 decouples IOPS from size.

EBS is the hard drive for your EC2 instance, except it’s attached over the network and lives a life of its own. It behaves like a local disk (you format it, mount it, the OS sees blocks), but it persists independently of the instance and can be backed up, resized, and restored. The catches: it belongs to one instance, in one AZ.

What you will learn

A disk for one instance

EBS provides block storage: raw volumes the operating system treats like a physical disk (partition, format, mount). A volume attaches to a single EC2 instance at a time and is the natural home for an OS, a database’s files, or anything needing low-latency random read/write. (A niche exception, Multi-Attach on io1/io2, lets a few same-AZ instances share one volume with a cluster-aware filesystem.)

Persistent, but AZ-bound

A volume’s lifecycle is separate from the instance: stop or terminate the instance (if not set to delete-on-termination) and the volume keeps your data. But an EBS volume lives in a single Availability Zone, you can only attach it to instances in that same AZ.

Volume types

EBS offers types for different needs: gp3 (general-purpose SSD, balanced, provisionable IOPS/throughput), io2 (high-performance SSD for demanding databases), and HDD types st1 (throughput-optimised) and sc1 (cold, cheapest) for big sequential workloads.

gp3 for most workloads; io2 for IOPS-hungry databases; st1/sc1 for large logs/big-data scans.

Snapshots

A snapshot is a point-in-time backup of a volume stored in S3, taken incrementally (only changed blocks after the first). From a snapshot you restore a volume, copy it to other AZs/regions, or stamp out many identical volumes.

Flashcards

What kind of storage is EBS, and who can use one volume?
Block storage (a disk to the OS), attached to one EC2 instance at a time, ideal for OS disks and database files.
Does an EBS volume die with its instance?
No (unless delete-on-termination is set), it persists independently and can be reattached, within the same AZ.
How do you get an EBS volume’s data into another AZ or region?
Take a snapshot (to S3) and create a new volume from it in the target AZ/region, volumes themselves are AZ-bound.
gp3 vs io2 vs st1/sc1?
gp3 = balanced general SSD; io2 = high-IOPS SSD for demanding DBs; st1/sc1 = throughput/cold HDD for big sequential data.
What is an EBS snapshot and where does it live?
A point-in-time, incremental backup of a volume stored in S3; used to restore or copy volumes across AZs/regions.

Sources

Open the SysPad canvas · Official EBS Volume documentation

Other storage lessons