Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to move an AWS subnet into a different availability zone?

I created two subnets without any preference of the availability zone(AZ). So, now I have two subnets in one AZ. I know that I can extend the VPC and create new subnets but I simply want to move a subnet into a different zone. Is there any way I can move a subnet to a different AZ on AWS?

like image 689
bot Avatar asked Mar 20 '19 18:03

bot


People also ask

Can we change availability zone of subnet in AWS?

To add an Availability Zone Select the check box next to an existing group. A split pane opens up in the bottom of the Auto Scaling groups page. On the Details tab, choose Network, Edit. In Subnets, choose the subnet corresponding to the Availability Zone that you want to add to the Auto Scaling group.

Can subnets be in different availability zones?

When you create a subnet, you specify the IPv4 CIDR block for the subnet, which is a subset of the VPC CIDR block. Each subnet must reside entirely within one Availability Zone and cannot span zones.

How many subnets can be in an Availability Zone?

AZ can have more than one subnets. However, there is a soft limit of 200 subnets per AZ.


1 Answers

This is not possible.

An Availability Zone is nominated when the Subnet is created. It is not possible to change the AZ on a Subnet.

You should either create another subnet, or delete the subnet and recreate it in a different AZ.

like image 128
John Rotenstein Avatar answered Oct 18 '22 19:10

John Rotenstein