This tutorial explains Subnetting step by step with examples. Learn what IP Subnetting is, Subnetting components such as Network ID, Broadcast ID, network portion, host portion, FLSM, VLSM, Subnetting eligible bits, reserved network bits and host bits including Subnetting rules in detail.
What is IP Subnetting?
IP Subnetting is a process of dividing a large IP network in smaller IP networks. In Subnetting we create multiple small manageable networks from a single large IP network.
Let’s take an example.
To best utilize available addresses if we put more than 16000000 hosts in a single network, due to broadcast and collision, that network will never work. If we put less hosts then remaining addresses will be wasted.
Subnetting provides a better way to deal with this situation. Subnetting allows us to create smaller networks from a single large network which not only fulfill our hosts’ requirement but also offer several other networking benefits.
I have already explained the advantages of Subnetting along with why Subnetting is necessary in previous parts of this tutorial. In this part, I will mainly focus on Subnetting components and terminology.
This tutorial is the third part of the article “IP Subnetting in Computer Network Step by Step Explained with Examples”. Other parts of this article are following.
This tutorial is the first part of the article. It explains IP addressing and network addressing such as IP address, subnet mask, IP address types and IP classes in detail.
This tutorial is the second part of the article. It explains what Subnetting is and why it is necessary in computer network along with the advantages of Subnetting.
This tutorial is the fourth part of the article. It explains how to solve or answer any Subnetting related question in less than a minute with 50+ Subnetting examples.
This tutorial is the fifth part of the article. It explains what VLSM Subnetting is and how it is done step by step including differences between FLSM Subnetting and VLSM Subnetting.
This tutorial is the sixth part of the article. It explains VLSM Subnetting examples for Cisco exams and interviews.
This tutorial is the last part of the article. It explains Supernetting in detail with examples.
Network portion vs Host portion
Identifying network portion and host portion in an IP address is the first step of Subnetting. Subnetting can only be done in host portion. Subnet mask is used to distinguish the network portion from host portion in an IP address.
An IP address and a subnet mask both collectively provide a numeric identity to an interface. Both addresses are always used together. Without subnet mask, an IP address is an ambiguous address and without IP address a subnet mask is just a number.
Both addresses are 32 bits in length. These bits are divided in four parts. Each part is known as octet and contains 8 bits. Octets are separated by periods and written in a sequence.
Subnet mask assigns an individual bit for each bit of IP address. If IP bit belongs to network portion, assigned subnet mask bit will be turned on. If IP bit belongs to host portion, assigned subnet mask bit will be turned off.
There are two popular notations to write the IP address and Subnet mask; Decimal notation and Binary notation.
In decimal notation, a value range 1 to 255 represents a turned on bit while a value 0 (zero) represents a turned off bit.
In binary notation, 1 (one) represents a turned on bit while 0 (zero) represents a turned off bit.
Examples of IP address with subnet mask in binary format
00001010.00001010.00001010.00001010 11111111.00000000.00000000.00000000 10101100.10101000.00000001.00000001 11111111.11111111.00000000.00000000 11000000.10101000.00000001.00000001 11111111.11111111.11111111.00000000
Examples of IP address with subnet mask in decimal format
10.10.10.10 255.0.0.0 220.127.116.11 255.255.0.0 192.168.1.1 255.255.255.0
In above examples network portion is formatted in bold text.
Reserve IP classes, network bits and host bits
Each IP address belongs to a predefined IP class. There are five predefined IP classes; A, B, C, D and E. From these classes, class D and E are reserved and cannot be used in Subnetting.
To learn more about IP address and its classes, you can see this tutorial.
It explains IP address, IP classes, Types of IP address, Private IP address, Public IP address and much more in detail.
In class A, B and C: –
- First 8, 16 and 24 bits are reserved for network portion respectively.
- Last 2 bits (31 & 32) are reserved for host portion.
Reserved network bits and host bits cannot be used in Subnetting.
|IP Class||First IP Address of class||Last IP Address of class||Default Subnet Mask||Default Network bits||Host bits||Reserved host bits|
|A||0.0.0.0||127.255.255.255||255.0.0.0||First 8 bits||9 to 30||31, 32|
|B||18.104.22.168||22.214.171.124||255.255.0.0||First 16 bits||17 to 30||31, 32|
|C||192.0.0.0||126.96.36.199||255.255.255.0||First 24 bits||25 to 30||31, 32|
Subnetting eligible host bits
After excluding reserved network bits and host bits, remaining bits are considered as Subnetting eligible host bits.
Subnetting can be done only in Subnetting eligible bits.
A subnet is a single small network created from a large network. In Subnetting we break a single large network in multiple small networks. These networks are known as subnets.
Network address and Broadcast address
In each network there are two special addresses; network address and broadcast address. Network address represents the network itself while broadcast address represents all the hosts which belong to it. These two addresses can’t be assigned to any individual host in network. Since each subnet represents an individual network, it also uses these two addresses.
In simple language, in a single network only two IP addresses will be used for these addresses. But if we breaks this network in two small networks then four IP addressed will be used for these addresses.
Network address and broadcast address are also known as Network ID and broadcast ID respectively.
Valid host addresses
All addresses between Network address and Broadcast address are known as valid host addresses. Only valid host addresses can be assigned to the devices in a network. These devices include end user devices such as computes, laptops, tablets, smartphones, IP phones, servers, printers, terminals, IP camera and networking devices such switches, routers, firewalls and proxy servers. In short, any device that uses IP protocol for data transferring needs a valid host address.
Block size is the sum of network address, valid host addresses and broadcast address. For example, if in a network there are 6 valid hosts than block size of that network is 8 (1 network address + 6 valid hosts + 1 broadcast address).
Power of 2
An IP address is built from the various combinations of IP bits. Understanding how many combinations the number of bits provides or to get the number of combinations how many bits we need is the second essential step of Subnetting.
- A combination of all 32 represents a unique IP address.
- A combination of network bits in IP address represents the number of networks or subnets.
- A combination of host bits in IP address represents the number of total hosts.
To know how many combinations the number of bits provides or to get the number of combinations how many bits are required, we use the power of 2.
For example, to break a single large network in 4 subnets, we need 2 (22 = 4) Subnetting bits. This way if we have 3 Subnetting bits, we can make 8 (23 = 8) additional networks.
Following table lists the power of 2 till 32.
In 2X the X is the number of bits.
Subnetting always flows in single direction (left to right) without skipping any bit. This simple rule gives us the exact location of Subnetting bits in an address space. Let’s take an example.
A class C network is subnetted in 4 subnets. Find the number of host bits used in Subnetting and their location in address space.
To create 4 subnets we need to 2 (22 = 4) Subnetting eligible host bits.
Since in class C network space Subnetting eligible bits starts from 25 and Subnetting always goes from left to right without skipping any bit, the bits used in this network are 25 and 26.
It’s a compact representation of Subnet mask. In this notation a slash (/) sign and total number of the on bits in subnet mask are written with IP address instead of full Subnet mask.
Following table lists some examples of IP addresses with Subnet mask in all three notations.
|In Slash notation||In binary notation||In decimal notation|
Type of Subnetting
There are two types of Subnetting FLSM and VLSM. In FLSM, all subnets have equal number of host addresses and use same Subnet mask. In VLSM, subnets have flexible number of host addresses and use different subnet mask.
Following figure shows an example of FLSM and VLSM.
FLSM is easy in implementation and simple in operation but wastes a lot of IP addresses. VLSM is hard in implementation and complex in operation but utilizes maximum IP addresses.
Several steps involve in both types of Subnetting. Due to length of this tutorial, I will explain both types of Subnetting individually in next parts of this article.
That’s all for this part. In next part, we will learn how to perform a FLSM Subnetting step by step in detail with practical examples. If you have any suggestion or feedback regarding this tutorial, please let me know. If you like this tutorial, please share it with friends.
Prerequisites for 200-301
200-301 is a single exam, consisting of about 120 questions. It covers a wide range of topics, such as routing and switching, security, wireless networking, and even some programming concepts. As with other Cisco certifications, you can take it at any of the Pearson VUE certification centers.
The recommended training program that can be taken at a Cisco academy is called Implementing and Administering Cisco Solutions (CCNA). The successful completion of a training course will get you a training badge.
Full Version 200-301 Dumps