Course contentsShow
← Cloud and Infrastructure
Lesson 217 of 2,9894. Cloud Networking BasicsFree lesson

VPC Peering Routing and Limitations

Understand routing requirements, non-transitive peering behavior, and CIDR overlap restrictions.

VPC Peering Routing and Limitations

What you'll learn: How traffic routes between peered VPCs and the key restrictions that prevent certain connection patterns.

How Routing Works in VPC Peering

When you establish a VPC peering connection, traffic doesn't automatically flow between the VPCs. You must update route tables in each VPC to direct traffic destined for the other VPC's CIDR range through the peering connection.

Think of it like adding specific directions to a map: "If you want to reach addresses in VPC B (10.1.0.0/16), use the peering connection as your gateway."

Each subnet's route table needs an entry pointing to the peer VPC's CIDR block, with the peering connection as the target. Without these explicit routes, instances won't know how to reach the peered network.

Non-Transitive Peering Behavior

Here's a critical limitation: peering is not transitive.

Imagine three VPCs: A, B, and C. If A peers with B, and B peers with C, traffic cannot flow from A to C through B. It's like having a friend-of-a-friend—you can't assume automatic access.

Each direct relationship requires its own peering connection. If A needs to communicate with C, you must create a separate A↔C peering connection.

CIDR Overlap Restrictions

You cannot peer VPCs with overlapping CIDR blocks. If VPC A uses 10.0.0.0/16 and VPC B also uses 10.0.0.0/16, peering is impossible—the networks can't distinguish which "10.0.1.5" you're trying to reach.

This is why planning your IP address ranges (CIDR blocks) before creating VPCs is crucial. Think ahead about which VPCs might need to communicate.

Key Takeaway: VPC peering requires manual route table updates, is non-transitive (no multi-hop routing), and cannot connect VPCs with overlapping IP ranges—careful CIDR planning is essential.