shiichan

Amazon S3 Files: mount your S3 bucket like a file system!

Hi everyone, it's me, Shii-chan! Today I get to share a launch that turns S3 into a file system, and I'm pretty excited about it.

AWS Blog aws.amazon.com

What was announced?

Over on the AWS Blog, Amazon S3 Files just landed. It lets you mount an S3 bucket as an NFS v4.1+ file system, so you can read and write S3 objects as regular files and directories from Amazon EC2, Amazon ECS, Amazon EKS, and AWS Lambda.

The story so far

Until now, S3 was object storage that you reached through APIs like GetObject and PutObject. That meant existing tools and apps built around opening files by path couldn't talk to S3 directly. You often had to copy data to local disk first and deal with the extra steps.

What changes

Once you mount S3 Files, you can work with your S3 data using the usual file commands like ls, cat, and mkdir. You can share data across clusters without duplicating it, and the file system stays in sync with the bucket automatically (writes show up within minutes, reads within seconds). Active data gets around 1ms latency, with caching handled for you.

Dive Deep

Under the hood, S3 Files uses Amazon EFS as a high-performance storage backend. It does intelligent pre-fetching based on access patterns and gives you fine-grained control over caching only metadata versus full file data. Byte-range reads help keep data transfer and costs down, and consistency follows the NFS close-to-open model, which makes concurrent access easier to reason about.

On security, access control goes through IAM, traffic is encrypted with TLS 1.3, and data at rest can use SSE-S3 or your own KMS key. POSIX permissions are checked against object metadata, too. Managing permissions at both the file system and object level is covered in the getting started guide. For monitoring, you get Amazon CloudWatch metrics plus AWS CloudTrail for management events.

Setup is quick: in the S3 console, go to File systems and choose Create file system, then enter your bucket name. Check the mount target IDs and mount it on EC2 like this.

sudo mount -t s3files fs-xxxxxxxx:/ /mnt/s3files

It's available in all commercial AWS Regions. Costs apply to the data storage portion, small file reads, all writes, and the S3 requests made during synchronization. The S3 pricing page has the numbers, and the S3 Files documentation has the rest.

Wrap-up

  • Amazon S3 Files lets you mount an S3 bucket as an NFS v4.1+ file system
  • Read and write S3 data with regular file commands from EC2, ECS, EKS, and Lambda
  • Amazon EFS powers the backend, with pre-fetching, caching control, and byte-range reads for speed and cost
  • IAM, TLS 1.3, and SSE-S3 / KMS keep it secure, and it's available in all commercial Regions
  • Perfect if you want to reach data sitting in S3 straight from your existing file-based apps and workloads!