EC2 Create EBS Volume

Amazon Web Services (AWS)’s Elastic Compute Cloud (EC2) is a commercial web service that allows users to rent virtual computers. Using AWS EC2’s cloud infrastructure, you can build powerful servers in the cloud. This service completely eliminates the need to set up and invest in hardware, enabling you to deploy your apps quickly. With AWS EC2, you can set up servers, configure networking and security, and manage storage.

Amazon Machine Image (AMI) is your virtual machine’s software configuration. It includes elements such as operating system, application server, and applications. 

An instance is nothing but a virtual machine. AWS offers a variety of instance types, which are various combinations of CPU, storage, memory, networking capacity, and so on.  

Amazon Elastic Block Store (EBS) provides block level storage volumes that you can use with your EC2 instances. You can attach an EBS volume to any running EC2 instance and can use it as primary storage for databases, file systems, or any app that requires frequent updates and quick access to the data.

Using this action, you can create an EBS volume that you can later attach to any EC2 instance in the same Availability Zone. To do this, you first need to configure the action, and select the required AWS connection. Select the region in which you want to create the new EBS volume. Next, enter the Availability Zone in which you want to create the volume. Remember that if you want to attach this EBS volume to an EC2 instance, it should be in the same availability zone.

While configuring the action, you need to enter a few other details, which are mentioned below:

  • Volume type: The type of the new EBS volume could be gp2 (general purpose SSD), io1 (provisioned IOPS SSD), or standard (magnetic).
  • Size: Here, you need to mention the size (in GB) of the new EBS volume. For standard volumes, you can select from 1–1024 GB. For gp2, the range is 1–16384 Gb, and for io1, it is 4–16384 GB.
  • Encrypted: You also need to specify where the volume would be encrypted or not. It is important to note that encrypted EBS volumes can be attached to only EC2 instances that support EBS encryption.
  • IOPS: If you are creating a new io1 volume, then you need to mention the number of I/O operations per second ratio.
  • KMS Key ID: Here, mention the full ARN of the AWS Key Management Service (KMS) master key to use when creating the encrypted volume.
  • Snapshot ID: Mention the ID of the snapshot from which you want to create the volume.
  • Dry Run: Perform a dry run before the volume is actually created. This will check if you have the required permissions to perform this action.
  • ec2-create-ebs-volume

Once you have entered all the required details, click on ‘Done’ and run the flow. This will create a new EBS volume.

Output:
  • output-arrow aws-128 EC2 Create EBS volume
    • left-triangle VolumeId string
    • left-triangle Size number
    • left-triangle SnapshotId string
    • left-triangle AvailabilityZone string
    • left-triangle State string
    • left-triangle VolumeType string
    • left-triangle Encrypted boolean