8 Crucial Performance Tips for Amazon EFS

DZone 's Guide to

8 Crucial Performance Tips for Amazon EFS

In this article, you will learn what AWS EFS is, how to test drive it, and seven performance tips to keep your EFS workloads running.

· Performance Zone ·
Free Resource

Amazon EFS enables you to build cloud-based network file systems for Linux-based workloads and applications. Because EFS structure and functionality are similar to on-premise infrastructure, you can easily transfer existing files. Before moving any workloads, you should test drive EFS, and after the move, you should perform performance optimization on a regular basis. 

In this article, you will learn what AWS EFS is, how to test drive it, and seven performance tips to keep your EFS workloads running smoothly and efficiently.

What Is AWS EFS?

Elastic File System (EFS) is a storage service available in AWS that you can use to recreate a network file system in the cloud. It is designed for Linux-based workloads and applications and is based on Network File System v 4 (NFSv4). You can use it with other AWS services as well as on-premises resources. 

In comparison to other storage services, AWS EFS offers functionality that is closest to existing file storage on-premises. With it, you can easily transfer your existing file structure and continue to access files as you would if files remained on-premises. You can do this either by hosting applications in EC2 and attaching instances to EFS or by using EFS as a stand-alone file system.

In EFS you have the choice of two access options. Standard Access is designed for your basic workloads, it offers lower latency access in exchange for a higher cost. Infrequent Access is designed for less used files that you need to store for a longer period. It offers a lower cost in exchange for higher latency. Regardless of which access tier you choose, EFS is a pay-for-use service, charging you only for the storage and transfer bandwidth that you are actually using. 

How to Test Drive EFS

Before transferring files to EFS, you may want to test drive the service. This can help you gain familiarity with configurations, gauge how performance compares to your current system, and help you better estimate the level of resources you need. You can accomplish this by demoing the free tier.

The free EFS tier offers 5 GB of storage for 12 months. It is easiest to try if you already have an existing EC2 instance that you can mount the file system to. If you do not, there is also a free tier available for EC2 that is good for 750 hours which should be enough time for testing. 

To set up your demos, you can create resources through either the command-line interface (CLI) or the Management Console. For a walkthrough of how to set up and connect these services using the Management Console, you can refer to the AWS documentation here. 

During your test drive, make sure to simulate your use of the file system as closely as possible to what you’ll actually need. This may mean attaching multiple instances, writing files with single and multiple threads, or accessing data from both Standard and Infrequent access tiers. 

7 Amazon EFS Performance Tips

Once you have decided to adopt EFS services, you can shift your focus to ensuring that you are getting the greatest return on your investment. The following tips can help you ensure that your EFS performance is optimized and that you are not paying for resources you don’t need. 

1. Monitor Your EFS Burst Credits

Burst credits are one of the most overlooked aspects of EFS. These credits are designed to give your performance a temporary boost during times of high traffic. However, credits only last for a brief amount of time and take a while to recover, meaning you might see sudden drops in performance if you run out. 

Each EFS volume starts with a .5MB/s transfer rate. This can be supplemented by burst credits for throughput up to 100MB/s, lasting for 7.2 minutes. The only way to increase these numbers is to increase the amount of data you are storing in your EFS volumes. This is true up to 10GB at which point you always get maximum performance. 

2. Use Asynchronous Write Operations

Asynchronous write operations enable you to cut down on the latency of write operations by eliminating part of the data transfer trip. When you enable asynchronous writes, you buffer your data to an EC2 instance before it is written to EFS. 

Keep in mind, however, that this can affect the consistency of your data. It is not helpful if you require file systems to remain in real-time synchronization. 

3. Don’t Run Applications From EFS

EFS is not designed to run or host applications. If you try to accomplish this, you will see poor performance. This is because EFS cannot perform the large file reads or manage the speed that is required for managing codebases or deploying applications. 

Instead, you should host and run applications from EBS and EC2 and reserver EFS for accessory files. For example, content to be served. Restricting services to their intended purpose helps ensure you get the performance you expect.

4. Monitor Average I/O Throughput

Keeping track of your average I/O throughput can help you identify bottlenecks and areas where you can compress storage. For example, if multiple files are required by the same application, uniting these files into a single file can reduce throughput demands. In contrast, frequently requesting many small files can quickly exceed your throughput limitations.

When you reduce the number of file requests possible, you can help keep your I/O operations per second down. This helps reduce your latency overhead and keeps it within performance boundaries. 

5. Manage Backups Carefully

Creating backups in EFS can be a challenge because there is currently no snapshot feature available. Instead, you must either use AWS Backup service or perform EFS-to-EFS backups. Whichever method you use, take care that you only retain the backup copies that you need and be mindful of how much storage backups require.

Additionally, when creating backups, try to schedule the creation for your off-hours and rate-limit copying. This can help you avoid impacting the performance of your standard operations and can prevent accidentally burning through your burst credits.

6. Choose the Right Performance Mode

When using EFS, you have the choice of two performance modes:

  • General Purpose — Provides lower throughput in exchange for lower latency operations. It is designed for standard tasks, such as web-hosting or content management. This is the default performance setting. 
  • Max I/O — Provides higher throughput in exchange for higher latency. It is designed for compute-heavy tasks, such as media processing or big data analysis.

7. Leverage Simultaneous Connections 

EFS is designed to allow massively parallel connections and can be simultaneously attached to up to a thousand EC2 instances. This enables you to distribute your applications and workloads and can help you significantly increase performance. When configuring these connections, just keep in mind that you are still limited by the total throughput and transfer speed of your volumes. 


Amazon EFS can be a powerful tool, but like many self-configured services, it requires regular optimization. To avoid overhead, you should regularly monitor your EFS burst credits and average I/O throughput. To ensure optimal performance, you can use asynchronous write operations and avoid running applications from EFS. 

To avoid billing surprises, you should manage backups carefully, and choose the right performance mode for your workloads. Finally, you can boost performance by leveraging simultaneous connections. Remember that, in most cases, performance is not an exact science. When optimizing performance, setting up (automated and/or human) continual loops can help you ensure you cover all aspects.

aws, aws efs, monitoring, performance

Published at DZone with permission of Ilai Bavati . See the original article here.

Opinions expressed by DZone contributors are their own.

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}