Understanding Variable Length Subnet Masking
Defining Variable Length Subnet Masking
With classful subnetting, all subnets have the identical number of host addresses. This could present issues if you need certain subnets to have a small number of IP addresses, and you need other subnets to have a large number of IP addresses. The solutions listed below; to solving this issue does not however optimize the network configuration. This is mostly due to IP addresses being wasted:
- If you require a large number of host addresses, you can create subnets that have numerous numbers of host addresses.
- If you require a small number of host addresses, you can create subnets that have small numbers of host addresses.
Previously, a single subnet mask was used in the entire network, and was shared by all hosts in that particular network. When one subnet mask is used, and the network is divided into subnets, then all subnets have the identical number of host addresses.
Variable length subnet masks (VLSMs) allow subnets to be further subnetted, and also enable routers to handle different subnet masks. VLSMs provide the flexibility needed to optimize the network configuration by allowing you to configure network subnets that meet the requirements of your organization. No IP addresses are wasted. VLSMs (nonclassful subnetting) can be defined as the process whereby which subnets are divided into smaller segments of various sizes. The name used to describe the process wherein subnets are continuously subdivided, is recursive subnetting.
For VLSM to allow subnets to be further subnetted, it utilizes the subnet mask to distinguish between the network address and the host address of the IP address. The process of dividing a subnet into further segments starts with the subnet mask used on the original subnet. The default subnet mask is not the starting point.
When you use VLSM to divide a network into different sized subnets, a definite pattern of subnet IDs with trailing 0s have to be used. The trailing 0s actually prevent the subnet address spaces from overlapping with each other. With a Class C network, a maximum of seven subnets can be defined. This concept is illustrated below:
- Subnet 1:
- Subnet ID: 0
- Subnet Mask: 255.255.255.128
- Hosts per Subnet: 126
- Subnet 2:
- Subnet ID: 10
- Subnet Mask: 255.255.255.192
- Hosts per Subnet: 62
- Subnet 3:
- Subnet ID: 110
- Subnet Mask: 255.255.255.224
- Hosts per Subnet: 30
- Subnet 4:
- Subnet ID: 1110
- Subnet Mask: 255.255.255.240
- Hosts per Subnet: 14
- Subnet 5:
- Subnet ID: 11110
- Subnet Mask: 255.255.255.248
- Hosts per Subnet: 6
- Subnet 6:
- Subnet ID: 111110
- Subnet Mask: 255.255.255.252
- Hosts per Subnet: 2
- Subnet 7:
- Subnet ID: 111111
- Subnet Mask: 255.255.255.252
- Hosts per Subnet: 2
From the above illustration, you can notice that the last two subnets, Subnet 7 and Subnet 6 are the same size. Subnet 7 is differentiated by a subnet ID that has all 1s. No trailing 0s are used to define Subnet 7. You can utilize this configuration at any subnet level to replace each of the subnets beneath that particular subnet.
While RFC 1812 allows you to use subnets that are all 0s or all 1s, you should first verify that each host and router on your network supports this particular configuration. Even today, not all hosts and routers support RFC 1812. Before you can implement subnets with all 0s or all 1s, you have to meet the following requirements:
- A routing protocol which supports RFC 1812 must be running within your network environment. Routing protocols that support RFC 1812 are:
- Border Gateway Protocol version 4 (BGPv4)
- Open Shortest Path First (OSPF)
- Routing Information Protocol version 2 (RIPv2)
- You have to configure your hosts and routers to support all 0s or all 1s subnets. If you have hosts and routers running Windows Server 2003, the use of 0s or all 1s subnets is automatically supported. You do not need to perform any further configuration.
|
Bookmark Understanding Variable Length Subnet Masking

