SlideShare uma empresa Scribd logo
1 de 64
Baixar para ler offline
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Brad Bonnett, Sr Manager Product Management, EC2 Pricing & Launch Services
Bhavesh Maisheri, Technology Project Manager, Market Regulation Surveillance Technology, FINRA
Ratnakar Korem, Technology Project Manager, Market Regulation Surveillance Technology, FINRA
SRV203
Optimizing Amazon EC2
for Fun and Profit
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Optimizing Performance and Cost
Right sizing
Purchasing options
Increase elasticity
Measure, monitor &
improve
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Right Sizing
• Selecting the cheapest instance available while
meeting performance requirements
• Look at CPU, RAM, storage, and network
utilization to identify potential instances that can
be downsized
• Testing with On-Demand is cheap (use Spot to
test even cheaper!)
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Instance Growth – Increased Choice
2017 launches:
• Compute optimized: C5, Z1d
• General purpose: M5, T2 Unlimited
• Accelerated computing: G3, P3
• Memory optimized: x1e
• I/O optimized: I3, H1
• Programmable/FPGAs: F1
• Bare metal: I3.metal
3
5
7
11 12 13
23
42
52
60
70
2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Increase Elasticity
Turn off non-production instances
• Look for dev/test, non-prod instances that are
always running and turn off
Automatically scale production
• Use Auto Scaling to scale in and out based on
demand and usage
• AWS CloudFormation, Amazon CloudWatch &
scheduled scaling are your friends
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Measure, Monitor, Improve
• Auto-tag resources
• Identify always-on non-prod
• Identify instances to downsize
• Recommend Reserved Instances
• Dashboard your status
• Report on savings
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Tagging is Essential
•How do we explain the costs?
•How do we allocate the charges to the
right team?
•How do we save money?
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Tagging is Essential
Up to 50 tags (key-value pairs) per instance
• Completely custom – Environment, owner, application, cost center, etc.
• Tag on create, after launch, or both!
i-4a1c2f5d
Owner =
Admin
Env =
Test
App =
website
i-4a3d3f6e
Owner =
Admin
Env =
Prod
App =
website
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Templatize launch requests with EC2 Launch templates
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Consistent
experience
Simplified
permissions
Governance &
best practices
Increase productivity
Launch Templates are now available in AWS CloudFormation
with Auto Scaling and Spot Fleet
Use Launch Templates to achieve…
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Purchasing Options
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
No upfront
investment
required
Pay as you go
Pay less when you
reserve
Pay less as AWS
grows
AWS Pricing Principles
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Purchasing Options
On-Demand
Pay for compute capacity by the second
with no long-term commitments
Spiky workloads,
to define needs
Reserved Instances
Make a 1- or 3-year commitment and
receive a significant discount off On-
Demand prices
Committed &
steady-state usage
Spot Instances
Spare EC2 capacity at savings of up to
90% off On-Demand prices
Fault-tolerant, flexible,
stateless workloads
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 On-Demand Pricing
Short-term, spiky, or
unpredictable
Low cost & flexible Develop and test
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Reserved Pricing
Discount up to 75% off
the On-Demand price
Steady state and
committed usage
1- and 3-year terms
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
EC2 Reserved Pricing – Flexibility & Savings
Optional capacity reservation
when used in a specific
Availability Zone
Convertible RIs
Change instance family,
OS, tenancy, & payment
Payment flexibility
with three upfront payment
options (all, partial, none)
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Reserved Instance Recommendations
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon EC2 Spot Instances
Low Cost Faster Results Easy Access Resource
Flexibility
Spare EC2 capacity that AWS can reclaim with two minutes of notice
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Rendered on Amazon EC2 Spot Instances
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
EC2 Spot: Spare Compute Capacity at Scale
Spot is available for all EC2
Instance Types, in all Public
Regions and in all Availability
Zones
Coming Soon – AWS GovCloud (US)!
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Consumer apps & services
B2B Enterprise Tech
Research
Sports, Media &
Entertainment Financial Services
AdTech & digital experience
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
EC2 Spot: Use Cases
Big data
Containers &
test/dev
HPC & batch Web Services
FINRA has saved up to 50%
from its on-premises solution,
increased elasticity/scalability,
and accelerated reprocessing
requests from months to days
with EC2 Spot Instances
Yelp runs millions of tests
every day with EC2 Spot
Instances. Yelp improved test
result response time from 2
days to 30 minutes and has
also delivered a large reduction
in execution costs with Spot.
TLG Aerospace saw a 75%
reduction in the cost per CFD
simulation with Amazon EC2
Spot Instances. They were able
to pass those savings along to
their customers and be more
competitive.
AdRoll have been able to
seamlessly scale their
infrastructure, better serve
customers across the globe,
and reduce our fixed costs by
75% and operational costs by
83%.with AWS solution,
including EC2 Spot Instances
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Picking the right EC2 Purchase Option
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
To Optimize EC2, Combine All Three Options
1. Use Reserved Instances for
known/steady-state workloads
2. Scale using Spot, On-Demand, or
both
3. AWS services make this easy and
efficient (e.g., Auto Scaling, Spot
Fleet, Amazon ECS/Amazon EKS,
Amazon EMR, Thinkbox
Deadline, AWS Batch, AWS
CloudFormation)
0
2
4
6
8
10
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
On-Demand
Spot
Reserved
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Optimization Patterns – Grid Processing
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
The Old Way – Low Utilization, High Costs
Server utilization rates are typically low due to need to deploy in advance and for peak needs
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
The Old Way – Managing with High Utilization
Higher grid utilization rates result in hidden costs: longer queue wait times and delayed results
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
The Old Way – In the Cloud?
0
20
40
60
80
100
120
140
160
3 year Reserved Instances
?
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
The Old Way – Conflicting Goals
-600%
-500%
-400%
-300%
-200%
-100%
0%
100%
0
200
400
600
800
1000
1200
1400
Jobs in the Queue
Grid Utilization
Higher utilization can reduce IT spending… but also constrain the business
But every job in the queue
represents business impact
Grid utilization looks great
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
The Cloud Way: Scalability When Needed
Scale higher to reduce time to results: Less waiting, more agility, faster innovation
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
The Cloud Way: Optimize for Cost and Results
?
0
100
200
300
400
500
600
1 2 3 4 5 6 7 8 9 10 11 12
3 year Reserved Instances On-Demand Spot
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
New EC2 Spot Pricing Model
Simplified access
Via existing EC2 API calls such
as RunInstances
Simplified Pricing Set it
& Forget it
Low predictable prices
without bidding
Pause & Resume
With hibernation and stop-
start
Simplified access model, predictable prices, pause & resume
EC2 Fleet: Simply tell Fleet how much capacity you need and Fleet does the rest
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Introducing Amazon EC2 Fleet
Benefits
Simplifies provisioning of EC2 capacity across different instance types, AZs, and purchase models with a single API
Reduces Costs
Combines Spot, On-Demand, and RIs to
run workloads at the lowest possible
cost
Increases Operational Efficiency
Provisions compute capacity across
purchase options, instance types, and
AZs with a single API
Key Features
Flexible Capacity Allocation
Select an instance allocation strategy
that works for your app in app-aware
units (vCPU, GB RAM etc.)
Simplified Provisioning
Select instances, assign weights, specify
target capacity for On-Demand and Spot
Instances, and build a fleet within
seconds
Spot Instances
On-Demand InstancesOn-Demand Instances
Spot Instances
Reserved InstancesReserved Instances
AZ1 AZ2
Massive Scale
Launch 1,000’s of instances with a single
API call, and scale to 1,000s of cores,
TBs of memory, etc.
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
New Spot Instance Advisor
✓ Shows your savings over
On-Demand
✓ Helps you select pools
with the least chance of
interruption
Note: The average frequency of interruption across all Regions and instance types is <5%
https://aws.amazon.com/ec2/spot/instance-advisor/
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
FINRA Use Case
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
About
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Investor
protection
Market
integrity
FINRA: Mission
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
FINRA: Volume
brokers
17
firms
3,700 630,000
stock
exchanges
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
FINRA: Volume Growth
37 billion
events on average
each day
in 2017
100 billion
events on a single day
in March 2018
58 billion
events on average
each day
in 2018
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
FINRA: Big Data
of storage
25+ pb 150+
applications
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Leverage the Data: Apps, Query, Machine Learning
Data Lake
Audit Trail
Market
Surveillance
Ad Hoc
Lifecycle
Viewer
Data Science
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Market Surveillance – Pattern
Data Lake
PatternN
Output Data
Orchestration
Data Location
Registration
Frame
-work
DevOps
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Pattern Execution Framework
Data Lake
Pattern1 Pattern2 Pattern3 Pattern4 Pattern5 Pattern6 PatternN…
Output Data Output Data Output Data Output Data Output DataS3
Orchestration
Data Location
Registration
Frame
work
DevOps
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Three-Pronged Challenges
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Three-Pronged Objectives: “S3”
SCALABILITYSAVINGS STABILITY
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Savings: 30,000 EC2 Instances Used per Week
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Savings: Over 95% of EC2 Instances Use Spot
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Savings: Over 95% of EC2 Instances Use Spot
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Savings: Get the Best Possible Price
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Savings: EC2 Usage across AZs
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Savings: Multiple Pattern Configurations
Data Lake
PatternN
Output Data
m4.4xlarge
* 50
c4.8xlarge
* 25
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Three-Pronged Objectives: “S3”
SCALABILITYSAVINGS STABILITY
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Scalability: Market Events Reach New Highs
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Scalability: EC2 Usage per Week
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Scalability: EC2 Usage per Week
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Three-Pronged Objectives: “S3”
SCALABILITYSAVINGS STABILITY
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Stability: (Minimal) Disruption Due to Spot
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Stability: Time-Sensitive Workloads Use On-Demand
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Three-Pronged Challenges
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Technology Project Manager
Market Regulation Surveillance
FINRA
http://technology.finra.org/
Ratnakar Korem
Technology Project Manager
Market Regulation Surveillance
FINRA
http://technology.finra.org/
Bhavesh Maisheri
Thank You!
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Optimization Best Practices
✓ Remember the pillars of optimization
✓ Right sizing
✓ Increase elasticity (turn stuff off!)
✓ Measure, monitor, and improve
✓ Use Launch Templates to streamline and simplify
the launch process
✓ Use tags to understand your services
✓ Architect your workloads with performance and
cost in mind
✓ Optimize across the three purchasing options
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Putting It All Together
Build free from
constraints
Optimize cost and
performance
Accelerate your
innovation
By combining the breadth of the three purchase options for Amazon EC2 with the
depth of the capabilities our platform provides, you will …
On AWS, you can be more innovative and more cost-effective than anywhere else
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Thank You!

