Purchasing an RDS reserved instance in eu-west-1

After Amazon’s announcement that they’d released reserved instances for Amazon RDS, I decided to purchase a small instance to save the $300-odd per year by buying a one-year reservation.

But for Amazon’s years of research into streamlining online purchases, buying an RDS reservation is currently API-only. So let’s be careful when using the command line, eh? Compare:

$ rds-describe-reserved-db-instances-offerings --db-instance-class db.m1.small --duration 1y --multi-az n
OFFERING c48ab04c-20ba-479d-a0e8-fc510cc07c0a db.m1.small n 1y $227.50 $0.046 mysql

with:

$ EC2_REGION=eu-west-1 rds-describe-reserved-db-instances-offerings --db-instance-class db.m1.small --duration 1y --multi-az n
OFFERING ceb6a579-a4f3-4b55-ac53-7208e3c4b0fd db.m1.small n 1y $227.50 $0.059 mysql

Notice the difference in hourly cost, indicating that the region was correct for eu-west-1. Remember that EC2_REGION instance variable, folks! Wouldn’t want to end up with a non-refundable purchase of $227.50 (or more, for more expensive options) now would we?

Please add this to the web console soon, Amazon. Thanks. I’d rather not make a two hundred dollar mistake due to a missing environment variable.