ladderlore
  • Type a service name, like S3 or IAM.

Concept · Builds on CLF-C02

Subnets, route tables, gateways and NAT

Design public, private and isolated tiers across Availability Zones, and pick the right gateway for each path.

You know from Cloud Practitioner

  • A subnet lives in one Availability Zone. A route table decides where its traffic goes.
  • A route to an internet gateway makes a subnet public.
  • A NAT gateway lets private resources reach out, and keeps outside connections from coming in.
Read the Cloud Practitioner lesson
  • Public

    Route to internet
    Internet gateway
    Holds
    Load balancer, NAT gateway
  • Private

    Route to internet
    Outbound only, through NAT
    Holds
    Application servers
  • Isolated

    Route to internet
    None, local routes only
    Holds
    Databases
Three tiers, three routing rules.
  • Internet gateway

    Direction
    Two ways, public IPs
    Note
    Free, scales on its own
  • NAT gateway

    Direction
    Outbound IPv4 only
    Note
    Managed, one per AZ (or one Regional gateway)
  • NAT instance

    Direction
    Outbound IPv4 only
    Note
    You run and patch it
  • Egress-only IGW

    Direction
    Outbound IPv6 only
    Note
    Blocks inbound
Which gateway for which path.

1 / 2

  • Internet gateway

    Direction
    Two ways, public IPs
    Note
    Free, scales on its own
  • NAT gateway

    Direction
    Outbound IPv4 only
    Note
    Managed, one per AZ (or one Regional gateway)
  • NAT instance

    Direction
    Outbound IPv4 only
    Note
    You run and patch it

2 / 2

  • Egress-only IGW

    Direction
    Outbound IPv6 only
    Note
    Blocks inbound
Which gateway for which path.

What it is

A secure VPC has three tiers in at least two Availability Zones. The public tier holds load balancers and NAT gateways. The private tier holds application servers, which reach the internet only through NAT. The isolated tier holds databases. Its route table has only the local route, plus endpoints if needed.

What it is

A zonal NAT gateway is managed and lives in one AZ. If that AZ fails, private subnets in other AZs lose their route. So create one zonal NAT gateway per AZ and point each AZ’s private route table to its own. This also avoids cross-AZ data charges. AWS also offers a Regional NAT gateway. It is one gateway that grows across AZs by itself. The exam may still expect one NAT gateway per AZ.

What it is

A NAT instance is the old do-it-yourself option. It costs less at tiny scale, but you patch it and size it. You must also turn off its source/destination check, because it forwards traffic that is not for itself. An egress-only internet gateway gives IPv6 resources outbound access and blocks inbound connections.

VPC Flow Logs record accepted and rejected IP traffic for a VPC, subnet or network interface. They go to Amazon CloudWatch Logs, Amazon S3 or Amazon Data Firehose. They show who talked to whom, not the content.

Remember

  • Three tiers: public (load balancer, NAT), private (application), isolated (database).
  • Use at least two AZs for every tier.
  • One zonal NAT gateway per AZ for resilience and to avoid cross-AZ charges. A Regional NAT gateway is one gateway across AZs.
  • Private subnet default route: 0.0.0.0/0 to the NAT gateway. Isolated subnet: no default route.

Remember

  • Egress-only internet gateway is for IPv6 outbound only.
  • Flow Logs show traffic metadata, not packet contents.

On the exam

  • “Private instances need outbound internet and the design must survive an AZ failure” points to one NAT gateway per AZ.
  • “IPv6 instances must reach the internet but not be reachable from it” points to an egress-only internet gateway.
  • “Find out which IPs were rejected on a subnet” points to VPC Flow Logs.