Here is an AWS typical VPC, which is composed of the following components
- two subnets
- Internet Gateway
- Route table
- Instances
Imagine a scenario
step1, instance (private IP 172.31.0.5) in subnet1 send a packet to IP 172.31.16.5 (in subnet2).
step2, the packet reaches the route table, the route table redirect the packet to the target local.
step3, Some magic happens.
step4, instance(172.31.16.5) receives the packet.
The following questions are about the magic in step3.
- What does local mean in this place? the VPC network?
- what's the topology of vpc and subnets?
- How does route table know which subnet should be the right subnet to receive this packet?
- How does route table know which instance should be the right instance to receive this packet?
- How does route table redirect the packet to the instance(172.31.16.5)?
- If I would like to better understand it, which kind of background knowledge should I learn first?
