Subnetting (FLSM & VLSM) – Complete Guide
🔹 Subnetting Basics
✅ What is Subnetting?
Subnetting divides a larger IP network into smaller subnetworks (subnets), improving network performance, security, IP address usage, and simplifying management.
🔸 Purpose and Advantages:
- Efficient utilization of IP addresses.
- Reduced broadcast traffic.
- Easier troubleshooting.
- Enhanced security via network isolation.
🔹 IP Address Structure
An IPv4 address consists of two parts:
- Network Portion: Identifies the network.
- Host Portion: Identifies individual devices.
✅ Classes and Default Masks
Class | Range | Default Mask |
---|---|---|
A | 0.0.0.0 – 127.255.255.255 | 255.0.0.0 |
B | 128.0.0.0 – 191.255.255.255 | 255.255.0.0 |
C | 192.0.0.0 – 223.255.255.255 | 255.255.255.0 |
🔹 Subnet Mask
A subnet mask defines the network and host portions. Written as dotted decimal (e.g., 255.255.255.0).
🟩 Fixed-Length Subnet Mask (FLSM)
✅ Definition:
FLSM uses the same subnet mask for all subnets, creating equal-sized networks.
✅ FLSM Example Problem:
Subnet 192.168.10.0/24 into 4 equal subnets:
Subnet | Network ID | Usable Hosts | Broadcast Address |
---|---|---|---|
1 | 192.168.10.0/26 | .1 – .62 | .63 |
2 | 192.168.10.64/26 | .65 – .126 | .127 |
3 | 192.168.10.128/26 | .129 – .190 | .191 |
4 | 192.168.10.192/26 | .193 – .254 | .255 |
🟦 Variable-Length Subnet Mask (VLSM)
✅ Definition:
VLSM allows subnets of different sizes within the same network, providing efficient IP address allocation.
✅ VLSM Example Problem:
Given 192.168.20.0/24, subnet it as:
Subnet | Hosts Required | Subnet Mask | CIDR | Usable Hosts | Subnet Range |
---|---|---|---|---|---|
A | 100 | 255.255.255.128 | /25 | 126 | 192.168.20.0 – .127 |
B | 50 | 255.255.255.192 | /26 | 62 | 192.168.20.128 – .191 |
C | 10 | 255.255.255.240 | /28 | 14 | 192.168.20.192 – .207 |
📘 CIDR & Supernetting
- CIDR: Allows flexible subnet masks (e.g., /24, /26).
- Supernetting: Combines multiple networks into one larger network for route summarization.
🎯 When and How to Use:
Technique | Use-case Scenario |
---|---|
FLSM | Simple networks, equal-sized subnets. |
VLSM | Complex networks with different-sized subnets. |
CIDR | Internet routing and ISP environments. |
Supernetting | Route summarization to reduce routing table size. |
✅ Exercises
Exercise 1: FLSM Subnetting
Subnet 192.168.10.0/24 into 4 equal subnets:
Subnet # | Network ID | Usable IP Range | Broadcast Address |
---|---|---|---|
1 | |||
2 | |||
3 | |||
4 |
Exercise 2: VLSM Subnetting
Given 172.16.20.0/24, subnet to meet the following:
Subnet | Required Hosts | Network ID | CIDR | Subnet Mask | Usable IP Range | Broadcast Address |
---|---|---|---|---|---|---|
A | 50 | |||||
B | 30 | |||||
C | 12 | |||||
D | 6 |