Amazon Elastic File System (EFS) is a fully managed, scalable, elastic file storage service for use with AWS Cloud services and on-premises resources.
It provides a shared file system accessible by multiple EC2 instances simultaneously, unlike EBS or Instance Store, which are limited to single-instance attachment.
Key features:
kaptaindevops runs a web application across multiple EC2 instances in a cluster.
He uses EFS to store shared configuration files, logs, and media assets, ensuring all instances access the same files in real-time.
| Feature | EFS | EBS | Instance Store |
|---|---|---|---|
| Persistence | Persistent | Persistent | Temporary |
| Shared Access | Multiple EC2 instances | Single EC2 instance | Single EC2 instance |
| Performance | Scales with demand, high throughput | SSD/HDD types, fixed IOPS | Very fast, local to host |
| Elasticity | Automatic scaling | Manual resizing | Fixed size at launch |
| Durability | Across AZs | Within AZ | Lost if instance stops/terminates |
| Use Case | Shared storage, media, logs, clusters | Databases, boot volumes, transactional data | Cache, scratch data, temp processing |