Subnetting is a very important topic for both the ICND1 and ICND2 exam and is also needed to know in order to be a good network administrator.
Subnetting can be a topic difficult to understand at first, but with practice it can become automatic and easy to do. Before you can fully understand subnetting you will need to know these important key fundamental topics that are discussed in the following articles:
IP Addresses
IP Address Classes
How to Convert an IP Address to Binary
Designing a Local Area Network
Classless Inter-Domain Routing
…Now that you know what an IP Address and how they are represented in binary we can talk more about subnetting.
Why Subnetting is Important
Subnetting is important because it keeps us from wasting valuable IP Addresses. Here is a quick example of what would happen before subnetting when only classful routing was possible:
A company would be assigned a class B address like 172.1.0.0. With a Class B IP Address there over 65,000 IP Addresses that can be used. Anywhere from 172.1.0.1 all they way to 172.1.255.255. If this company only needed 200 of these IP address the other 64,800 would go to waste
With subnetting these IP Addresses can be broken up into sections to so that we don’t waste any.
How To Split an IP Address Into Smaller Subnets
Lets say that an ISP has been assigned the IP Address range of 192.168.1.0/24. This means that the ISP has 256 IP Addresses that it can use. The ISP decides to break up this range into smaller ranges so that it can sell off smaller chunks to business that will each need 10 to 14 IP Addresses that it can use.
Here is our original subnet mask for the 192.168.1.0 IP Address in binary
11111111.11111111.11111111.00000000
If you we look at the last octet (the one with all zeros): I’m going to break it up and show each places decimal value above it so that we can figure out where to subnet it in order to get the ranges that we are looking for.
128…64…32…16…8….4…2….1
0……0……0…..0….0….0…0….0
We are looking for ranges between 10 to 14 so breaking up the subnets by 16′s will be ideal. To do this put 1′s where all the 0′s are before you get to the 16, like this:
128…64…32…16…8…4…2…1
1…….1…..1…..1….0…0…0…0
To find out how big the subnets are going to be look at the top number above the first 0 that you come to. In this case it as a 16.
So, our original mask was a /24 mask. We get this by adding up all of the 1′s in the original subnet mask. There are 3 octets full of 1′s and each octet has 8 binary numbers so you can easily calculate the prefix by multiplying 8×3 which equals 24. Now to get our new subnet mask prefix we simply add the number of ones to our original amount. In this case we added 4 1′s so our new mask is 24 + 4 which equals 28. Our new prefix is /28.
Now that we have our new subnet mask lets break it up into the different subnets that we can assign out.
“/28″ IP Address Ranges (Incrementing by 16)
1. 192.168.1.0 – 192.168.1.15
2. 192.168.1.16 – 192.168.1.31
3. 192.168.1.32 – 192.168.1.47
4. 192.168.1.48 – 192.168 1.63
5. 192.168.1.64 – 192.168.1.79
6. 192.168.1.80 – 192.168.1.95
7. 192.168.1.96 – 192.168.1.111
8. 192.168.1.112 – 192.168.1.127
9. 192.168.1.128 – 192.168.1.143
10. 192.168.1.144 – 192.168.1.159
11. 192.168.1.160 – 192.168.1.175
12. 192.168.1.176 – 192.168.1.191
13. 192.168.1.192 – 192.168.1.207
14. 192.168.1.208 – 192.168.1.223
15. 192.168.1.224 – 192.168.1.239
16. 192.168.1.240 – 192.168.1.255
From the above table you can see that by creating this /28 subnet from our /24 subnet we now have 16 different ranges of IP Address that we can assign out to different businesses each with 16 IP Addresses.
Assigning Subnets
Now let’s say that we have 3 businesses that need to be assigned IP Addresses. For the first business we can assign the first range of IP Addresses:
192.168.1.0 – 192.168.1.15
Let’s write them all out:
192.168.1.0 —> Network Address
192.168.1.1
192.168.1.2
192.168.1.3
192.168.1.4
192.168.1.5
192.168.1.6
192.168.1.7
192.168.1.8
192.168.1.9
192.168.1.10
192.168.1.11
192.168.1.12
192.168.1.13
192.168.1.14
192.168.1.15 —> Broadcast Address
Each range of IP Addresses actually only has 14 usable IP Addreses that can be used. As you can see from the above table the first IP Address is reserved as the Network Address for that range. The last IP Address is reserved as the Broadcast Address for that range. Every range has to have a Network Address and a Broadcast Address so they cannot be use to assign to hosts.
For the next 2 businesses we can assign them the next two ranges:
192.168.1.16 – 192.168.1.31
192.168.1.32 – 192.168.1.47
This process can be repeated for the rest of the ranges. If needed by one of the businesses, they too can break up their IP Address range into even smaller subnets.
Related Articles:
CIDR
Related Topics:
ICND1 Study Guide – The Fastest Way To Get Cisco Certified Guaranteed!