An organisation has a Class-C IP address of 200.200.200.0 and wants to have three sub-networks, one with 110 hosts and two with 60 hosts each. Which of the following options are a possible set of subnet address and subnet mask?
255.255.255.192/ 200.200.200.128
255.255.255.128/ 200.200.200.0
255.255.255.128/ 200.200.200.64
255.255.255.192/ 200.200.200.0
255.255.255.128/ 200.200.200.192
255.255.255.128/ 200.200.200.64
255.255.255.128/ 200.200.200.128
255.255.255.192/ 200.200.200.192
255.255.255.192/ 200.200.200.224
255.255.255.128/ 200.200.200.128
255.255.255.192/ 200.200.200.64
255.255.255.192/ 200.200.200.0
Solution
In Class C network first three octets are reserved for NID, so we have total 8 bits
for host and subnets. If we want to distribute addresses in subnets so first we should consider the subnet with maximum host, here which is a subnet with 110 hosts.
For 110 hosts we require 7 bits for host id, one bit remains for the subnet, which we fix to 1 for this subnet, now subnet mask for this subnet is 255.255.255.10000000 = 255.255.255.128 and subnet address is 200.200.200.128
For the first subnet, we have fixed the last octet 8th bit to 1, and for the second and third subnet, 8th bit will be 0.
Now for 60 hosts, we require 6 bit for host id, two-bit remain for the subnet, in which 8th bit is already fixed to 0; we can configure 7th bit only for these subnets;
For the second and third subnet, we fix the 7th bit to 0 and 1 respectively.
Subnet address for the second and third subnet is 200.200.200.0 and 200.200.200.64 respectively.
Subnet mask for the second and third subnet is 255.255.255.11000000 = 255.255.255.192
For class C subnet mask is 255.255.255.0
As its class C address, we have to take two-bit from the last octet.
Therefore, Possible subnet bits would be 00,01,10,11
MSB in last 8 bits helps us to get two subnets
10000000 →→ subnet1
00000000 →→ subnet2
subnet2 is divided into 2 more subnets using 7th bit
00000000 →→ subnet2(0)
01000000 →→ subnet2(1)
