DNS, IP, Subnets & All That Jazz


Just like each place in the world has an address – Each machine on the internet has an address called the IP Address. For instance, your computer has an IP address, the server that hosts this website has an IP adress, and so on. And when we use “www.zarrata.com”, we are actually referring to IP address “” which is assigned to zarrata.com. You can find your own IP at http://whatismyipaddress.com/

Then, of course, we would need a database that has all the IP’s corresponding to all the websites on the internet. It could then be used to translate the human-friendly address or domain names(zarrata.com) to the real(IP) address( This database is called the DNS (Domain Name System).

Now, an IP address is actually used in binary for communication by the computer. For instance, translates to 11011000.00011011.00111101.10001001 – each number is represented by 8 positions in binary form – and are hence, called octets. The complete IP address is then a 32-bit number (made from 4 octets). Each of these 32 bits can be either 0 or 1 – thus allowing 2^(32) unique IP addresses which is about 4.3 billion possibilities.

[PS – The IP address considered here is the most prevalent version of the IP address – called IPv4. The other being IPv6]


Now, the first half of the IP address – the first 2 octets – 216.27 is the network part and the second half – the last 2 octects 61.137 form the machine or host part. ie-the first half is the neighborhood or street where you live and the second half is the exact house in the neighborhood. Hence, machines having the same first half of the IP belong to the same network. For instace, & belong to the same network.

Subnets & Subnetting

Networks having a large number of hosts are divided into subnetworks or subnets. A subnet number is assigned to each subnet. The second half or host part now has the host and the subnet number combined together – using the AND operation.

Consider a large network that has the IP addresses ranging from –

(225 is the maximum value of any octet – since, 256 is not an octect; 256 = 100000000. Here 224 is used since is a BROADCAST ADDRESS and cannot be used).

Now, we wish to divide the network into two subnetworks:

The first network consisting of the machines –

The second network consisting of the machines –

It is done by using a subnet mask which is defined by :

1)The class of IP(see table below) – here, the mask to be used is

2)The address that divided the network – here,

Hence, the mask obtained from 1) & 2) is

Class Address Range Subnet Mask
Class A 1.xxx.xxx.xxx – 126.xxx.xxx.xxx
Class B 128.xxx.xxx.xxx – 191.xxx.xxx.xxx
Class C 192.xxx.xxx.xxx – 223.xxx.xxx.xxx
Class D 224.xxx.xxx.xxx – 239.xxx.xxx.xxx Reserved for multicast groups
Class E 240.xxx.xxx.xxx – 254.xxx.xxx.xxx Reserved for future use, research & development

[Note – 127.x.x.x addresses are reserved for loopback or localhost]


1 Comment

  1. Pingback: Durofy » DNS, IP, Subnets & All That Jazz | DNS Internet

Leave A Reply