How check the availability of specific types of ec2 by availability zone?

1

Hi all,

Is it possible to check the availability of specific types of ec2 by availability zone?

Best regards.

asked 2 years ago3.8K views
5 Answers
0

Thanks for replying, but actually I wanted a command that would show me the amount not only that there is a certain type of instance.

answered 2 years ago
  • That information is not available to the customers.

0

Yes, there are some examples including CLI commands described here

profile pictureAWS
EXPERT
answered 2 years ago
0

When I try to launch p2.xlarge, I sometimes get:

We currently do not have sufficient p2.xlarge capacity in the Availability Zone you requested (us-east-1b). Our system will be working on provisioning additional capacity. You can currently get p2.xlarge capacity by not specifying an Availability Zone in your request or choosing us-east-1a, us-east-1c, us-east-1d, us-east-1e.

However, there's no way in the console to remove the availability zone, just to change it, and then I need to try one by one... How to solve it?

answered 2 years ago
0

aws ec2 describe-instance-type offerings shows only the types of instances, but does not offer any clue about how many are available, looking at the examples in https://docs.aws.amazon.com/cli/latest/reference/ec2/describe-instance-type-offerings.html. It does not even work for me for some reason. It would be useful if the error message gives a URL where the permission can be granted.

$ aws ec2 describe-instance-type-offerings --location-type "availability-zone" --filters Name=location,Values=us-east-2a --region us-east-2 --query "InstanceTypeOfferings[*].[InstanceType]" --output text
An error occurred (UnauthorizedOperation) when calling the DescribeInstanceTypeOfferings operation: You are not authorized to perform this operation. User: YYY is not authorized to perform: ec2:DescribeInstanceTypeOfferings with an explicit deny in a service control policy
answered 4 months ago
0

To check the availability of instance types in different AZ, you can use the following cli commands:

  1. List all AZ in region aws ec2 describe-availability-zones --region us-east-1
  2. List instance type available by AZ. aws ec2 describe-instance-type-offerings --region us-east-1 --location-type availability-zone --filters "Name=instance-type,Values=c7a.large" --output text

Unfortunately, AWS does not make public the quantity of instance types available by region/AZ.

AWS
answered a month ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions