InetDaemon
The guy  "geeks" call for tech support..

IP Subneting

  1. Addressing
  2. Classful IP Addressing
  3. Classless IP Addressing

Introduction

IP addresses used in a single network will all have part of their address that is the same. This part of the address is called the network portion. The other part of an address is the host portion of the address and must be unique.

So how do you determine what part of an IP address is the network portion and what part is the host portion?

THE CLASSFUL ANSWER

Classful addressing breaks up ranges of IP addresses based on the value of the first four bits in the first octet of the address. The table below illustrates how the pattern of the first four bits indicates which part of an IP address is the network part and which part of the address is the host part.

N = Network  |  h = Host
First Octet IP Address Characteristics
Most
Significant
BITS
Addr.
Class
Network vs.
Host
NETWORK BITS

HOST BITS

0000 A N.h.h.h 8 24
1000 B N.N.h.h 24 16
1100 C N.N.N.h 16 8

Note that in classful addressing, IP addresses are split into groups of addresses by how many octets are in the host and Network portions of the address.

Classful addressing is highly inefficient. When an organization needed just a dozen addresses, they were assigned a class C network address which granted them 256 addresses. This meant that 238 of the addresses go unused and were wasted. As the number of address blocks dwindled, some means of conserving addresses became necessary.

THE CLASSLESS ANSWER

By taking the classful blocks and carving them into smaller blocks, addresses could be conserved. This took the class A, class B and Class C networks and carved them into smaller networks. These smaller networks were called sub-networks or just subnets for short. To determine which portion of an address was the network part and which portion was the host part, a mask became necessary to assist computers in determining how many bits in an address were host bits and how many were network bits.

SUBNET MASK

The subnet mask allows a computer to determine what part of an address is network, and which part is host, but does so using binary logic instead of just matching a pattern of 1's and 0's.

To carve a block of addresses into a smaller chunk of addresses, you extend the network portion of the address into the host bits.

The bits in a class C address look like this:

NNNNNNNN.NNNNNNNN.NNNNNNNN.hhhhhhhh

If we carve the class C into 2 blocks, then we need to use one more bit to chop the number of hosts in half.

NNNNNNNN.NNNNNNNN.NNNNNNNN.Nhhhhhhh

To indicate this, we can use a mask that looks like this:

11111111.11111111.11111111.10000000

Yes, the mask always has a 1 for any bit that is supposed to be a network bit in the address. The host bits are always zero.

Why are the network bits in a subnet mask always 1's?

Because routers (which use masks) don't care about host addresses, they care about networks. They want to keep the network part of an address and throw out the host part of the address when they are trying to figure out which network a host belongs to. Thus, the subnet mask serves to help the router keep the network part of the address and ignore the host portion of the address.

Please recall that IP addresses are binary numbers. That means that each column has a value that is twice the value of the column to the right of it. You could also say that each bit has a value that is exactly half the value of the column to the left of it. Thus, carving a block in half only requires moving right one bit. Moving right two bits carves a block into four pieces.


The Internet | Internet Protocol | IP Addresses|IP Subnetting | IP Supernetting |VLSM | IP Routing

 


YOUR DONATIONS SUPPORT THE CONSTRUCTION OR COMPLETION OF TUTORIALS THROUGHOUT THIS SITE

Comments and Suggestions | FAQ's | About InetDaemon.Com | About InetDaemon | Acceptable Use Policy | Privacy Policy
© 1996 - 2008 InetDaemon, InetDaemon Enterprises

This is a 'WHYFF' (We Help You For Free) site. One Person maintains this site in his spare time.
InetDaemon is an IT expert, not an English professor. Grammar and spelling errors are to be expected.

Standard disclaimer: The statements, views and opinions presented on this web page are those of the author and are not endorsed by, nor do they necessarily reflect, the opinions of the author's present and/or former employers or any other organization the author may be associated with. We do not warranty or guarantee the correctness of the information provided or its fitness for any purpose.