Home > Software design >  RDS having 3 subnets of one AZ in AWS
RDS having 3 subnets of one AZ in AWS

Time:03-08

I have an existing RDS instance, from the RDS console, I see that the instance has a subnet group of 6 subnets -- of which, 3 subnets (A1, A2, A3) from us-east-1a and 3 subnets (B1, B2, B3) from us-east-1b.

My question is, how can I tell exactly which subnet that the instance is sitting in (for example, if the instance is within AZ of us-east-1a)? And if the instance fails over to us-east-1b, which subnet that the instance will be failed over to?

CodePudding user response:

The Amazon RDS management console displays the current Region & AZ:

Amazon RDS management console

However, it does not display where it will be 'failed over to' because that is determined at the time of failover.

CodePudding user response:

Here is saying without any details:

Amazon RDS chooses a subnet and an IP address within that subnet to associate with your DB instance. The DB instance uses the Availability Zone that contains the subnet.

Not sure if someone knows internal AWS logic. But you able to check what subnet RDS using after failover. Just try to ping Endpoint.

For example if you have two subnets B1 - 10.0.1.0/24 and B2 - 10.0.2.0/24 and result of ping will be

ping db_name.abcdefghi.ap-northeast-1.rds.amazonaws.com
PING db_name.abcdefghi.ap-northeast-1.rds.amazonaws.com (10.0.1.131) 56(84) bytes of data.

That means that DB is sitting on B1.

  • Related