Skip to main content

Welcome to a Grasp lesson

Create a free account to keep studying and create your own study path.

Lesson 6

VLSM: Minimizing IP Address Waste

Recommended resources

Hello and welcome to the first lesson of our second module.

In the last module, we focused on the fundamental mechanics of subnetting. You practiced finding network addresses, broadcast addresses, and usable IP ranges, and you mastered the skill of rapidly determining the block size for common prefixes. So far, we've implicitly assumed that when you subnet a larger block, all the resulting smaller networks are the same size. For example, breaking a /24 into eight /27s.

Today, we challenge that assumption. We'll explore why this Fixed Length Subnet Masking (FLSM) approach is often inefficient and introduce a more powerful and flexible method. This lesson will explain how Variable Length Subnet Masking (VLSM) minimizes address waste compared to a fixed-size scheme, a core principle for building the large, efficient network you're aiming for.

1. The Problem: One Size Doesn't Fit All

Imagine you're given the address block 192.168.10.0/24 and asked to create subnets for a small office with the following needs:

  • Engineering Dept: 30 hosts
  • Sales Dept: 12 hosts
  • Server Farm: 5 hosts
  • WAN Link to HQ: 2 hosts (one for each router interface)

Using the fixed-size subnetting method we've worked with so far, you have to find a single subnet size that can accommodate the largest requirement. In this case, the Engineering department needs 30 hosts.

Based on your skills from the last module, you know a /28 provides 14 usable hosts (too small) and a /27 provides 30 usable hosts (just right).

If we use a fixed-size scheme, we are forced to use /27 for every single subnet. Let's see how much waste that creates:

  • Sales (12 hosts): Gets a /27 (30 IPs). 18 IPs wasted.
  • Servers (5 hosts): Gets a /27 (30 IPs). 25 IPs wasted.
  • WAN Link (2 hosts): Gets a /27 (30 IPs). 28 IPs wasted.

This method, known as Fixed Length Subnet Masking (FLSM), was used by older routing protocols but is highly inefficient for modern networks. The following reading explains this concept clearly.

Classful vs Classless vs CIDR vs FLSM vs VLSM

The article 'Classful vs Classless vs CIDR vs FLSM vs VLSM' from Practical Networking clearly defines FLSM and illustrates its inefficiency. Focus on how forcing all subnets to be the same size wastes addresses.

Read the section titled 'FLSM'. The text and diagram demonstrate how using a single subnet size for a topology with varying needs results in poor address utilization.


2. The Solution: Variable Length Subnet Masking (VLSM)

The obvious solution to the wastefulness of FLSM is to use subnets of different sizes, tailored to the specific needs of each network segment. This is precisely what Variable Length Subnet Masking (VLSM) allows you to do.

Let's re-address our office requirements using VLSM:

  • Engineering (30 hosts): Needs 30 usable IPs -> A /27 (30 usable IPs) is perfect.
  • Sales (12 hosts): Needs 12 usable IPs -> A /28 (14 usable IPs) is a great fit.
  • Server Farm (5 hosts): Needs 5 usable IPs -> A /29 (6 usable IPs) works well.
  • WAN Link (2 hosts): Needs 2 usable IPs -> A /30 (2 usable IPs) is the standard choice.

By "right-sizing" each subnet, we've dramatically reduced the number of wasted IP addresses. VLSM treats a large address block not as something to be cut into equal slices, but as a pool of addresses to be allocated in chunks of whatever size is needed.

The same article from Practical Networking provides a direct comparison, showing how VLSM improves efficiency for the exact same topology.

Classful vs Classless vs CIDR vs FLSM vs VLSM

Now, let's look at the solution. This section introduces VLSM and reworks the previous example to show the significant improvement in address efficiency.

Read the section titled 'VLSM'. Compare the VLSM diagram to the FLSM diagram you just reviewed to see the difference in address allocation.

The image below provides a great side-by-side summary of the differences between these two approaches.

FLSM vs. VLSM Comparison
This table directly compares FLSM and VLSM. Note the key differences in the 'Subnet Size' and 'IP Address' rows, highlighting how VLSM's flexibility leads to higher efficiency and less waste.

3. VLSM in a Real-World Context

For the large-scale architecture you aim to design, with multiple buildings and departments, VLSM is not just an option—it's a necessity. The following video frames this concept within a municipal network, a scenario very similar in scale and complexity to your goal.

IPv4 Subnetting - What is VLSM?

This video from telecomTech demonstrates how VLSM is applied in a real-world municipal network, which is a great parallel to designing for a large multi-building company.

Watch from 01:38 to 04:29. The speaker explains how they subdivided a large address block for different buildings and departments, explicitly contrasting the VLSM approach with a wasteful fixed-size scheme.

As you saw in the video, VLSM is fundamental to modern network design. It allows an administrator to take a large block of addresses (like the /21 in the video) and carve it up to perfectly match the needs of different segments, from large user departments to tiny point-to-point links between switches.

This network diagram provides another example of what a final VLSM design can look like across a multi-site organization.

Multiple Sites VLSM Subnetting with Summarization
This diagram shows a multi-site network for an organization with an HQ and two branches. Notice the variety of CIDR prefixes used (/23, /24, /25, /30), each chosen to match the host requirements of that specific LAN or WAN link. This is VLSM in practice.

4. Visualizing the Allocation Process

Thinking of your IP address block as a single resource to be partitioned is key. The best way to implement VLSM is to allocate the largest required subnets first, then fit the smaller ones into the remaining space. This prevents "fragmenting" your address space with small subnets, which can make it difficult to allocate larger blocks later on.

The next video gives an excellent visualization of this process. It shows a /24 block being broken down into various smaller sizes and introduces the "largest to smallest" allocation strategy.

Variable-Length Subnet Mask (VLSM) - Subnetting Mastery - FLSM and VLSM Appendix Part 2 of 2

To understand how to apply VLSM, it helps to see how a large block is carved up. This video from Practical Networking demonstrates the process and introduces the key strategy of allocating from largest to smallest.

Watch from the beginning (00:00) to 08:03. Focus on how the address space is visualized as a large block that gets divided into smaller, variable-sized chunks. Pay close attention to the explanation of why allocating from largest to smallest is the best practice.


Conclusion

In this lesson, you've learned the fundamental difference between fixed and variable-length subnetting and, most importantly, why VLSM is the standard for efficient network design.

Key Takeaways:

  • Fixed Length Subnet Masking (FLSM) assigns the same size subnet to every network segment, which is simple but extremely wasteful if segments have different host requirements.
  • Variable Length Subnet Masking (VLSM) allows you to use a different subnet mask for each network segment, "right-sizing" the allocation to meet specific needs.
  • The primary advantage of VLSM is the significant reduction in wasted IP addresses, which is crucial for scaling and managing large networks.
  • The best practice for applying VLSM is to allocate subnets from the largest required size to the smallest.

You now understand the "why" behind VLSM. In our next lesson, we will focus on the "how." You will be given a set of host requirements and a parent address block, and you will learn to determine the optimal CIDR prefix for each network segment, putting your rapid subnetting skills to practical use.