Module 2 of 5
๐Ÿ“Š IP Addressing & Subnetting
1

IPv4 Addressing

IPv4 Basics

An IPv4 address is a 32-bit number expressed in dotted-decimal notation (e.g., 192.168.1.10). Divided into a network portion and a host portion, determined by the subnet mask.

IPv4 Address Classes (Classful)

ClassRangeDefault MaskUse
A1.0.0.0 โ€“ 126.255.255.255/8 (255.0.0.0)Large networks
B128.0.0.0 โ€“ 191.255.255.255/16 (255.255.0.0)Medium networks
C192.0.0.0 โ€“ 223.255.255.255/24 (255.255.255.0)Small networks (up to 254 hosts)

Private IP Ranges (RFC 1918)

  • 10.0.0.0/8 โ€” Class A private range
  • 172.16.0.0/12 โ€” Class B private range (172.16.0.0 โ€“ 172.31.255.255)
  • 192.168.0.0/16 โ€” Class C private range
2

CIDR & Subnetting

CIDR Notation

Classless Inter-Domain Routing (CIDR) uses a prefix length (e.g., /24) instead of classful subnet masks. The prefix length specifies how many bits are the network portion.

Subnetting Formula

  • Number of subnets = 2s where s = subnet bits borrowed.
  • Hosts per subnet = 2h โ€“ 2 where h = host bits (subtract 2 for network address and broadcast).

Common Subnet Reference

PrefixSubnet MaskUsable Hosts
/24255.255.255.0254
/25255.255.255.128126
/26255.255.255.19262
/27255.255.255.22430
/28255.255.255.24014
/30255.255.255.2522 (point-to-point links)

Finished reading? Take the quiz to earn 100 points.

Take Quiz โ†’