InterviewHubPRO
Section Overview
Q10

Question 10 of 65

Part 2: Networking, VPC & Traffic Routing (6 - 20)

15%
AWS Cloud Architecture•Part 2: Networking, VPC & Traffic Routing (6 - 20)

VPC Peering vs AWS Transit Gateway vs PrivateLink.

In Simple Words:

  • VPC Peering: Direct 1-to-1 connection between two VPCs. Non-transitive (A to B and B to C does not connect A to C).
  • Transit Gateway: Centralized hub-and-spoke router connecting hundreds of VPCs and on-premises datacenters with transitive routing.
  • PrivateLink: Privately exposes specific microservices or AWS APIs between VPCs via private ENIs without peering the entire networks.
bash
# Create a Transit Gateway attachment via AWS CLI:
aws ec2 create-transit-gateway-vpc-attachment   --transit-gateway-id tgw-0123456789abcdef0   --vpc-id vpc-12345678   --subnet-ids subnet-aaa subnet-bbb