Friday 16 September 2016

Subnet Mask

  • Subnet Mask is short for "Subnetwork Mask".
  • Subnet is a logical sub division of an IP network.The process of dividing the network into two or more networks is called "subnetting".

  • A Subnet Mask is a 32-bit number used to differentiate the network component of an IP address by dividing the IP address into Network address and Host address.
  • Subnet Mask is made by setting network bits to all "1"s and setting host bits to all "0"s. 
  • Subnet Mask is a binary number format but it also communicated with decimal format. 

The IP is divide into five classes and each class has it's default subnet mask as shown below:

ClassAddress rangeSubnet Mask
(decimal)
Subnet Mask
(binary)
FormatNumber of Networks
(2^N)
Number of Hosts
(2^H -2)
A
1-127
255.0.0
11111111 00000000 00000000 00000000
N.H.H.H
2^8 = 256
2^24 -2 = 16,777,214
B
128-191
255.255.0.0
11111111 11111111 00000000 00000000
N.N.H.H
2^16 = 65,536
2^16 -2 = 65,534
C
192-223
255.255.255.0
11111111 11111111 11111111 00000000
N.N.N.H
2^24 = 16,777,216
2^8 -2 = 254
D
224-239
MulticastMulticastN/AN/AN/A
E
240-255
ExperimentalExperimentalN/AN/AN/A

Examples of Subnet Masking: