Information Technology Reference
In-Depth Information
The address class determines the default number of bits used to specify the network ID and,
therefore, the default subnet mask for an address. Table 8-2 lists the default number of bits for
specifying the network ID in each address class.
Table 8-2
Default subnet mask and number of network ID bits for each address class
Class
Default subnet mask
Number of bits in network ID
A
255.0.0.0
8
B
255.255.0.0
16
C
255.255.255.0
24
In Figure 8-6, when the IP address 172.31.210.10 is entered in the IP address text box,
Windows recognizes it as a class B address and assigns a subnet mask of 255.255.0.0 by default.
IP Address Assignment Rules
When you assign a computer an IP address, there are
some rules to remember:
• Every IP address configuration must have a subnet mask.
• All hosts on the same physical network must share the same network ID in their IP
addresses.
• All host IDs on the same network must be unique.
• You can't assign an IP address in which all the host ID bits are 0. This type of IP address
is reserved as the network ID. For example, IP address 172.31.0.0 with subnet mask
255.255.0.0 is reserved to identify network 172.31.
• You can't assign an IP address in which all the host ID bits are 1. This type of IP address is
reserved as the network broadcast address. For example, IP address 172.31.255.255 with
subnet mask 255.255.0.0 has all host ID bits set to 1 and is reserved as the broadcast
address for the 172.31 network.
• Computers assigned different network IDs can communicate only by sending network
packets to a router, which forwards the packets to the correct network.
Subnetting If IP addresses have a default subnet mask assigned based on the value of
the IP address's first octet, why do you even need to specify the subnet mask? The reason is
the default subnet mask doesn't always suit the needs of today's networks. Address classes
and default subnet masks were designed when TCP/IP was in its infancy, and computer net-
works and the Internet were almost unheard of. They met the needs of the few government
agencies and universities using TCP/IP in the late 1970s and 1980s.
After computer networks were being installed in every business, and users wanted access
to the new information source called the Internet, the address class system clearly needed some
flexibility—hence, subnet masks that could be configured irrespective of the address class. This
use of subnet masks became known as Classless Interdomain Routing (CIDR). For example,
assigning the IP address 172.31.210.10 with a subnet mask of 255.255.255.0 is perfectly acceptable.
In this case, the network ID is 172.31.210 and the host ID is 10. Why would you want to assign
a subnet mask different from the default, however? Aren't the default subnet masks good
enough? In some cases, they are, but not in others.
Another way of specifying an IP address and its subnet mask is CIDR nota-
tion. CIDR notation uses the format A.B.C.D/n; n is the number of 1 bits
in the subnet mask or, expressed another way, the number of bits in the
IP address representing the network ID. The n is referred to as the IP prefix
or just prefix. For example, 172.31.210.10 with a 255.255.255.0 subnet
mask is expressed as 172.31.210.10/24 in CIDR notation.
 
 
Search WWH ::




Custom Search