Chapter 3
IP and Addressing
The addressing layer: how IPv4 packets are built, how you carve a block into subnets, and how private space, NAT, IPv6, and DHCP make the 32-bit world keep working.
Layer 2 moves frames inside one segment. Everything in this chapter is about layer 3: the addresses that let a packet leave its segment and cross the internet, and the machinery that keeps a 32-bit address space — long since exhausted — usable in practice. You start with the IPv4 datagram itself, learn to split a block into subnets with CIDR math, then work through the four mechanisms that paper over IPv4 scarcity: private addressing, NAT, IPv6, and DHCP.
Subnetting is the load-bearing skill here. Every VPC you size, every firewall rule you scope, every route you write depends on getting prefix math right, and overlapping CIDR ranges are one of the few mistakes the network makes genuinely unfixable without renumbering. Get the addressing layer wrong and nothing above it routes — so this is where the careful counting pays off.
Topics in This Chapter
TTL, protocol, DSCP/ECN, fragmentation. Connectionless, best-effort, and carrying exactly what a router needs to forward and nothing about reliability./24 actually means. A worked example of splitting a block and counting usable hosts — the single most-used hands-on networking skill.10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16 — plus loopback, link-local, and CGNAT. Why everyone overlaps on 10.0.0.0/8 and regrets it.:: compression, the /64 subnet norm, and SLAAC autoconfiguration with no broadcast. Enough space to abandon NAT — and why you still run dual-stack.