EFS

EFS is a file-level, fully managed, storage provided by AWS (Amazon Web Services) that can be accessed by multiple EC2 instances concurrently.

Just like the AWS EBS, EFS is specially designed for high throughput and low latency applications.

EFS

EFS Working Principle

EFS can be created using the EC2-Instance where it will be created in a specific region and distributed across multiple availability zones for the purpose of high availability and durability.

Once the EFS is created you need to set up mount targets which will provide the connectivity to your EFS file system.

EFS Workflow

EFS Storage Classes

  1. Standard

  • This is the default storage class for EFS.

  • The user is only charged for the amount of storage used.

  • This is recommended for storing frequently accessed files.

  1. Infrequent Access

  • Cheaper storage space.

  • Recommended for rarely accessed files.

  • Increased latency when reading or writing files.

Performance Modes in EFS

  1. General Purpose

  • Offers low latency.

  • Supports a maximum of 7000 IOPS.

  • As a cloud watch metric, you can view the amount of IOPS your architecture uses and can switch to Max IOPS if required.

  1. Max I/O

  • This is recommended when EFS needs over 7000 IOPS

  • Theoretically, this mode has an unlimited I/O speed.

Throughput Modes in EFS

  1. Burst Mode

Allows 100MBPS of burst speed per TB of storage.

  1. Provisioned Mode

Users can decide the max burst speed of the EFS but are charged more when speeds go beyond the default limit.

Advantages

EFS is scalable and elastic where you can scale the EFS depending on the data that is going to be stored. The scaling is done automatically.

Multiple instances in AWS can access the EFS simultaneously. It makes it easy to share data across instances.

Within the same region, the EFS replicates the data to the multiple availability zones.

EFS supports a wide range of POSIX file system features, making it compatible with many Linux-based applications.

Limitations of EFS

EFS only supports the Network File System (NFS) protocol, so it can only be mounted and accessed by devices that support NFS.

EFS has a maximum file size of 47.9 TB.

EFS has a maximum throughput of 1000 MB/s per file system and a maximum of 16,000 IOPS per file system.

EFS has a maximum number of files and directories that can be created within a single file system, which is determined by the size of the file system. For example, a 1 TB file system can support up to about 20 million files and directories.

Create EFS in AWS

  1. Login on the AWS account.

  2. Verify the region in which the infrastructure will be created. In the upper right corner, click on the button with the city name and choose the region, in this case, it will be Virginia.

  1. Select the Amazon EFS service.

  1. Click on “Create file system”.

  1. Select the VPC and the private subnet. Press “Next Step”.

  1. Assign a name to the EFS and choose the performance mode, it is recommended to keep the value by default. Then, press “Next Step”.

  1. Review the configurations and create the EFS.

  1. Verify the correct creation of the amazon EFS.

Verify in the Security Group, that the value of the origin (source) of the traffic is the private network or 0.0.0.0/0.

  1. Connect to the instance via SSH.

  2. Mount EFS in the instance.

Click on “Amazon EC2 mount instructions” and follow the commands provided and connect EFS storage.

Last updated