Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep...

39
© 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Darryl S. Osborne AWS - Storage Specialist Solutions Architect May 18, 2017 Deep Dive on Amazon Elastic File System

Transcript of Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep...

Page 1: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

© 2015, Amazon Web Services, Inc. or its Affiliates. All rights reserved.

Darryl S. OsborneAWS - Storage Specialist Solutions Architect

May 18, 2017

Deep Dive on Amazon Elastic File System

Page 2: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Amazon Elastic File System (EFS)

Provides simple, scalable, highly available & durable file storage in the cloud

Petabyte scale file system distributed across an unconstrained number of storage servers in multiple Availability Zones (AZs)

Elastic capacity, automatically growing & shrinking as you add & remove files

Page 3: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Amazon Elastic File System (EFS)

Standard file system interface & semanticsShared storageHighly available & highly durableConsistent low latencyStrong read-after-write consistencyElastic capacityFully managed

Page 4: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Cloud Data Migration

Direct Connect

Snow* data transport

family

3rd Party Connectors

TransferAcceleration

StorageGateway

Kinesis Firehose

Object

Amazon GlacierAmazon S3

Block

Amazon EBS (persistent)

Amazon EC2 Instance Store

(ephemeral)File

Amazon EFS

The AWS Storage Portfolio

Page 5: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

What customers are using EFS for today

Web servingContent management

Analytics

Media and Entertainment workflows

Workflow managementHome directories

Container storage

Database backups

Page 6: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Shared File Solutions in the Cloud… before EFS

3rd Party Software

Do It Yourself

3rd Party Hardware in AWS Direct Connect locations

Page 7: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Do It Yourself – NFS Architecture

NFSClients

NFSServer

Volume Volume

NFSClients

NFSServer

Volume Volume

NFSClients

NFSServer

Volume Volume

Page 8: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Do It Yourself – NFS Architecture

q Launch, patch, monitor, & pay for EC2 instancesq Create, attach, monitor, & pay for provisioned EBS

volumesq Create, maintain, and monitor auto scaling groupq Install, patch, monitor, & pay for* file system softwareq Configure, maintain, monitor, & pay for file system data

intra/inter-AZ replication• IOPS for replication are still IOPS

q Configure DNS for client HA access to inter-AZ NFS fleet

Page 9: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Do It Yourself

Page 10: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Do It Yourself NFS Architecture

NFSClients

NFSServer

Volume Volume

NFSClients

NFSServer

Volume Volume

NFSClients

NFSServer

Volume Volume

Page 11: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Amazon EFS Architecture

NFSClients

NFSClients

NFSClients

MountTarget

Single Namespace

MountTarget

MountTarget

Page 12: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Do It Yourself – Cost

NFSClients

NFSServer

Volume Volume

NFSClients

NFSServer

Volume Volume

NFSClients

NFSServer

Volume Volume

Page 13: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Amazon EFS Architecture

NFSClients

NFSClients

NFSClients

MountTarget

Single Namespace

MountTarget

MountTarget

Page 14: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Do you need an EFS file system?

If you have an application running on EC2 or use case that requires a file system…AND

• Requires multi-attach OR• GBs/s throughput OR• Multi-AZ availability/durability OR• Requires automatic scaling (grow/shrink) of storage

Page 15: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Where is EFS available today?

• US West (Oregon)

• US East (N. Virginia)

• US East (Ohio)

• EU (Ireland)

• Asia Pacific (Sydney)

More coming soon!

Page 16: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Hands-on: Create an EFS File System (Console)

Page 17: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Resources for Amazon EFS

File System• Regional construct• Ten per account per region (soft)• Default throughput limit 3 GB/s (soft)• Metered size updates approx. every hour• Accessible from EC2

• VPC, EC2-Classic via ClassicLink• Accessible from on-premises

• AWS Direct Connect

Page 18: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Resources for Amazon EFS

File System cont…

• Scenarios for on-prem via Direct Connect

Bursting

Migration

Tiering

Backup / DR

Page 19: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Resources for Amazon EFS

Mount Targets• One or more per file system• Create in a VPC Subnet• One per Availability Zone• Must be in the same VPC

Page 20: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Resources for Amazon EFS

Security Groups• Standard VPC Security Group• Same VPC as subnet• Up to five per mount target• Allow inbound TCP port 2049

from NFS clients

Page 21: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Mount EFS

NFSv4.0 NFSv4.1Linux Kernel 4+

Page 22: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Hands-on: Mount an EFS File System (Console)

Launch EC2 instance from EC2 Console

Connect to the instanceMake a directoryMount EFS file systemQuery disk file system & file system table

• df; df -hT; df -h -t nfsv4; mount -t nfsv4

Page 23: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Amazon EFS Architecture

NFSClients

MountTarget

Availability Zone

VPC subnet

Amazon EFS

EFS File Systemfs-123456ab

Default

Default

Page 24: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Amazon EFS Architecture

NFSClients

MountTarget

Availability Zone

VPC subnet

Amazon EFS

VPC subnet

