- Newest
- Most votes
- Most comments
Let's address your questions one by one:
-
Multiple EC2 instances in different subnets within the same VPC are reachable to each other by default. This is because VPCs have a default local route that allows communication between all resources within the VPC, regardless of which subnet they're in.
-
AWS doesn't expose a "system route table" for VPCs. Instead, each subnet in a VPC is associated with a route table, which can be either the main route table or a custom route table. You can view these route tables in the AWS Management Console, CLI, or API.
-
Regarding your specific setup:
- The Transit Gateway (TGW) does install an Elastic Network Interface (ENI) in the Service-VPC with an IP in the 10.1.99.X range.
- After TGW sends packets to Service-VPC, the routing decision is indeed based on the route table associated with the subnet where the packet arrives (in this case, FrontEnd-RT).
- There isn't a separate "system route table" for routing between subnets. The routing between subnets is handled by the local route in each subnet's route table.
-
Regarding pinging 10.1.99.1 from the firewall:
- In theory, you should be able to ping this address if it's within your VPC and there are no security groups or network ACLs blocking the traffic.
- If you can't ping it, potential issues could be: a) Security group rules not allowing ICMP traffic b) Network ACLs blocking the traffic c) The firewall's own configuration preventing the ping
-
The reason 10.1.1.254 treats 10.1.99.1 as local is because they are both within the VPC's CIDR range. The "local" target in a route table refers to any destination within the VPC's CIDR block, not just within the same subnet.
If you're still having issues, you might want to check:
- The security group rules for both the source and destination instances
- The network ACLs for the subnets involved
- The firewall's configuration to ensure it's not blocking the traffic
- The route tables for all subnets involved to ensure they have the correct local route
Remember, while instances in different subnets of the same VPC can communicate by default, this can be restricted by security groups, network ACLs, or custom route tables.
Sources
Subnets for your VPC - Amazon Virtual Private Cloud
Subnet route tables - Amazon Virtual Private Cloud
Achieve multipath load balancing in Amazon VPC using Virtual IPs | AWS for Industries
Relevant content
- AWS OFFICIALUpdated 10 months ago
