Illustrated TCP/IP Illustrated TCP/IP
by Matthew G. Naugle
Wiley Computer Publishing, John Wiley & Sons, Inc.
ISBN: 0471196568   Pub Date: 11/01/98
  

Previous Table of Contents Next


Chapter 74
Another Try

A customer has the base network address of 150.1.0.0 with a subnet mask of 255.255.0.0, or /16 prefix.

This time we are not interested in a requirement of subnets. All we know is that we must be able to have 100 hosts on each subnet. Each subnet will not have that many, but the largest one will, and without multinetting, we must use a mask small enough to accommodate that number. In order to support 100 hosts, 7 bits are needed, which allows for 126 addresses (2n7 – 2). This will allow for future growth. The next-lowest mask yields 62 addresses (2n6 – 2), so we must allow for 7 bits. Always assign a mask that allows for future growth.

Next we must determine the subnet mask for the network number. Since we will be reserving 7 bits for host assignment, this will leave 25 bits left for the network mask (32 bits – 7 bits = 25 bits). This gives a subnet mask of 255.255.255.128, or /25 prefix. The natural mask for Class B is 255.255.0.0. This mask is 255.255.255.128, which allows for 9 bits to be assigned to the subnet mask, thereby allowing for 512 subnets to be defined. The subnet numbers range from 0 to 521. This gives the range of subnets of 150.1.0.0 (providing for the zero subnet) through 150.1.255.128 (using all 9 bits including the all-1s subnet).

Now that we have separated the subnets from the hosts, we should list them:

Subnets Host Range
150.1.0.0 through 150.1.255.128 1 through 125 (2n7 – 2)
150.1.1.0 (x – host reserved bits) Host 1 (x = network/subnet reserved bits)
10010110 . 00000001 . 00000001 . 0xxxxxxx xxxxxxxx.xxxxxxxx.xxxxxxxx.x0000001
150.1.1.0 Host 127
10010110 . 00000001 . 00000001 . 0xxxxxxx xxxxxxxx.xxxxxxxx.xxxxxxxx.x1111111

Another Try

  Let’s first review breaking a network number down with a subnet requirement:
  Requirement: A site has been assigned the network number 150.1.0.0. It requires 100 hosts per subnet. Future growth indicates 120 hosts per subnet. It wasdetermined that expansion was more likely in the case of remote sites than hosts.
  Step 1: Determine the bits required to support at least 100 hosts and future expansion to 120 hosts per subnet.
7 bits are required for 100–126 hosts.
Start from the right and move left.
  Step 2: Determine how subnets are defined by 9 bits.
9 bits support 512 subnets.
Start from the left and move right.
  Step 3: Determine the mask.
150.1.0.0/25, or 255.255.255.128


Previous Table of Contents Next