Skip to content

what is the purpose for Transit Gateway CIDR blocks

0

"Working with Route Tables in AWS Transit Gateway" mentions "Transit Gateway places a network interface in the connectivity subnet using one IP address from the subnet." If a VPC contains multiple subnets, which subnet does Transit Gateway place that network interface ? Any criteria to select ? If I want the Transit Gateway to select a particular subnet to place the network interface, I configure Transit Gateway CIDR blocks to achieve this ? If I configure multiple blocks, what will happen ?

thanks !!

asked 2 years ago2.1K views
2 Answers
1
Accepted Answer

Hello.

Select the subnet to link when creating a TransitGateway attachment.
A TransitGateway attachment ENI will be created in the selected subnet, and you will be able to communicate with multiple VPCs etc. via that ENI.
https://docs.aws.amazon.com/vpc/latest/tgw/tgw-vpc-attachments.html#create-vpc-attachment

For Subnet IDs, select one subnet for each Availability Zone to be used by the transit gateway to route traffic. You must select at least one subnet. You can select only one subnet per Availability Zone.

TransitGateway best practices are described in the following documents:
It also describes how to create a subnet.
https://docs.aws.amazon.com/vpc/latest/tgw/tgw-best-design-practices.html

Use a separate subnet for each transit gateway VPC attachment. For each subnet, use a small CIDR, for example /28, so that you have more addresses for EC2 resources. When you use a separate subnet, you can configure the following:

EXPERT
answered 2 years ago
EXPERT
reviewed 2 years ago
EXPERT
reviewed 2 years ago
0

thanks so much for such a quick response.

answered 2 years 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.