Mais conteúdo relacionado

Mais procurados

Mais procurados (20)

Introduction to Serverless on AWS - Builders Day Jerusalem
Introduction to Serverless on AWS - Builders Day JerusalemIntroduction to Serverless on AWS - Builders Day Jerusalem
Introduction to Serverless on AWS - Builders Day Jerusalem
 
SRV309 AWS Purpose-Built Database Strategy: The Right Tool for the Right Job
 SRV309 AWS Purpose-Built Database Strategy: The Right Tool for the Right Job SRV309 AWS Purpose-Built Database Strategy: The Right Tool for the Right Job
SRV309 AWS Purpose-Built Database Strategy: The Right Tool for the Right Job
 
Building Well Architected .NET Apps (WIN304) - AWS re:Invent 2018
Building Well Architected .NET Apps (WIN304) - AWS re:Invent 2018Building Well Architected .NET Apps (WIN304) - AWS re:Invent 2018
Building Well Architected .NET Apps (WIN304) - AWS re:Invent 2018
 
使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200)
使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200)使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200)
使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200)
 
BDA301 Working with Machine Learning in Amazon SageMaker: Algorithms, Models,...
BDA301 Working with Machine Learning in Amazon SageMaker: Algorithms, Models,...BDA301 Working with Machine Learning in Amazon SageMaker: Algorithms, Models,...
BDA301 Working with Machine Learning in Amazon SageMaker: Algorithms, Models,...
 
