Amazon EBS is like a hard drive in the cloud that provides persistent block storage volumes for use with Amazon EC2 instances.\n\nThese volumes can be attached to your EC2 instances and allow you to create a file system on top of these volumes, run a database, server or use them in any other way you would use a block device.\n\n**What is a block storage volume? \n**A block storage volume works similarly to a hard drive. You can store any type of files on it or even install a whole Operating System on it.\n\nEBS volumes are placed in an availability zone, where they are automatically replicated to protect data loss from the failure of a single component.\n\nBut since they are replicated only across a single availability zone you may lose data if the whole availability zone goes down, which is really rare.\n\n### EBS Volume Types\n\nThere are five types of EBS volumes. You can use whatever works best for your use case.\n\n#### 1\\. General Purpose SSD (gp2)\n\nThis is the volume that EC2 chooses by default as the root volume of your instance. It provides a balance of both price and performance.\n\nSSD stands for Solid State Drive which is multiple times faster than HDD (Hard Disk Drive) for small input/output operations.\n\nHaving it as the root volume for your instances can significantly improve the performance of your server.\n\nIts performance is measured in IOPS (Input-Output Operations per second), means how many input and output operations our server can per second.\n\nThese EBS volumes provide a ratio of 3 IOPS per GB with the ability to burst up to 3000 IOPS for extended periods of time. They support up to 10,000 IOPS and 160 MB/s of throughput.\n\n1 IOPS — 256 KB/s of read or write operation. \nIOPS refer to operations on blocks that are up to 256 KB in size.\n\n#### 2\\. Provisioned IOPS SSD (io1)\n\nThis is the fastest and most expensive EBS volume. They are designed for I/O intensive applications such as large Relational or NoSQL databases.\n\nThe size of this volume ranges from 4 GiB to 16 TiB and the IOPS ranges from 100 IOPS to 32,000 IOPS.\n\nThey support up to 500 MB/s of throughput and can be used as root volume for an EC2 instance.\n\nHere, you are charged for the provisioned IOPS along with the storage space of your volume.\n\n#### 3\\. Throughput Optimized HDD (st1)\n\nThese are low-cost magnetic storage volumes which define performance in terms of Throughput.\n\nThese are designed for large, sequential workloads like Big Data, Data warehouses, and log processing. You will probably use these volumes for your Hadoop cluster.\n\nThey provide throughput of up to 500 MB/s and cannot be used as root volume for an EC2 instance.\n\n#### 4\\. Cold HDD (sc1)\n\nThese are even cheaper magnetic storage than Throughput Optimized. They are designed for large, sequential cold workloads like a file server.\n\nThey are good for infrequently accessed workloads and provide throughput of up to 250 MB/s.\n\nThey also cannot be used as root volumes.\n\n#### 5\\. Magnetic (standard)\n\nThese are previous generation magnetic drives that are suited for workloads where data is accessed infrequently.\n\nTheir size can be up to 1 TiB and on average they provide a throughput of 100 MB/s.\n\nThese can be used as root volumes for EC2 instances.\n\n### Snapshots\n\nYou can take snapshots of your EBS volumes that are a point in time images of your volumes (like copies of your volumes).\n\nYou can then use these snapshots to create new EBS volumes with different volume types and attach them to your instances.\n\nSnapshots can be used as a backup of your volumes. They are stored in Amazon S3 so you automatically get the high durability of S3.\n\nSnapshots can only be accessed from the EC2 dashboard.\n\n### Some Facts\n\n1. An EBS volume can only be mounted to a single EC2 instance at a time. If you want to assign a volume to multiple EC2 instances, check out Amazon Elastic File System (EFS).\n2. EBS root volumes of your default AMIs cannot be encrypted. You can use third-party tools like BitLocker to do that.\n3. Volumes other than root volume can be encrypted.\n4. By default, root volumes are deleted on termination of an EC2 instance.\n5. You can copy snapshots between AWS regions to create volumes in different regions.\n6. The size of an EBS volume can be up to 16 TiB.\n\nThanks for reading this article. If you liked it, please give a few claps so it reaches more people who would love it!