ANS-C01 Question 172
Single answerYour company has two VPCs, VPC-A and VPC-B, in different AWS accounts. Both VPCs use the CIDR block 10.0.0.0/16, resulting in overlapping IP address ranges. You need to establish connectivity between the two VPCs to enable communication between applications deployed in each. How can you achieve this without altering the existing CIDR blocks?
- A
Use AWS PrivateLink to create an interface endpoint in each VPC for communication.
- B
Set up a VPC peering connection between the two VPCs and configure route tables to allow traffic.
- C
Deploy a Transit Gateway and configure NAT Gateway in each VPC to facilitate communication.
- D
Use a VPN connection with NAT on both sides to translate overlapping IP ranges into unique IP ranges.
Show answer and explanation
Correct answer: D
Explanation
When two VPCs have overlapping CIDR blocks, directly connecting them using methods like VPC peering or Transit Gateway is not feasible due to conflicting routes. Using a VPN connection with NAT on both sides resolves this by translating the overlapping IP ranges into unique ones, ensuring proper routing and communication. This approach avoids the need to reconfigure or modify the existing CIDR blocks in either VPC.
- A. Incorrect.
AWS PrivateLink does not support direct communication between two VPCs with overlapping IP ranges. It is typically used for connecting to AWS services or shared applications without exposing the entire VPC.
- B. Incorrect.
VPC peering does not support overlapping CIDR blocks because route table entries would conflict due to the identical IP ranges.
- C. Incorrect.
While a Transit Gateway can connect multiple VPCs and support overlapping CIDR blocks, it does not natively resolve the overlap issue. NAT or additional IP address translation is required to handle overlaps effectively.
- D. Correct.
Using a VPN connection with NAT on both sides allows you to translate the overlapping IP ranges into unique ones, enabling successful routing and communication between the two VPCs.