Rightsizing Your Silicon Design Environment: Elastic Clusters for EDA Workloa...
Rightsizing Your Silicon Design Environment: Elastic Clusters for EDA Workloa...Rightsizing Your Silicon Design Environment: Elastic Clusters for EDA Workloa...
Rightsizing Your Silicon Design Environment: Elastic Clusters for EDA Workloa...
 
Improve Accessibility Using Machine Learning (AIM332) - AWS re:Invent 2018
Improve Accessibility Using Machine Learning (AIM332) - AWS re:Invent 2018Improve Accessibility Using Machine Learning (AIM332) - AWS re:Invent 2018
Improve Accessibility Using Machine Learning (AIM332) - AWS re:Invent 2018
 
AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...
AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...
AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...
 
Amazon Prime Video: Delivering the Amazing Video Experience (CTD203-R1) - AWS...
Amazon Prime Video: Delivering the Amazing Video Experience (CTD203-R1) - AWS...Amazon Prime Video: Delivering the Amazing Video Experience (CTD203-R1) - AWS...
Amazon Prime Video: Delivering the Amazing Video Experience (CTD203-R1) - AWS...
 
Achieving Business Value with AWS - AWS Online Tech Talks
Achieving Business Value with AWS - AWS Online Tech TalksAchieving Business Value with AWS - AWS Online Tech Talks
Achieving Business Value with AWS - AWS Online Tech Talks
 
MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018
MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018
MySQL High Availability & Disaster Recovery (DAT361) - AWS re:Invent 2018
 
Taking Serverless to the Edge
Taking Serverless to the Edge Taking Serverless to the Edge
Taking Serverless to the Edge
 
Choose the right DB for the Job - Builders Day Israel
Choose the right DB for the Job - Builders Day IsraelChoose the right DB for the Job - Builders Day Israel
Choose the right DB for the Job - Builders Day Israel
 
Create an ML Factory in Financial Services with CI CD - FSI301 - New York AWS...
Create an ML Factory in Financial Services with CI CD - FSI301 - New York AWS...Create an ML Factory in Financial Services with CI CD - FSI301 - New York AWS...
Create an ML Factory in Financial Services with CI CD - FSI301 - New York AWS...
 
Intro to Open Source Databases on AWS - AWS Online Tech Talks
Intro to Open Source Databases on AWS - AWS Online Tech TalksIntro to Open Source Databases on AWS - AWS Online Tech Talks
Intro to Open Source Databases on AWS - AWS Online Tech Talks
 
[NEW LAUNCH!] Optimize file system costs using Amazon EFS Infrequent Access (...
[NEW LAUNCH!] Optimize file system costs using Amazon EFS Infrequent Access (...[NEW LAUNCH!] Optimize file system costs using Amazon EFS Infrequent Access (...
[NEW LAUNCH!] Optimize file system costs using Amazon EFS Infrequent Access (...
 
SRV321 Deep Dive on Amazon EBS
 SRV321 Deep Dive on Amazon EBS SRV321 Deep Dive on Amazon EBS
SRV321 Deep Dive on Amazon EBS
 
Compliance and Security Mitigation Techniques
Compliance and Security Mitigation TechniquesCompliance and Security Mitigation Techniques
Compliance and Security Mitigation Techniques
 
Building Serverless Applications with Amazon DynamoDB & AWS Lambda - Workshop...
Building Serverless Applications with Amazon DynamoDB & AWS Lambda - Workshop...Building Serverless Applications with Amazon DynamoDB & AWS Lambda - Workshop...
Building Serverless Applications with Amazon DynamoDB & AWS Lambda - Workshop...
 
Analyze Amazon CloudFront and Lambda@Edge Logs to Improve Customer Experience...
Analyze Amazon CloudFront and Lambda@Edge Logs to Improve Customer Experience...Analyze Amazon CloudFront and Lambda@Edge Logs to Improve Customer Experience...
Analyze Amazon CloudFront and Lambda@Edge Logs to Improve Customer Experience...
 

Semelhante a Optimize Amazon EC2 for Fun and Profit

Semelhante a Optimize Amazon EC2 for Fun and Profit (20)

Optimize Amazon EC2 for Fun and Profit - SRV203 - Chicago AWS Summit
Optimize Amazon EC2 for Fun and Profit - SRV203 - Chicago AWS SummitOptimize Amazon EC2 for Fun and Profit - SRV203 - Chicago AWS Summit
Optimize Amazon EC2 for Fun and Profit - SRV203 - Chicago AWS Summit
 
SRV203 Optimizing Amazon EC2 for Fun and Profit
 SRV203 Optimizing Amazon EC2 for Fun and Profit SRV203 Optimizing Amazon EC2 for Fun and Profit
SRV203 Optimizing Amazon EC2 for Fun and Profit
 
Running Amazon EC2 Workloads at Scale (CMP402-R1) - AWS re:Invent 2018
Running Amazon EC2 Workloads at Scale (CMP402-R1) - AWS re:Invent 2018Running Amazon EC2 Workloads at Scale (CMP402-R1) - AWS re:Invent 2018
Running Amazon EC2 Workloads at Scale (CMP402-R1) - AWS re:Invent 2018
 
Best practices for optimizing your EC2 costs with Spot Instances | AWS Floor28
Best practices for optimizing your EC2 costs with Spot Instances | AWS Floor28Best practices for optimizing your EC2 costs with Spot Instances | AWS Floor28
Best practices for optimizing your EC2 costs with Spot Instances | AWS Floor28
 
Better, Faster, Cheaper – Cost Optimizing Compute with Amazon EC2 Fleet #savi...
Better, Faster, Cheaper – Cost Optimizing Compute with Amazon EC2 Fleet #savi...Better, Faster, Cheaper – Cost Optimizing Compute with Amazon EC2 Fleet #savi...
Better, Faster, Cheaper – Cost Optimizing Compute with Amazon EC2 Fleet #savi...
 
Optimize EC2 for Fun and Profit - SRV203 - Anaheim AWS Summit
Optimize EC2 for Fun and Profit - SRV203 - Anaheim AWS SummitOptimize EC2 for Fun and Profit - SRV203 - Anaheim AWS Summit
Optimize EC2 for Fun and Profit - SRV203 - Anaheim AWS Summit
 
Cost optimisation as a by-product of awesome practice and agility at Trainline
Cost optimisation as a by-product of awesome practice and agility at TrainlineCost optimisation as a by-product of awesome practice and agility at Trainline
Cost optimisation as a by-product of awesome practice and agility at Trainline
 
Amazon EC2 Spot Instances Workshop
Amazon EC2 Spot Instances WorkshopAmazon EC2 Spot Instances Workshop
Amazon EC2 Spot Instances Workshop
 
Cost Optimize EC2 with Amazon EC2 Spot Instances
Cost Optimize EC2 with Amazon EC2 Spot InstancesCost Optimize EC2 with Amazon EC2 Spot Instances
Cost Optimize EC2 with Amazon EC2 Spot Instances
 
AWS Compute Evolved Week: Cost Optimize EC2 with Amazon EC2 Spot Instances
AWS Compute Evolved Week: Cost Optimize EC2 with Amazon EC2 Spot InstancesAWS Compute Evolved Week: Cost Optimize EC2 with Amazon EC2 Spot Instances
AWS Compute Evolved Week: Cost Optimize EC2 with Amazon EC2 Spot Instances
 
Optimizar los costos a medida que mejora en AWS - MXO207 - Mexico City Summit
Optimizar los costos a medida que mejora en AWS - MXO207 - Mexico City SummitOptimizar los costos a medida que mejora en AWS - MXO207 - Mexico City Summit
Optimizar los costos a medida que mejora en AWS - MXO207 - Mexico City Summit
 
Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -...
Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -...Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -...
Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -...
 
AWS Webinar Series - Cost Optimisation Levers, Tools, and Strategies
AWS Webinar Series - Cost Optimisation Levers, Tools, and StrategiesAWS Webinar Series - Cost Optimisation Levers, Tools, and Strategies
AWS Webinar Series - Cost Optimisation Levers, Tools, and Strategies
 
Building High-Scale Web Apps on Amazon EC2 Fleet (CMP409-R1) - AWS re:Invent ...
Building High-Scale Web Apps on Amazon EC2 Fleet (CMP409-R1) - AWS re:Invent ...Building High-Scale Web Apps on Amazon EC2 Fleet (CMP409-R1) - AWS re:Invent ...
Building High-Scale Web Apps on Amazon EC2 Fleet (CMP409-R1) - AWS re:Invent ...
 
Amazon EC2 Spot Instances
Amazon EC2 Spot InstancesAmazon EC2 Spot Instances
Amazon EC2 Spot Instances
 
Running Amazon EKS Workloads on Amazon EC2 Spot Instances (CMP403-R1) - AWS r...
Running Amazon EKS Workloads on Amazon EC2 Spot Instances (CMP403-R1) - AWS r...Running Amazon EKS Workloads on Amazon EC2 Spot Instances (CMP403-R1) - AWS r...
Running Amazon EKS Workloads on Amazon EC2 Spot Instances (CMP403-R1) - AWS r...
 
Running Enterprise Test/Dev on Amazon EC2 Spot Instances (CMP407-R1) - AWS re...
Running Enterprise Test/Dev on Amazon EC2 Spot Instances (CMP407-R1) - AWS re...Running Enterprise Test/Dev on Amazon EC2 Spot Instances (CMP407-R1) - AWS re...
Running Enterprise Test/Dev on Amazon EC2 Spot Instances (CMP407-R1) - AWS re...
 
以 Amazon EC2 Spot 執行個體有效控制專案成本 (Level: 200)
以 Amazon EC2 Spot 執行個體有效控制專案成本 (Level: 200)以 Amazon EC2 Spot 執行個體有效控制專案成本 (Level: 200)
以 Amazon EC2 Spot 執行個體有效控制專案成本 (Level: 200)
 
Cost Optimisation on AWS
Cost Optimisation on AWSCost Optimisation on AWS
Cost Optimisation on AWS
 
Cloud Economics - TCO 101
Cloud Economics - TCO 101Cloud Economics - TCO 101
Cloud Economics - TCO 101
 

Mais de Amazon Web Services

Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
Amazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
Amazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
Amazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
Amazon Web Services
 

Mais de Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

Optimize Amazon EC2 for Fun and Profit

  • 1. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Brad Bonnett, Sr Manager Product Management, EC2 Pricing & Launch Services Bhavesh Maisheri, Technology Project Manager, Market Regulation Surveillance Technology, FINRA Ratnakar Korem, Technology Project Manager, Market Regulation Surveillance Technology, FINRA SRV203 Optimizing Amazon EC2 for Fun and Profit
  • 2. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Optimizing Performance and Cost Right sizing Purchasing options Increase elasticity Measure, monitor & improve
  • 3. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Right Sizing • Selecting the cheapest instance available while meeting performance requirements • Look at CPU, RAM, storage, and network utilization to identify potential instances that can be downsized • Testing with On-Demand is cheap (use Spot to test even cheaper!)
  • 4. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Amazon EC2 Instance Growth – Increased Choice 2017 launches: • Compute optimized: C5, Z1d • General purpose: M5, T2 Unlimited • Accelerated computing: G3, P3 • Memory optimized: x1e • I/O optimized: I3, H1 • Programmable/FPGAs: F1 • Bare metal: I3.metal 3 5 7 11 12 13 23 42 52 60 70 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017
  • 5. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Increase Elasticity Turn off non-production instances • Look for dev/test, non-prod instances that are always running and turn off Automatically scale production • Use Auto Scaling to scale in and out based on demand and usage • AWS CloudFormation, Amazon CloudWatch & scheduled scaling are your friends
  • 6. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Measure, Monitor, Improve • Auto-tag resources • Identify always-on non-prod • Identify instances to downsize • Recommend Reserved Instances • Dashboard your status • Report on savings
  • 7. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Tagging is Essential •How do we explain the costs? •How do we allocate the charges to the right team? •How do we save money?
  • 8. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Tagging is Essential Up to 50 tags (key-value pairs) per instance • Completely custom – Environment, owner, application, cost center, etc. • Tag on create, after launch, or both! i-4a1c2f5d Owner = Admin Env = Test App = website i-4a3d3f6e Owner = Admin Env = Prod App = website
  • 9. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Templatize launch requests with EC2 Launch templates
  • 10. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Consistent experience Simplified permissions Governance & best practices Increase productivity Launch Templates are now available in AWS CloudFormation with Auto Scaling and Spot Fleet Use Launch Templates to achieve…
  • 11. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Amazon EC2 Purchasing Options
  • 12. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. No upfront investment required Pay as you go Pay less when you reserve Pay less as AWS grows AWS Pricing Principles
  • 13. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Amazon EC2 Purchasing Options On-Demand Pay for compute capacity by the second with no long-term commitments Spiky workloads, to define needs Reserved Instances Make a 1- or 3-year commitment and receive a significant discount off On- Demand prices Committed & steady-state usage Spot Instances Spare EC2 capacity at savings of up to 90% off On-Demand prices Fault-tolerant, flexible, stateless workloads
  • 14. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Amazon EC2 On-Demand Pricing Short-term, spiky, or unpredictable Low cost & flexible Develop and test
  • 15. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Amazon EC2 Reserved Pricing Discount up to 75% off the On-Demand price Steady state and committed usage 1- and 3-year terms
  • 16. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. EC2 Reserved Pricing – Flexibility & Savings Optional capacity reservation when used in a specific Availability Zone Convertible RIs Change instance family, OS, tenancy, & payment Payment flexibility with three upfront payment options (all, partial, none)
  • 17. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Reserved Instance Recommendations
  • 18. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Amazon EC2 Spot Instances Low Cost Faster Results Easy Access Resource Flexibility Spare EC2 capacity that AWS can reclaim with two minutes of notice
  • 19. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 20. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Rendered on Amazon EC2 Spot Instances
  • 21. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. EC2 Spot: Spare Compute Capacity at Scale Spot is available for all EC2 Instance Types, in all Public Regions and in all Availability Zones Coming Soon – AWS GovCloud (US)!
  • 22. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Consumer apps & services B2B Enterprise Tech Research Sports, Media & Entertainment Financial Services AdTech & digital experience
  • 23. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. EC2 Spot: Use Cases Big data Containers & test/dev HPC & batch Web Services FINRA has saved up to 50% from its on-premises solution, increased elasticity/scalability, and accelerated reprocessing requests from months to days with EC2 Spot Instances Yelp runs millions of tests every day with EC2 Spot Instances. Yelp improved test result response time from 2 days to 30 minutes and has also delivered a large reduction in execution costs with Spot. TLG Aerospace saw a 75% reduction in the cost per CFD simulation with Amazon EC2 Spot Instances. They were able to pass those savings along to their customers and be more competitive. AdRoll have been able to seamlessly scale their infrastructure, better serve customers across the globe, and reduce our fixed costs by 75% and operational costs by 83%.with AWS solution, including EC2 Spot Instances
  • 24. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Picking the right EC2 Purchase Option
  • 25. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. To Optimize EC2, Combine All Three Options 1. Use Reserved Instances for known/steady-state workloads 2. Scale using Spot, On-Demand, or both 3. AWS services make this easy and efficient (e.g., Auto Scaling, Spot Fleet, Amazon ECS/Amazon EKS, Amazon EMR, Thinkbox Deadline, AWS Batch, AWS CloudFormation) 0 2 4 6 8 10 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 On-Demand Spot Reserved
  • 26. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Optimization Patterns – Grid Processing
  • 27. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. The Old Way – Low Utilization, High Costs Server utilization rates are typically low due to need to deploy in advance and for peak needs
  • 28. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. The Old Way – Managing with High Utilization Higher grid utilization rates result in hidden costs: longer queue wait times and delayed results
  • 29. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. The Old Way – In the Cloud? 0 20 40 60 80 100 120 140 160 3 year Reserved Instances ?
  • 30. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. The Old Way – Conflicting Goals -600% -500% -400% -300% -200% -100% 0% 100% 0 200 400 600 800 1000 1200 1400 Jobs in the Queue Grid Utilization Higher utilization can reduce IT spending… but also constrain the business But every job in the queue represents business impact Grid utilization looks great
  • 31. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. The Cloud Way: Scalability When Needed Scale higher to reduce time to results: Less waiting, more agility, faster innovation
  • 32. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. The Cloud Way: Optimize for Cost and Results ? 0 100 200 300 400 500 600 1 2 3 4 5 6 7 8 9 10 11 12 3 year Reserved Instances On-Demand Spot
  • 33. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. New EC2 Spot Pricing Model Simplified access Via existing EC2 API calls such as RunInstances Simplified Pricing Set it & Forget it Low predictable prices without bidding Pause & Resume With hibernation and stop- start Simplified access model, predictable prices, pause & resume EC2 Fleet: Simply tell Fleet how much capacity you need and Fleet does the rest
  • 34. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Introducing Amazon EC2 Fleet Benefits Simplifies provisioning of EC2 capacity across different instance types, AZs, and purchase models with a single API Reduces Costs Combines Spot, On-Demand, and RIs to run workloads at the lowest possible cost Increases Operational Efficiency Provisions compute capacity across purchase options, instance types, and AZs with a single API Key Features Flexible Capacity Allocation Select an instance allocation strategy that works for your app in app-aware units (vCPU, GB RAM etc.) Simplified Provisioning Select instances, assign weights, specify target capacity for On-Demand and Spot Instances, and build a fleet within seconds Spot Instances On-Demand InstancesOn-Demand Instances Spot Instances Reserved InstancesReserved Instances AZ1 AZ2 Massive Scale Launch 1,000’s of instances with a single API call, and scale to 1,000s of cores, TBs of memory, etc.
  • 35. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. New Spot Instance Advisor ✓ Shows your savings over On-Demand ✓ Helps you select pools with the least chance of interruption Note: The average frequency of interruption across all Regions and instance types is <5% https://aws.amazon.com/ec2/spot/instance-advisor/
  • 36. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. FINRA Use Case
  • 37. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. About
  • 38. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Investor protection Market integrity FINRA: Mission
  • 39. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. FINRA: Volume brokers 17 firms 3,700 630,000 stock exchanges
  • 40. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. FINRA: Volume Growth 37 billion events on average each day in 2017 100 billion events on a single day in March 2018 58 billion events on average each day in 2018
  • 41. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. FINRA: Big Data of storage 25+ pb 150+ applications
  • 42. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Leverage the Data: Apps, Query, Machine Learning Data Lake Audit Trail Market Surveillance Ad Hoc Lifecycle Viewer Data Science
  • 43. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Market Surveillance – Pattern Data Lake PatternN Output Data Orchestration Data Location Registration Frame -work DevOps
  • 44. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Pattern Execution Framework Data Lake Pattern1 Pattern2 Pattern3 Pattern4 Pattern5 Pattern6 PatternN… Output Data Output Data Output Data Output Data Output DataS3 Orchestration Data Location Registration Frame work DevOps
  • 45. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Three-Pronged Challenges
  • 46. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Three-Pronged Objectives: “S3” SCALABILITYSAVINGS STABILITY
  • 47. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Savings: 30,000 EC2 Instances Used per Week
  • 48. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Savings: Over 95% of EC2 Instances Use Spot
  • 49. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Savings: Over 95% of EC2 Instances Use Spot
  • 50. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Savings: Get the Best Possible Price
  • 51. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Savings: EC2 Usage across AZs
  • 52. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Savings: Multiple Pattern Configurations Data Lake PatternN Output Data m4.4xlarge * 50 c4.8xlarge * 25
  • 53. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Three-Pronged Objectives: “S3” SCALABILITYSAVINGS STABILITY
  • 54. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Scalability: Market Events Reach New Highs
  • 55. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Scalability: EC2 Usage per Week
  • 56. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Scalability: EC2 Usage per Week
  • 57. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Three-Pronged Objectives: “S3” SCALABILITYSAVINGS STABILITY
  • 58. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Stability: (Minimal) Disruption Due to Spot
  • 59. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Stability: Time-Sensitive Workloads Use On-Demand
  • 60. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Three-Pronged Challenges
  • 61. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Technology Project Manager Market Regulation Surveillance FINRA http://technology.finra.org/ Ratnakar Korem Technology Project Manager Market Regulation Surveillance FINRA http://technology.finra.org/ Bhavesh Maisheri Thank You!
  • 62. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Optimization Best Practices ✓ Remember the pillars of optimization ✓ Right sizing ✓ Increase elasticity (turn stuff off!) ✓ Measure, monitor, and improve ✓ Use Launch Templates to streamline and simplify the launch process ✓ Use tags to understand your services ✓ Architect your workloads with performance and cost in mind ✓ Optimize across the three purchasing options
  • 63. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Putting It All Together Build free from constraints Optimize cost and performance Accelerate your innovation By combining the breadth of the three purchase options for Amazon EC2 with the depth of the capabilities our platform provides, you will … On AWS, you can be more innovative and more cost-effective than anywhere else
  • 64. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Thank You!