IP Address and Subnetting
IP Address and Subnetting
SUBNETTING
1
P.THAMIZHIKKAVI
Research Scholar
Department of C.Tech
WHAT IS IP ADDRESS
A unique string of characters that identifies
each computer using the Internet Protocol to
communicate over a network.
2
DOTTED DECIMAL NOTATION
Four dotted decimal values - octal
Each octal have 8 binary bits
Value upto 256(2^8)
Value ranges from 0 - 255
3
EXAMPLE OF IP ADDRESS
10.0.0.1
172.16.0.1
192.168.0.1
255.255.255.255
4
TYPES OF IP ADDRESS
Public
Private
Static
Dynamic.
5
CLASSES OF IP ADDRESS
Class A
Class B
Class C
Class D
Class E
6
CLASS A
Range : 0 – 127
No of octal in network part : 1
No of octal in host part : 3
Private IP in class A : 10.0.0.0 — 10.255.255.255
7
CLASS B
Range : 128-191
No of octal in network part : 2
No of octal in host part : 2
Private IP in class A : 172.16.0.0 — 172.31.255.255
8
CLASS C
Range : 192-223
No of octal in network part : 3
No of octal in host part : 1
Private IP in class A : 192.168.0.0 — 192.168.255.255
9
CLASS D
Range : 224 - 239
Class D is for multicast networking
10
CLASS E
Range : 240 - 255
Class E address range is reserved for future or experimental purposes.
11
RANGE OF IP FOR EACH
CLASS
Class A – 0 to 127
Class B – 128 to 191
Class C – 192 to 223
Class D – 224 to 239
Class E – 240 to 255
12
HINT TO REMEMBER THE
RANGE
CLASS Power of 2 from right to left
power 2^7 2^6 2^5 2^4 2^3 2^2 2^1 2^0 Start
value 128 64 32 16 8 4 2 1 Value
A 0 0 0 0 0 0 0 0 0
B 1 0 0 0 0 0 0 0 128
C 1 1 0 0 0 0 0 0 192
D 1 1 1 0 0 0 0 0 224
E 1 1 1 1 0 0 0 0 240
13
DETAIL EXAMPLE OF IP
ADDRESS
Class A Class B Class C
Network ID 10.0.0.0 172.16.0.0 192.168.10.0
First IP address 10.0.0.1 172.16.0.0 192.168.10.1
Last IP address 10.255.255.254 172.16.255.254 192.168.10.254
Network broadcast 10.255.255.255 172.16.255.255 192.168.10.255
Total number of IP in a 1,67,77,216 65536 256
network
14
SUBNET MASK
For people understanding
Class A – first eight bit is in network part - /8
Class B - first sixteen bit is in network part - /16
Class C – first twenty four bit is in network part - /24
15
SUBNET MASK
Convert all network part bits into 1
Class A
11111111.00000000.00000000.00000000
255.0.0.0
Class B
11111111.11111111.00000000.00000000
255.255.0.0
Class C
11111111.11111111.11111111.00000000
255.255.255.0
16
WHY SUBNETTING
To reduce the wastage of IP address
17
CLASSFUL AND CLASSLESS IP
ADDRESS
Classful IP address
10.0.0.1/8
172.16.0.1/16
192.168.10.1/24
Classless IP address
10.15.26.4/12
172.16.33.56/19
192.168.10.55/26
18
TYPES OF SUBNETTING
Based on requirement of
Network
Host
19
POWER OF 2
Power of 2 Value
2^0 1
2^1 2
2^2 4
2^3 8
2^4 16
2^5 32
2^6 64
2^7 128
2^8 256
2^9 512
2^10 1024
2^11 2048
20
BASED ON NETWORK
Number of networks required.
All networks are treated as same.
It is a left to right approach
21
EXAMPLE
Do subnetting for the classful IP address 172.16.0.0/8.
To be divided into 16 network.
Tell the first network details , second network details and last network details.
Calculate the subnet mask.
22
CALCULATION
Number of network required – 16
Calculation its near biggest value in power of 2
2^4 – 16
23
CALCULATION
IP address
172.16.0.0/16
1010110000010000/0000000000000000
24
CALCULATION
Updated IP address
10101100000100000000/000000000000
25
CALCULATE NEXT NETWORK
ID
Increase the right first bit of network part
First network ID
10101100000100000000/00000000000
Second network ID
10101100000100000001/000000000000
Calculated ID
First network ID : 172.16.0.0 /20
Second network ID : 172.16.16.0 /20
26
INCREMENTAL VALUE
The calculated value for the given question is
16
All the other networks ID will be created using the incremental value only.
For example :
172.16.0.0
172.16.16.0
172.16.32.0
172.16.48.0
….
172.16.240.0
27
FIRST NETWORK ID DETAILS
Network ID : 172.16.0.0
First IP : 172.16.0.1
Last IP : 172.16.15.254
Broadcast IP : 172.16.15.255
28
SECOND NETWORK ID
DETAILS
Network ID : 172.16.16.0
First IP : 172.16.16.1
Last IP : 172.16.31.254
Broadcast IP : 172.16.31.255
29
SUBNET MASK CALCULATION
IP address : 10101100000100000000/000000000000
In 8 bits form
10101100.00010000.0000/0000.00000000
30
SUBNETTING ANALYSIS
In classful IP address
172.16.0.0 /16
Number of IP address – 65536
In classless IP address
172.16.16.0 /20
Number of IP address – 6656
31
BASED ON HOST
How many host are required on each network.
The network require more number of host is calculated first.
It is a right to left approach
32
EXAMPLE
Do subnetting for the classful IP address 172.16.0.0 /8.
To be divided into 3 network.
First network should have 1000 host
Second network should have 512 host
Third network should have 250 host
33
IMPORTANT NOTE:
Dividing based on network requirement wont focus on number of valid IP addresses.
But dividing based on host part should always focus on vaild IP addresses
Add in count the below details
Network ID – 1
Broadcast ID – 1
Required IP – n
34
FOR FIRST NETWORK
Number of host required – 1000
To be taken as - 1002
Calculation its near biggest value in power of 2
2^10 – 1024
172 16 0 0
1010 1100 0001 0000 0000 0000 0000 0000
35
CALCULATION
IP address
172.16.0.0/16
1010110000010000/0000000000000000
36
CALCULATION
Updated IP address
1010110000010000000000/0000000000
37
CALCULATE NEXT NETWORK
ID
Increase the right first bit of network part
First network ID
1010110000010000000000/000000000
Second network ID
1010110000010000000001/0000000000
Calculated ID
First network ID : 172.16.0.0 /22
Second network ID : 172.16.4.0 /22
38
INCREMENTAL VALUE
The calculated value for the given question is
4
All the other networks ID will be created using the incremental value only.
For example :
172.16.0.0
172.16.4.0
39
FIRST NETWORK ID DETAILS
Network ID : 172.16.0.0
First IP : 172.16.0.1
Last IP : 172.16.3.254
Broadcast IP : 172.16.3.255
40
SUBNET MASK CALCULATION
IP address : 1010110000010000000000/0000000000
In 8 bits form
10101100.00010000.000000/00.00000000
41
FOR SECOND NETWORK
Number of host required – 512
To be taken as - 514
Calculation its near biggest value in power of 2
2^10 – 1024
172 16 4 0
1010 1100 0001 0000 0000 0100 0000 0000
42
CALCULATION
IP address
172.16.4.0 /22
10101100000100000001/0000000000
43
CALCULATION
Updated IP address
1010110000010000000001/0000000000
172.16.4.0/ 22
44
CALCULATE NEXT NETWORK
ID
Increase the right first bit of network part
First network ID
1010110000010000000001/000000000
Second network ID
1010110000010000000010/0000000000
Calculated ID
First network ID : 172.16.4.0 /22
Second network ID : 172.16.8.0 /22
45
NETWORK ID DETAILS
Network ID : 172.16.4.0
First IP : 172.16.4.1
Last IP : 172.16.7.254
Broadcast IP : 172.16.7.255
46
SUBNET MASK CALCULATION
IP address : 1010110000010000000001/0000000000
In 8 bits form
10101100.00010000.000001/00.00000000
47
FOR THIRD NETWORK
Number of host required – 250
To be taken as - 252
Calculation its near biggest value in power of 2
2^8 – 256
172 16 8 0
1010 1100 0001 0000 0000 1000 0000 0000
48
CALCULATION
IP address
172.16.8.0 /22
10101100000100000010/0000000000
49
CALCULATION
Updated IP address
101011000001000000001000/00000000
172.16.8.0/ 24
50
CALCULATE NEXT NETWORK
ID
Increase the right first bit of network part
First network ID
101011000001000000001000/0000000
Second network ID
101011000001000000001001/00000000
Calculated ID
First network ID : 172.16.8.0 /24
Second network ID : 172.16.9.0 /24
51
INCREMENT VALUE
Increment value for third network is – 1
First network : 172.16.8.0
Next network : 172.16.9.0
52
NETWORK ID DETAILS
Network ID : 172.16.8.0
First IP : 172.16.8.1
Last IP : 172.16.8.254
Broadcast IP : 172.16.8.255
53
SUBNET MASK CALCULATION
IP address : 101011000001000000001000/00000000
In 8 bits form
10101100.00010000.00001000./00000000
54
FINAL ANSWER
1000 host 512 host 250 host
Network ID 172.16.0.0 /22 172.16.4.0 /22 172.16.8.0 /24
First IP address 172.16.0.1 /22 172.16.4.1 /22 172.16.8.1 /24
Last IP address 172.16.3.254 /22 172.16.7.254 /22 172.16.8.254 /24
Network broadcast 172.16.3.255 /22 172.16.7.255 /22 172.16.8.255 /24
Total no of valid IP 1024 1024 256
address
55
HINT TABLE FOR
SUBNETTING Increament value
128 64 32 16 8 4 2 1
I 1 2 3 4 5 6 7 8
II 9 10 11 12 13 14 15 16
octal
III 17 18 19 20 21 22 23 24
IV 25 26 27 28 29 30 31 32
0 (A) 128 (B) 192 (C) 224 (D) 240 (E) 248 252 254 255
Subnet mask
56
QUESTIO
NS???
57
THANK
YOU
58