Is there is any way with the aws cli to check instance type availability within a given availability zone before actually launching one?
I'm building a cluster inside a VPC, which requires you to launch a subnet in a zone (either specified or assigned by aws) before you launch the instances, but there is no guarantee that the instance types you want are available in this zone at this point.
Yesterday I hit the dreaded InsufficientInstanceCapacity error and this needs to not happen. What is the correct way to deal this this? I cannot see any obvious ec2 commands for this.
I can loop through each zone creating and destroying subnets until I find one that sticks but there has to be a better way?
Cheers, nick
AWS finally responded directly to me and the answer is no, there is no way to check capacity. Their suggested solution is to fall back to more smaller instance types until you find one that works.
Use reserved instances. This is precisely the use case for Reserved Instances. You'll also save a bunch of money over on-demand instances.