EFS File Systemfs-123456ab

Default

Default

Page 25: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Amazon EFS Architecture

NFSClients

MountTarget

VPC subnet

Amazon EFS

MountTarget

EFS File Systemfs-123456ab

DefaultDefault

Default

Default

Page 26: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Security

Control network traffic using VPC security groups and network ACLs

Control file and directory access by using POSIX permissions

Control administrative access (API access) to file systems by using AWS Identity and Access Management (IAM)

action-level and resource-level permissions

Page 27: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

High throughput and parallel I/O

Low latency and serial I/O

GenomicsBig data analyticsScale-out jobs

Home directoriesContent management

Web servingMetadata-intensive

jobs

Amazon EFS is designed for wide spectrum of performance needs

Page 28: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Performance modes for different workloads

Mode What’s it for Advantages Tradeoffs When to use

General purpose (default)

Latency-sensitive

applications and general-purpose

workloads

Lowestlatencies for file

operations

Limit of 7K ops/sec

Best choice for most workloads

Max I/OLarge-scale and

data-heavyapplications

Virtually unlimited ability

to scale out throughput /

IOPS

Slightly higher latencies

Consider for large scale-out

workloads

Page 29: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

EC2EC2

EC2EC2

EC2EC2

…File systems distributed across unconstrained number of servers

Avoids bottlenecks/constraints of traditional file serversEnables high levels of aggregate IOPS/throughput

Data also distributed across Availability Zones (durability, availability)

Amazon EFS - distributed data storage design

Page 30: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

How to think about EFS perf relative to EBS

Amazon EFS Amazon EBS PIOPS

Performance

Per-operationlatency Low, consistent Lowest, consistent

Throughput scale Multiple GBs per second Single GB per second

Characteristics

Data availability / durability Stored redundantly across multiple AZs Stored redundantly in a single AZ

Access 1 to 1000s of EC2 instances, from multiple AZs, concurrently Single EC2 instance in a single AZ

Use casesBig Data and analytics, media processing

workflows, content management, web serving, home directories

Boot volumes, transactional and NoSQL databases, data warehousing

& ETL

Page 31: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

I/O size impacts throughput of serialized operations

4 KB 32 KB 256 KB 2 MB 16 MB

I/O size

Thro

ughp

ut

I/O Size Implication

Page 32: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Take advantage of EFS’s distributed architecture

Parallelize via multiple threads and/or multiple instances

0

5000

10000

15000

20000

25000

30000

0 20 40 60 80 100 120 140 160

IOPS

# of Total Threads

Aggregate IOPS of parallel writes using10 m4.xlarge instances

Parallelize

Page 33: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Previous Scalability Test

Small files – 300 instancesLarge files – 50 instances

Page 34: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

EFS CloudWatch Metrics

• DataReadIOBytes• DataWriteIOBytes• MetaDataIOBytes• TotalIOBytes• BurstCreditBalance• PermittedThroughput• ClientConnections• PercentIOLimit

AmazonCloudWatch

Page 35: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

EFS Economics

No minimum commitments or up-front feesNo need to provision storage in advanceNo other fees, charges, or billing dimensions

Price: $0.30/GB-Month (US Regions)$0.33/GB-Month (EU Ireland)$0.36/GB-Month (AP Sydney)

Page 36: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

EFS TCO example

Let’s say you need to store ~500 GB and require high availability and durability

Using a shared file layer on top of EBS, you might provision 600 GB (with ~85% utilization) and fully replicate the data to a second Availability Zone for availability/durability

Example comparative cost:Storage (2x 600 GB EBS gp2 volumes): $120 per monthCompute (2x m4.xlarge instances): $350 per monthInter-AZ data transfer costs (est.): $129 per monthTotal $599 per month

EFS cost is (500GB * $0.30/GB-month) = $150 per month, with no additional charges

Page 37: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Key recommendations

• Test your application!

• Use General Purpose mode for lowest latency, Max-I/O for scale-out

• Use Linux kernel version 4.0 or newer, mount via NFSv4.1

• To optimize, look for opportunities to:• Aggregate I/O• Perform async operations• Parallelize• Cache

• Don’t forget to check your burst credit earn/spend rate when testing – ensure sufficient amount of storage

Page 38: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Reference

AWS Loft EFS Hands-on Walk-through - https://bit.ly/awsloft2017

AWS 10-minute Tutorials - https://aws.amazon.com/getting-started/tutorials/

Amazon EFS Web page - https://aws.amazon.com/efs/

YouTube AWS Channel - https://www.youtube.com/user/AmazonWebServices

Reference Architecture - https://aws.amazon.com/architecture/

QuickStarts - https://aws.amazon.com/architecture/

qwikLABS - https://aws.qwiklabs.com/

Page 39: Deep Dive on Amazon Elastic File Systemaws-de-media.s3-eu-west-1.amazonaws.com/images/AWS...Deep Dive on Amazon Elastic File System Amazon Elastic File System (EFS) Provides simple,

Danke!Darryl S. Osborne

[email protected]