Top Amazon Elastic Block Store (EBS) Interview Questions (2021) | CodeUsingJava










Most frequently asked Amazon Elastic Block Store (EBS) Interview Questions


  1. What is Elastic Block Store?
  2. What are the benefits of Amazon EBS?
  3. What are the types of EBS Volume?
  4. What is the difference between AWS EFS and EBS?
  5. How can we change default root EBS size in cloudformation?
  6. How to Set Up Amazon EBS?
  7. How to Copy files from one EBS to Another EBS?
  8. How can we transfer data from an EBS volume to a S3 bucket?


What is Elastic Block Store?

Amazon Elastic Block Store (EBS) is a block storage system used to store persistent data. Amazon EBS is suitable for EC2 instances by providing highly available block level storage volumes. It has three types of volume, i.e. General Purpose (SSD), Provisioned IOPS (SSD), and Magnetic. These three volume types differ in performance, characteristics, and cost. Amazon Elastic Block Store (EBS) provides block level storage volumes for use with Amazon EC2 instances. Amazon EBS volumes are off-instance storage that persists independently from the life of an instance.Amazon Elastic Block Store (EBS) is an easy to use, high-performance, block-storage service designed for use with Amazon Elastic Compute Cloud (EC2) for both throughput and transaction intensive workloads at any scale. Amazon EBS is used to provide block level storage volumes for use with AWS EC2 instances, EBS volumes are off instance storage that persists independently from the life of an instance.It is easy to use gives high performance, block storage service designed in using with AWS EC2 for throughput and transaction intensive workloads at any scale.
Elastic Block Store is used for storing persistent data and providing highly available block level storage volumes.It has three types of volume:

General Purpose (SSD)
Provisioned IOPS (SSD)
Magnetic


What are the benefits of Amazon EBS?

Reliable and secure storage - Each of the EBS volume will automatically respond to its Availability Zone to protect from component failure. Secure - Amazon's flexible access control policies allows to specify who can access which EBS volumes. Access control plus encryption offers a strong defense-in-depth security strategy for data. Higher performance - Amazon EBS uses SSD technology to deliver data results with consistent I/O performance of application. Easy data backup - Data backup can be saved by taking point-in-time snapshots of Amazon EBS volumes. Benefits of Amazon EBS are as follows:
  • Reliable and Secure Storage - It automatically respond to its availability zone protecting from component failure.
  • Secure - It allows us to specify access EBS volumes.
  • Higher Performance - Delivers data results with consistent performance.
  • Easy Data Backup - Takes taking point-in-time snapshots of Amazon EBS volumes.

What are the types of EBS Volume?

EBS General Purpose (SSD) This volume type is suitable for small and medium workloads like Root disk EC2 volumes, small and medium database workloads, frequently logs accessing workloads, etc. By default, SSD supports 3 IOPS (Input Output Operations per Second)/GB means 1 GB volume will give 3 IOPS, and 10 GB volume will give 30 IOPS. Its storage capacity of one volume ranges from 1 GB to 1 TB. The cost of one volume is $0.10 per GB for one month. Provisioned IOPS (SSD) This volume type is suitable for the most demanding I/O intensive, transactional workloads and large relational, EMR and Hadoop workloads, etc. By default, IOPS SSD supports 30 IOPS/GB means 10GB volume will give 300 IOPS. Its storage capacity of one volume ranges from 10GB to 1TB. The cost of one volume is $0.125 per GB for one month for provisioned storage and $0.10 per provisioned IOPS for one month. EBS Magnetic Volumes It was formerly known as standard volumes. This volume type is suitable for ideal workloads like infrequently accessing data, i.e. data backups for recovery, logs storage, etc. Its storage capacity of one volume ranges from 10GB to 1TB. The cost of one volume is $0.05 per GB for one month for provisioned storage and $0. 05 per million I/O requests. There are 3 types of EBS Volume:
EBS General Purpose (SSD) volume works for small and medium workloads like Root disc EC2.
Provisioned IOPS (SSD) volume works for the most demanding I/O intensive and large workloads like Hadoop workload.
EBS Magnetic Volumes also known as standard volumes.It works for ideal workloads like data backups and log storage.


What is the difference between AWS EFS and EBS?

AWS EFS is a file system you can mount onto EC2
AWS EBS is a device you can mount onto EC2


How can we change default root EBS size in cloudformation?

Use BlockDeviceMappings to approach
 "BlockDeviceMappings": [
          {
            "DeviceName": "/dev/xvda",
            "Ebs": {
              "VolumeType": "io1",
              "Iops": "300",
              "DeleteOnTermination": "false",
              "VolumeSize": "30"
            }
          }
        ],


How to Set Up Amazon EBS?

Use the following steps for setting up Amazon EBS:
STEP 1 - Create Amazon EBS volume.
STEP 2 - Store EBS Volume from a snapshot.
STEP 3 - Attach EBS Volume to an Instance.
STEP 4 - Detach a volume from Instance.


How to Copy files from one EBS to Another EBS?

For copying files from one EBS to another EBS we need to attach to an instance and allow storing the files on a third storage option by assuming the volumes not attaching to instances.
Follow the following steps for doing the same:
Start a temporary instance.
Use a larger size for higher IO bandwidth.
Attach both EBS volumes to the instance and mount them as, say, /vol1 and /vol2.
Copy the files from /vol1 to /vol2.
Unmount the volumes, detach the EBS volumes, terminate the temporary instance.


How can we transfer data from an EBS volume to a S3 bucket?

To select Users and create an Administrator we can use this code:
aws configure

We have to enter our Access key ID and Secret access key.
aws s3 sync /ebs-directory/ s3://your-bucket