Digging into EC2 Spot Price History
In December 2009, Amazon Web Services team introduced yet another innovation - spot pricing for EC2 instances. Several sites were created shortly to track spot price history by creating price charts. But price charts are relatively boring - juicy meat is in the dynamics hidden inside series of numbers which represent the price history. Let’s do some exploring!
Several notes first.
- All references to times and dates below are GMT for all regions.
- Spot instances went live on December 14, therefore I ignore all data points before that (for simplicity, my cutoff was set at UNIX timestamp 1260777600 - it's 8am on December 14 GMT, which translates to midnight in Seattle where AWS is headquartered).
- Spot price history was obtained on January 25, 2010 at 10:54pm via API and cached locally for analysis.
- In order to be able to deal with integers instead of floats, all prices below are represented in points where 1,000 points = $1 per compute hour.
- Each product is specified as [region, instance_type, product_description] tuple.
- I am only going to outline facts below, all interpretation is up to you.
- These results have not been exhaustively verified, my analysis code may have bugs. Use at your own risk.
#1 Price averages
Here is a chart of average spot price for each product relative to regular price for the same product (averages take into consideration for how long each price was valid). Percentage next to a product identification represents the ratio between average spot price and regular price.
#2 Price increases in a row
Maximum number of price increases in a row was 6. It occurred on January 23-24 for [us-west-1, m1.large, Windows] and the price went up from 256 to 273.
5 price increases in a row happened also once, 4 in a row - 16 times, 3 in a row - 95 times, 2 in a row - 643 times, and a single increase immediately followed by price reduction happened 2,433 times. Of the latter, 684 times (28%) were a single price increase followed by price returning to where it used to be right before the increase (X -> X+Y -> X).
#3 Individual price increases
Maximum single price increase in absolute terms was 928 - it occurred for [us-east-1, m2.2xlarge, Windows] when the price went up from 572 to 1,500. Second biggest was 890 for [us-east-1, m1.large, Linux/UNIX] and third biggest - 551 for [us-east-1, m1.small, Windows]. Note that all of these occurred in us-east-1.
The biggest price increase as percentage of the regular price was 460% when a price for [us-east-1, m1.small, Windows] jumped from 49 to 600 on January 24. The second and third biggest in the category were 262% increase for [us-east-1, m1.large, Linux/UNIX] (110 -> 1000) and 64% increase for [us-east-1, m2.2xlarge, Windows] (572 -> 1500).
The same two biggest increases were also the biggest price increases as percentage of current spot price - 1,124% and 809%, respectively. Third place in this category was a 186% increase for [eu-west-1, m1.small, Linux/UNIX] when the price went up from 28 to 80.
Here is a chart showing price increases and reductions day by day.
#4 Number of datapoints per product and/or product family
There were a total of 4,469 spot price revisions for Windows and 3,885 for Linux/UNIX. By region, us-east-1 had the least price revisions in total - 2,491, of which 1,254 were for Windows and 1,237 for Linux/UNIX (50.3% vs 49.7%). A total of 2,809 price revisions in eu-west-1 were distributed 1,518 for Windows vs 1,291 for Linux/UNIX (54% vs 46%). A total of 3,054 price revisions in us-west-1 were distributed 1,697 for Windows vs 1,357 for Linux/UNIX (56% vs 44%).
[eu-west-1, m1.small, Windows] had the most price revisions - 287. [us-east-1, m2.4xlarge, Windows] had the least - 40.
Across all regions combined, the most price revisions per day happened on January 22, 2010 - 351 price revisions.
#5 Percentiles
Here is a Google Fusion table with percentile estimates for each product. I tried to calculate percentiles from 50th through 95th (step 5) and 99th, but since a price function consists of discrete values, not all percentiles could be estimated. For each percentile, a nominal price is provided along with its percentage of the regular instance price for a given product. Percentiles take into consideration for how long a given price was valid.
#6 Spot price over regular price
Situations when a spot price is equal or exceeds regular price are especially interesting. Most such situations occurred in us-east-1, and none of them occurred in eu-west-1.
Spot price has reached but not exceeded the regular price for [c1.xlarge, Linux/UNIX] twice, [c1.medium, Windows] twice, [m1.small, Windows] 6 times, [m1.large, Windows] once - all in us-east-1.
In us-west-1, spot price for [m1.large, Linux/UNIX] exceeded the regular price by 20 for under 2 hours on December 29.
Spot price for [us-east-1, m2.2xlarge, Windows] exceeded the regular price by 60 for over 20 hours on January 11-12.
Spot price for [us-east-1, m1.large, Linux/UNIX] exceeded the regular price by 64 on December 17 and by 660 twice on December 18.
And finally, spot price for [us-east-1, m1.small, Windows] exceeded the regular price by 480 once and by 430 once - both on January 24.
Conclusion
There are hardly any surprises in the spot price history so far, but it’s only been less than 2 months since the feature was launched. As the usage ramps up, I expect it will become more interesting. Kudos to AWS team for coming up with this innovative pricing mechanism and being the first to introduce it at such a large scale in a real environment. Only time will tell if it will stick in its current form or if it will morph into something else (I have a couple of ideas), but the first small step towards dynamic pricing of computing resources has been made.
Read other posts on my blog tagged amazon-ec2-spot.