Storage
Amazon EFS
Serverless, elastic file system, accessible through the NFS protocol, that grows and shrinks automatically as you add or delete files. It lets many Amazon EC2 instances, containers, or AWS Lambda functions share the same files without provisioning capacity; it is not supported on Windows instances.
Exam phrases that point here
«a shared file system accessed by multiple Linux instances at the same time»
Amazon EFS is a managed NFS file system: many instances mount it at the same time and see the same files, with file locking included.
When not: If the clients are Windows and use SMB, the answer is usually Amazon FSx for Windows File Server. If the disk is used by a single instance (for example, a self-managed database), Amazon EBS fits.
«mount the same storage from instances in multiple Availability Zones»
A Regional EFS file system stores data across several zones and supports a mount target in each one, so instances in different zones share the same data and the file system survives the loss of a zone.
When not: If you choose EFS One Zone to save money, the data lives in a single zone and does not survive its loss. And if what you need is a block disk for an instance, Amazon EBS cannot be shared across zones.
«file storage that grows and shrinks automatically, without provisioning capacity»
EFS is elastic: you pay for what you store and do not have to reserve a size in advance.
When not: If the data is read and written as objects over HTTP or an API (website images, a data lake), Amazon S3 is usually more suitable and cheaper. If you need an extreme-performance parallel file system for HPC, think of Amazon FSx for Lustre.
«reduce the cost of files that are rarely accessed, without changing the application»
With lifecycle management, EFS automatically moves files that are not being used to the Infrequent Access or Archive classes; the application still sees them at the same path.
When not: If the data is objects in a bucket, the equivalent tool is Amazon S3 lifecycle rules. And if cold files are read frequently and latency matters, it is best to have them return to Standard on first access.
«persistent, shared storage for Lambda functions or containers on Fargate»
Both AWS Lambda and Amazon ECS (with EC2 or Fargate) can mount an EFS file system, and the data survives each invocation or task.
When not: If you only need temporary space during execution, the service's own ephemeral storage is enough. If the data is stored as objects, Amazon S3 is the simplest option.
Often paired with
- Amazon EC2
- AWS Lambda