intermediate v1 • Updated 7 hours ago

Subnetting & VLSM (Variable Length Subnet Masking)

Subnetting is the practice of dividing a single large IP network into multiple smaller, logically segmented subnetworks (subnets) by borrowing host bits.

Remember This Key Rule

Usable Hosts = \(2^h - 2\). Borrowing bits increases subnets and decreases host capacity per subnet.

In Simple Terms

Instead of wasting a massive block of 254 IP addresses on a two-router point-to-point link, subnetting allows you to chop up address space into exact sizes: a `/30` (2 usable hosts) for router links, a `/26` (62 usable hosts) for HR, and a `/25` (126 usable hosts) for Sales.

Visual Diagram & Flow

.0/26
.1-.62
.64/26
.65-.126
.128/26
.129-.190
.192/26
.193-.254
Why It Matters in Real Networks

Efficient subnetting prevents catastrophic IP address exhaustion, reduces broadcast traffic, and creates clear security perimeters.

How It Works (Technical Breakdown)

Subnet Math Formula: - **Number of Subnets created**: \(2^s\) (where \(s\) is borrowed network bits). - **Number of Usable Hosts per Subnet**: \(2^h - 2\) (where \(h\) is remaining host bits; subtract 2 for Network & Broadcast). - **Block Size (Magic Number)**: \(256 - ext{Subnet Mask Octet}\). **Common CIDR Cheat Sheet**: - `/24`: 255.255.255.0 -> 254 usable hosts (Block: 256) - `/25`: 255.255.255.128 -> 126 usable hosts (Block: 128) - `/26`: 255.255.255.192 -> 62 usable hosts (Block: 64) - `/27`: 255.255.255.224 -> 30 usable hosts (Block: 32) - `/28`: 255.255.255.240 -> 14 usable hosts (Block: 16) - `/29`: 255.255.255.248 -> 6 usable hosts (Block: 8) - `/30`: 255.255.255.252 -> 2 usable hosts (Block: 4) - `/31`: Point-to-point RFC 3021 (2 usable hosts) - `/32`: Single host route (loopback)
Real-World Analogy

Subnetting is like buying a 10,000 sq ft office building floor and building interior walls to create distinct secure offices of different sizes for different teams.

Concrete Example

Divide `192.168.10.0/24` into 4 equal subnets using `/26` (borrow 2 bits, block size = 64): 1. Subnet 1: `192.168.10.0/26` (Hosts .1 - .62, Broadcast .63) 2. Subnet 2: `192.168.10.64/26` (Hosts .65 - .126, Broadcast .127) 3. Subnet 3: `192.168.10.128/26` (Hosts .129 - .190, Broadcast .191) 4. Subnet 4: `192.168.10.192/26` (Hosts .193 - .254, Broadcast .255)

Common Engineering Mistakes & Pitfalls

Forgetting to subtract 2 for the Network ID and Broadcast Address, or confusing bit borrowing with decimal addition.

Concept Mastery Quiz

Test your comprehension with active-recall questions.

1. Which CIDR prefix provides exactly 2 usable host IP addresses, ideal for point-to-point router links?

Active Recall Flashcards

Click each flashcard to reveal the answer and test your memory.

No flashcards created for this topic yet.

Content Versioning

Audit trail of revisions and updates for this knowledge topic.

Version Change Summary Author Timestamp
v1 (Current) Active production content system Sun, Aug 23, 2026 11:09 AM
Searching...
No matching topics found for "".
Type at least 2 characters to search across all topics, protocols, and scenarios.
Navigate with mouse or click ESC to close