Subnetting (Classless Addressing)
MD. MONARUL ISLAM
LECTURER, DEPARTMENT OF CSE
DAFFODIL INTERNATIONAL UNIVERSITY
1
2
In classful addressing, a large part of the
available addresses were wasted.
Classful addressing, which is almost obsolete, is
replaced with classless addressing.
Subnetting
Subnetting is the process of Dividing a Single
Network into smaller sub-networks called subnets.
It helps in minimizing the wastage of IP address.
3
Types of Subnetting
Two Types of Subnetting
 Fixed Length Subnetting (FLSM)
 Variable Length Subnetting (VLSM)
* FLSM = Fixed Length Subnet Mask
* VLSM = Variable Length Subnet Mask
4
How subnetting can be done?
 What we do in subnetting?
Converting Host Bits into Network Bits. (Reducing number of host bits)
i.e. Converting 0’s into 1’s
Subnetting can be done based on requirements.
Requirement of Host? 2ℎ-2 >= requirement
Requirement of Network? 2𝑛 >= requirement
Here, h= host bits , n= network bits
5
Fixed Length Subnetting
In Fixed Length Subnetting the length of subnet is fixed and all the
subnets are in equal size.
6
1st Subnet 2nd Subnet
3rd Subnet 4th Subnet
Fixed Length Subnetting
Let’s, consider an IP address 198.168.10.0
Now we have to divide this IP address into 4 subnetwork parts. After
dividing we have to find out the range of IP addresses blocks.
7
Step 1: Calculate the required subnet bit. In this subnetting
process, we will borrow the bit from the host side.
Now here is the question arise, which bits belong to the host side and network side?
We will find it with the help of subnet masks. We are given a Class C IP address and default subnet mask for
Class C is 255.255.255.0
Every octet consists of 8-bit in this case we are having 24 1’s in network bit.
As we know that every binary value having two possible values either 0 or 1. And with one binary we can
make two value and with two binary values, we can make four values. And with three binary value, we can
make 8 values and so on. Which is actually follow the 2 Power Table.
8
Step 1
9
Here, we need to configure 4 subnets for this we need to borrow 2
bits from the host bits and making the MSB of host bit of subnet
mask to 1 as now it will be considered to be Network Bits and the
value we will get,
11111111.11111111.11111111.11000000
From this we can now calculate the subnet mask.
Step 2: Calculating updated subnet mask.
In this step we will be calculating the updated subnet mask.
11111111.11111111.11111111.11000000
255 . 255 . 255 . 192
10
Step 3: Finding the range
We will find the range in this step.
Formula,
Range: (Maximum Subnet Mask – Updated Subnet Mask)
Maximum Subnet Mask is always 255.255.255.255 for every case
Maximum Subnet Mask: 255.255.255.255
Updated Subnet Mask: - 255.255.255.192
0. 0. 0. 63
Here is the range for network we have got is 0.0.0.63
11
Step 4:Divide the whole network with the
help of the range.
Now we will divide the whole network with the help of the range.
First Network Block:
198.168.10. 0
+ 0. 0. 0.63
198.168.10.63
So for this block, Network address will be: 198.168.10.0
Broadcast address will be: 198.168.10.63
First host address will be: 198.168.10.1 (NA+1)
Last host address will be: 198.168.10.62 (BA-1)
12
Step 4
Second Network Block:
198.168.10.64
+ 0. 0. 0.63
198.168.10.127
So for this block, Network address will be: 198.168.10.64
Broadcast address will be: 198.168.10.127
First host address will be: 198.168.10.65
Last host address will be: 198.168.10.126
13
Step 4
Third Network Block:
198.168.10.128
+ 0. 0. 0. 63
198. 168. 10.191
So for this block, Network address will be: 198.168.10.128
Broadcast address will be: 198.168.10.191
First host address will be: 198.168.10.129
Last host address will be: 198.168.10.190
14
Step 4
Forth Network Block:
198.168.10.192
+ 0. 0. 0. 63
198. 168.10.255
So for this block, Network address will be: 198.168.10.192
Broadcast address will be: 198.168.10.255
First host address will be: 198.168.10.193
Last host address will be: 198.168.10.254
Subnet masks will remain same for every network block i.e. 255.255.255.192
15
FLSM Exercises
1. Using FLSM, subnet the class A IP 20.0.0.0/8 as 8 subnets.
2. Using FLSM, subnet the class B IP 172.3.0.0/16 as 4 subnets.
3. Using FLSM, subnet the class C IP 192.168.2.0/24 as 6 subnets.
16
More with Subnetting
When you’ve chosen a possible subnet mask for your network and need to
determine the numbers of subnets, valid hosts, and broadcast addresses of a
subnet that the mask provides, all you need to do is answer five simple
questions:
How many subnets does the chosen subnet mask produce?
How many valid hosts per subnet are available?
What are the valid subnets?
What’s the broadcast address of each subnet?
What are the valid hosts in each subnet?
17
Examples
Given, Network Address = 192.168.2.0
Subnet mask = 255.255.255.128
Now let’s answer the five questions:
How many subnets? => 2𝑥 = number of subnets. x is the number of masked bit, or the 1′s.
Here, 128 = 10000000, the number of 1’s gives 21
subnets. Which means 2 subnets
How many hosts per subnet?
=> 2𝑦 − 2 = 𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 ℎ𝑜𝑠𝑡𝑠 𝑝𝑒𝑟 𝑠𝑢𝑏𝑛𝑒𝑡. y is the number of unmasked bit, or the 0′s.
Here, 128 = 10000000, the number of 0’s gives 27 − 2 hosts. Which means 126 hosts per subnet.
We need to subtract 2 for the subnet address and the broadcast address. Which are not valid hosts.
18
Examples (Cont.)
What are the valid subnets? => 256 – subnet mask = block size, or increment number.
Here, 256 – 128 = 128. Remember we will start at zero and counting our block size, So the
subnets are 0, 128.
What are the broadcast address of each subnet?
The broadcast address is always the number right before the next subnet.
For 1st subnets the Broadcast address is 127 and for 2nd subnet it is 255
What are the valid hosts? => These are the numbers between subnet and broadcast address
19
Subnet 0 128
First Host 1 129
Last Host 126 254
Broadcast 127 255
Exercise
Given, Network Address = 192.168.10.0
Subnet mask = 255.255.255.192
Now Answer the following questions:
How many subnets does the chosen subnet mask produce?
How many valid hosts per subnet are available?
What are the valid subnets?
What’s the broadcast address of each subnet?
What are the valid hosts in each subnet?
20
Exercise
Given, Network Address = 192.168.10.0
Subnet mask = 255.255.255.224
Now Answer the following questions:
How many subnets does the chosen subnet mask produce?
How many valid hosts per subnet are available?
What are the valid subnets?
What’s the broadcast address of each subnet?
What are the valid hosts in each subnet?
21
More Exercises
For more exercises see page no. 118 to page
no. 136 of
CCNA, Study Guide, 6th Edition, TodLammle.
22
Playing with FLSM
Suppose you have a network address of class A and you want to
create 1000 subnets. Which subnet mask will you choose?
Try to answer first then see the next slide.
23
Answer
We know, 2𝑥 = 𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑠𝑢𝑏𝑛𝑒𝑡𝑠
Here number of subnets = 1000
So, 2𝑥 = 1000 , the value of x must be equal to 10. Because 29 = 512. And we need to create 1000
subnets. Where 210 = 1024. So we will take x = 10. That means we need to convert 10 Host bits into
Network bits.
By default the subnet mask of class A network is 255.0.0.0 (11111111.00000000.00000000.00000000)
Now adding 10 bits into network, the subnet mask will become,
11111111.11111111.11000000.00000000
255 . 255 . 192 . 0
So the answer is 255.255.192.0
24
Thank You
25

