An introduction to bursting on AWS. The presentation includes an introductory explanation of the new EC2 family, T2, and the new EBS volume type GP2.
Learn about the new services on AWS to get the most bang for your buck.
AWS – an introduction to bursting
New EC2 (T2) and EBS (GP2) volume types
2014-08-21
Amazon Data Services Japan KK
Rasmus Ekman
So, what is a “burst”?
Burst
NormalNormal
• When you have a low average
baseline, with a large temporary
spike, or burst, of performance
• Example: even though the
speedometer of my motorcycle
maxes out at 250KMH, I rarely
drive at that speed, but it is
certainly nice to have the option
to do so when the time and the
circumstances are right. Most of
the time I am using just a
fraction of the power that is
available to me.
New low cost AWS burst services
• New EC2 instance family, T2,
and EBS volume type, GP2,
engineered with bursting in
mind
• Common use cases
– Low traffic web servers
– Dev. environments(build servers
etc)
– Remote desktops
– Small databases
• Extremely high cost-
performance
Computing
T2
New EBS volume type
GP2
Storage
New instance family
It’s all about the credits
• Credits are “saved” when resources are under low
load, and used during bursts
CPU creditsCPU usage
=
Spending
Savings
What is “T2”?
• T2 instance types are a special breed that differ from normal families, such as M3,
R3 and C3, by being able to burst CPU using CPU credits at a very low cost
• Intel Xeon 2.5GHz CPU(with turbo up to 3.3GHz)
• T2 instances provide a baseline level, CPU utilization, of CPU performance. The
baseline is a percentage of the full core performance
• The very lowest cost instance type, t2.micro, is part of the free tier!
• On demand rate starts at $0.013/hour, about $9.50/Month
model vCPU memory storage Baseline
performance
t2.micro 1 1GB EBS only 10%
t2.small 1 2GB EBS only 20%
t2.medium 2 4GB EBS only 40%
In other words, T2 is
a small instance type, with very high
cost-performance, that can burst
T2 is all about understanding CPU credits
Instance
type
Initial (boot)
credits
Credits
earned per
hour
Base
performance
(CPU
utilization)
Maximum
CPU credit
balance
t2.micro 30 6 10% 144
t2.small 30 12 20% 288
t2.medium 60 24 40%(*) 576
To simplify,
1 CPU credit = 1 minute of burst
burst=usage above the baseline performance
Details/(*):http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/t2-instances.html
Common use cases for T2
• Development environment
• Code repository
• Low traffic web application
• Small scale database, etc etc
If you find yourself constantly
running out of credits, move to a
higher instance type (e.g. M3)
Hint→
Price(Tokyo region)
• t2.micro – Monthly cost (Linux)
– $14.6 (On Demand)
– $10.7 (1-year Heavy RI)
– $7.3 (3-year Heavy RI)
• t2.micro – Monthly cost (Windows)
– $18.3 (On Demand)
– $12.8 (1-year Heavy RI)
– $9.4 (3-year Heavy RI)
• t2.small/medium will run 2x and 4x
With a 3 year RI, you can get a
Windows server under $10/Month!
On-demand VS reserved instance (RI)
0
100
200
300
400
500
600
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
t2.micro
t2.micro OD t2.micro 1YHURI t2.micro 3YHURI
USD
月
On-demand 1 year RI 3 year RI
On-demand
1 year RI
3 year RI
Is T2 any faster than T1?
Doorkeeper migrate their RDS database
Faster CPU means lower load More memory means better caching
“With the t2.micro […] we now spend ~35ms on SQL queries - with higher overall rpm,
compared to ~100ms before.”
Michael Reinsch, Co-Founder Doorkeeper Inc
T2 pointers
• T2 only supports HVM
– Same as R3/I2
• T1 only supports PV, meaning you can’t just do an
instance modification (1 click migration) to T2
• T2 only supports VPC, so if you are still on classic,
time to consider a move to VPC
• A general shift towards HVM (Intel CPU
virtualization feature)
• When you reboot, your CPU credits are reset to 0
Existing EBS volume types
Magnetic (standard) Provisioned IOPS
(PIOPS)
Type Hard disk base SSD base
Capacity fee Fee per GB Fee per GB
IOPS capacity
fee
- Fee per provisioned
IOPS
IO request fee Fee per million IO
requests
-
Performance 100 IOPS on average
with the ability to burst
to hundreds of IOPS
Consistently performs at
provisioned level, 4000
IOPS maximum
Introducing EBS General Purpose (SSD) – GP2
a new contender arrives
Magnetic
(standard) General Purpose
SSD
Provisioned IOPS
(PIOPS)
Type Hard disk base SSD base SSD base
Capacity fee Fee per GB Fee per GB Fee per GB
IOPS capacity fee - - Fee per provisioned
IOPS
IO request fee Fee per million
IO requests
- -
Performance 100 IOPS on
average with the
ability to burst to
hundreds of IOPS
The ability to burst to
3,000 IOPS maximum,
with a base performance
of 3 IOPS/GiB
Consistently performs
at provisioned level,
4000 IOPS maximum
In other words, GP2 is…
A new SSD based EBS volume type
that can burst, and has a very simple
fee structure with a high cost-
performance
GP2 details
• A new SSD based EBS volume type
• Base performance of 3 IOPS per GB
100GB volume gives 300 IOPS, and 500GB gives 1500 IOPS baseline etc.
• Can burst up to 3000 IOPS
Very good fit for boot volumes, and volumes that have
short periods of heavy usage
The burst time span is governed by I/O credits (details later)
• Simple fee structure
$0.12/GB per Month (Tokyo region)
No IO request or provisioning fees!
details:http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/EBSVolumeTypes.html
Base performance and volume size
Performance of a General Purpose(SSD) volume
(continuous IO load with various volume sizes)• When IO capacity over
the baseline is requested,
bursting will happen
• When credits have been
exhausted, the baseline
of 3 IOPS per GB is
maintained
• With a 1TB volume you
will get a 3000 IOPS
baseline
IOPS
Minutes
500GB
1TB
100GB
A cost-performance overview
Low IO usage High IO usage
• Magnetic is marginally cheaper than
GP2, but GP2 can burst up to 3000
IOPS without additional cost
• During high load scenarios GP2 is
much more cost effective than PIOPS
• Magnetic cannot provide the
performance needed in this scenario
• PIOPS will guarantee a stable IOPS
100 IOPS
Lowest
cost
General purpose SSD (GP2) tips
• 5 to 50 percent reduction in IOPS when you first access each block of data on
a newly created or restored EBS volume, so pre-warm the volume before
using
For best performance, access all blocks before using
For new volumes, write to all blocks
※With Linux run the dd command (of=/path/to/devfile), and in Windows do a full format
When restoring a snapshot, read all blocks
※With Linux run the dd command (if=/path/to/devfile), and in Windows use “dd for windows”
• Use EBS-Optimized Instances
By using a separate network for EBS, you will get more stable IO throughput
• To convert your old EBS volumes to GP2, take a snapshot
From an EBS snapshot you can restore to a different volume type, such as GP2
Pre-warming details: http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ebs-prewarm.html
EBS comparison summary
Magnetic
(standard)
General
purpose SSD
Provisioned IOPS
(PIOPS)
Use
case
• Very low usage
scenarios.
• Consider S3 for
backups
• OS volume
• Virtual desktops
• Development
and test
environments
• Very high loads that
require extremely
stable IOPS
performance
• Large scale databases
perform
ance
100 IOPS on
average with the
ability to burst to
hundreds of IOPS
The ability to burst
to 3,000 IOPS
maximum, with a
base performance
of 3 IOPS/GiB
Consistently performs at
provisioned level, 4000
IOPS maximum
Summary
• Two new low priced burstable services
– Computing – T2 family
– Storage – general purpose SSD (GP2)
• CPU and IO bursts are governed by credits
• Very high cost-performance
• Good fit for use cases that can allow for
variable performance
IOPS and I/O Credits detailed example
IOPS I/O Credit
Initial I/O Credit
is
5,400,000
As long as IO
credits remain,
performance will
be 3000 IOPS
While bursting IO
credits will
gradually be
consumed
One credits are
depleted bursting
will stop
Once credits reach
0, the baseline
performance will be
excercised
Once load is under
baseline, credits will
increase
When increasing the load
again after credits have
been restored, burst will
happen
分
Baseline performance
(gp2 500GB example)