IP supernets and subnets


 

 

 

 

 

Introduction

The web page entitled Classless IP addressing described the use of suffixes or bit masks for IP addresses, as a way of specifying the number of bits used for network id`s, and the number of bits used for the computer id`s.

Classless IP addressing therefore enables a much higher utilisation of IP addresses, with a very much reduced wastefulness due to unallocated numbers which could not be used.

However there is an added bonus in classless IP addressing, in that it enables organisations to do their own reorganisation of network id`s, within previously allocated Classes of addressing.

The best way of looking at this is to play around with IP addresses and bit masks in their 32 bit binary format.

 

Revisiting classless addressing in binary

In the previous web pages, it has been shown that the address

134.36.80.30

is a class B address, so that 134.36 identifies the network, and the .80.30 identifies the computer within that network - or in binary, 16 bits of the address identify the network, and 16 bits identify the computer.

It has also been shown that a Class B address is the same as a classless address with the suffix " /16 ", so the above address can be expressed as

134.36.80.30/16

And it has also been shown that this is the same as describing the address as

IP address 137.36.80.30
Bit mask 255.255.0.0

And in binary these look like

10000110 00100100 01010000 00011110

for the address, and

11111111 11111111 00000000 00000000

for the bit mask.

 

Subnets

So what is the effect of using a different bit mask - say 255.255.255.0

Converting this to binary gives the result

11111111 11111111 11111111 00000000

From this, it is clear that instead of 16 bits specifying the network id, there is now 24.

Which means that instead of having one network with the network id of 134.36, there is now 254 networks, with network id`s in the range

134.36.1

134.36.2

134.36.3

up to

134.36.254

Another way of looking at it is to say that a single class B network has been changed into 254 class C networks.

So the address

134.36.80.30

used with a bit mask of

255.255.255.0

gives the following result -

Network id 137.36.80
Computer ID .30

So an increase in the number of 1`s in the bit mask increases the number of network id`s - this process is known as subnetting, or creating subnets.

Organisations can use this technique to break up a single large network into several smaller sub networks.

The posible downside to this is that it reduces the maximum number of computers on each sub-net, but as 8 bits allows 254 unique computer id`s, this is probably more than enough anyway.

Although the above showed how to split up a class B network into 254 class C networks, the technique can be used with any type of network, ie, class A, B, or C, or classless networks.

And the organisation can choose at will how many subnets it wishes to create, it does not have to be 254.

So if an organisation has been given a class C network address such as

11001000 10101010 00100111 00000000

The inherent bit mask is

11111111 11111111 11111111 00000000

By using a bit mask of

11111111 11111111 11111111 11000000

within the organisation, they will have created four sub-nets, each of which can provide 62 unique computer id`s.

 

Supernets

If instead of increasing the number of 1`s in the bit mask, they are reduced, then the opposite effect is obtained.

So if an organisation is allocated four class C networks with the Network IP addresses

200.36.80.0

200.36.81.0

200.36.82.0

200.36.83.0

then the corresponding binary addresses are

11001000 00100110 01010000 00000000

11001000 00100110 01010001 00000000

11001000 00100110 01010010 00000000

11001000 00100110 01010011 00000000

The inherent bit mask for all these is

11111111 11111111 11111111 00000000

Using this bit mask splits these addresses into the network id section, and the computer id section -

11001000 00100110 01010000 ---- 00000000

11001000 00100110 01010001 ---- 00000000

11001000 00100110 01010010 ---- 00000000

11001000 00100110 01010011 ---- 00000000

However if the organisation then actually uses the bit mask which is

11111111 11111111 11111100 00000000

then it has reduced the number of bits that specify the network address by two, ie, from 24 down to 22.

The effect on the four network addresses is as follows :-

11001000 00100110 010100----00 00000000

11001000 00100110 010100----01 00000000

11001000 00100110 010100----10 00000000

11001000 00100110 010100----11 00000000

Two effects are seen, the first is that all four networks now have the same address

11001000 00100110 010100----00 00000000

which in dotted decimal notation is

200.36.80.0

The second effect is that there is now four times as many unique computer id`s available, ie, there is 1022 instead of 252.

So the organisation has converted its original allocation of four class C networks into a single larger network.

This process is called supernetting, or creating a supernet.

And just like subnets, the technique is not limited to class C network allocations, it can be used with class A, B, or C networks, or classless networks.

The essential requirement is that the organisation has been allocated a block of adjacent network addresses.

 


© 2001 Ron Turner


Return to the IP protocol home page