Fixed Length Subnetting about ip address.pptx

  • 1.
    Subnetting (Classless Addressing) MD.MONARUL ISLAM LECTURER, DEPARTMENT OF CSE DAFFODIL INTERNATIONAL UNIVERSITY 1
  • 2.
    2 In classful addressing,a large part of the available addresses were wasted. Classful addressing, which is almost obsolete, is replaced with classless addressing.
  • 3.
    Subnetting Subnetting is theprocess of Dividing a Single Network into smaller sub-networks called subnets. It helps in minimizing the wastage of IP address. 3
  • 4.
    Types of Subnetting TwoTypes of Subnetting  Fixed Length Subnetting (FLSM)  Variable Length Subnetting (VLSM) * FLSM = Fixed Length Subnet Mask * VLSM = Variable Length Subnet Mask 4
  • 5.
    How subnetting canbe done?  What we do in subnetting? Converting Host Bits into Network Bits. (Reducing number of host bits) i.e. Converting 0’s into 1’s Subnetting can be done based on requirements. Requirement of Host? 2ℎ-2 >= requirement Requirement of Network? 2𝑛 >= requirement Here, h= host bits , n= network bits 5
  • 6.
    Fixed Length Subnetting InFixed Length Subnetting the length of subnet is fixed and all the subnets are in equal size. 6 1st Subnet 2nd Subnet 3rd Subnet 4th Subnet
  • 7.
    Fixed Length Subnetting Let’s,consider an IP address 198.168.10.0 Now we have to divide this IP address into 4 subnetwork parts. After dividing we have to find out the range of IP addresses blocks. 7
  • 8.
    Step 1: Calculatethe required subnet bit. In this subnetting process, we will borrow the bit from the host side. Now here is the question arise, which bits belong to the host side and network side? We will find it with the help of subnet masks. We are given a Class C IP address and default subnet mask for Class C is 255.255.255.0 Every octet consists of 8-bit in this case we are having 24 1’s in network bit. As we know that every binary value having two possible values either 0 or 1. And with one binary we can make two value and with two binary values, we can make four values. And with three binary value, we can make 8 values and so on. Which is actually follow the 2 Power Table. 8
  • 9.
    Step 1 9 Here, weneed to configure 4 subnets for this we need to borrow 2 bits from the host bits and making the MSB of host bit of subnet mask to 1 as now it will be considered to be Network Bits and the value we will get, 11111111.11111111.11111111.11000000 From this we can now calculate the subnet mask.
  • 10.
    Step 2: Calculatingupdated subnet mask. In this step we will be calculating the updated subnet mask. 11111111.11111111.11111111.11000000 255 . 255 . 255 . 192 10
  • 11.
    Step 3: Findingthe range We will find the range in this step. Formula, Range: (Maximum Subnet Mask – Updated Subnet Mask) Maximum Subnet Mask is always 255.255.255.255 for every case Maximum Subnet Mask: 255.255.255.255 Updated Subnet Mask: - 255.255.255.192 0. 0. 0. 63 Here is the range for network we have got is 0.0.0.63 11
  • 12.
    Step 4:Divide thewhole network with the help of the range. Now we will divide the whole network with the help of the range. First Network Block: 198.168.10. 0 + 0. 0. 0.63 198.168.10.63 So for this block, Network address will be: 198.168.10.0 Broadcast address will be: 198.168.10.63 First host address will be: 198.168.10.1 (NA+1) Last host address will be: 198.168.10.62 (BA-1) 12
  • 13.
    Step 4 Second NetworkBlock: 198.168.10.64 + 0. 0. 0.63 198.168.10.127 So for this block, Network address will be: 198.168.10.64 Broadcast address will be: 198.168.10.127 First host address will be: 198.168.10.65 Last host address will be: 198.168.10.126 13
  • 14.
    Step 4 Third NetworkBlock: 198.168.10.128 + 0. 0. 0. 63 198. 168. 10.191 So for this block, Network address will be: 198.168.10.128 Broadcast address will be: 198.168.10.191 First host address will be: 198.168.10.129 Last host address will be: 198.168.10.190 14
  • 15.
    Step 4 Forth NetworkBlock: 198.168.10.192 + 0. 0. 0. 63 198. 168.10.255 So for this block, Network address will be: 198.168.10.192 Broadcast address will be: 198.168.10.255 First host address will be: 198.168.10.193 Last host address will be: 198.168.10.254 Subnet masks will remain same for every network block i.e. 255.255.255.192 15
  • 16.
    FLSM Exercises 1. UsingFLSM, subnet the class A IP 20.0.0.0/8 as 8 subnets. 2. Using FLSM, subnet the class B IP 172.3.0.0/16 as 4 subnets. 3. Using FLSM, subnet the class C IP 192.168.2.0/24 as 6 subnets. 16
  • 17.
    More with Subnetting Whenyou’ve chosen a possible subnet mask for your network and need to determine the numbers of subnets, valid hosts, and broadcast addresses of a subnet that the mask provides, all you need to do is answer five simple questions: How many subnets does the chosen subnet mask produce? How many valid hosts per subnet are available? What are the valid subnets? What’s the broadcast address of each subnet? What are the valid hosts in each subnet? 17
  • 18.
    Examples Given, Network Address= 192.168.2.0 Subnet mask = 255.255.255.128 Now let’s answer the five questions: How many subnets? => 2𝑥 = number of subnets. x is the number of masked bit, or the 1′s. Here, 128 = 10000000, the number of 1’s gives 21 subnets. Which means 2 subnets How many hosts per subnet? => 2𝑦 − 2 = 𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 ℎ𝑜𝑠𝑡𝑠 𝑝𝑒𝑟 𝑠𝑢𝑏𝑛𝑒𝑡. y is the number of unmasked bit, or the 0′s. Here, 128 = 10000000, the number of 0’s gives 27 − 2 hosts. Which means 126 hosts per subnet. We need to subtract 2 for the subnet address and the broadcast address. Which are not valid hosts. 18
  • 19.
    Examples (Cont.) What arethe valid subnets? => 256 – subnet mask = block size, or increment number. Here, 256 – 128 = 128. Remember we will start at zero and counting our block size, So the subnets are 0, 128. What are the broadcast address of each subnet? The broadcast address is always the number right before the next subnet. For 1st subnets the Broadcast address is 127 and for 2nd subnet it is 255 What are the valid hosts? => These are the numbers between subnet and broadcast address 19 Subnet 0 128 First Host 1 129 Last Host 126 254 Broadcast 127 255
  • 20.
    Exercise Given, Network Address= 192.168.10.0 Subnet mask = 255.255.255.192 Now Answer the following questions: How many subnets does the chosen subnet mask produce? How many valid hosts per subnet are available? What are the valid subnets? What’s the broadcast address of each subnet? What are the valid hosts in each subnet? 20
  • 21.
    Exercise Given, Network Address= 192.168.10.0 Subnet mask = 255.255.255.224 Now Answer the following questions: How many subnets does the chosen subnet mask produce? How many valid hosts per subnet are available? What are the valid subnets? What’s the broadcast address of each subnet? What are the valid hosts in each subnet? 21
  • 22.
    More Exercises For moreexercises see page no. 118 to page no. 136 of CCNA, Study Guide, 6th Edition, TodLammle. 22
  • 23.
    Playing with FLSM Supposeyou have a network address of class A and you want to create 1000 subnets. Which subnet mask will you choose? Try to answer first then see the next slide. 23
  • 24.
    Answer We know, 2𝑥= 𝑛𝑢𝑚𝑏𝑒𝑟 𝑜𝑓 𝑠𝑢𝑏𝑛𝑒𝑡𝑠 Here number of subnets = 1000 So, 2𝑥 = 1000 , the value of x must be equal to 10. Because 29 = 512. And we need to create 1000 subnets. Where 210 = 1024. So we will take x = 10. That means we need to convert 10 Host bits into Network bits. By default the subnet mask of class A network is 255.0.0.0 (11111111.00000000.00000000.00000000) Now adding 10 bits into network, the subnet mask will become, 11111111.11111111.11000000.00000000 255 . 255 . 192 . 0 So the answer is 255.255.192.0 24
  • 25.