Troubleshooting Internet Connectivity
What you'll learn: You'll master the systematic approach to diagnosing why cloud resources can't reach the internet or be reached from it.
Why Internet Connectivity Breaks
When a cloud instance can't connect to the internet (or vice versa), the problem typically lives in one of three layers: routing, network address translation (NAT), or security filtering. Think of it like a letter getting lost—it could be missing postage (no route), the return address is wrong (NAT issue), or the mailroom rejected it (security rules).
The Troubleshooting Checklist
1. Verify Route Tables
Check that your subnet has a route pointing 0.0.0.0/0 (all internet traffic) to an Internet Gateway for public subnets or a NAT Gateway for private subnets. Missing or incorrect routes mean traffic never knows where to go.
2. Confirm NAT Configuration
For private subnet instances, ensure:
- A NAT Gateway exists and is available (not failed)
- The NAT Gateway sits in a public subnet with internet access
- Your private subnet's route table points to this NAT Gateway
3. Inspect Security Groups
Security groups act as firewalls. Verify:
- Outbound rules allow traffic to your destination (typically
0.0.0.0/0on required ports) - Inbound rules permit responses if you're hosting services
- Security groups are stateful—responses to allowed outbound traffic automatically return
4. Check Network ACLs
Unlike security groups, Network ACLs are stateless. Both inbound AND outbound rules must explicitly allow traffic in both directions.
5. Validate Resource Configuration
- Does the instance have a public IP or Elastic IP (if in a public subnet)?
- Is the instance even running?
Key Takeaway: Internet connectivity issues almost always stem from misconfigured routes, missing NAT components, or overly restrictive security rules—check routing first, NAT second, then security layers.