Subnetworking and Netmasks
It is not uncommon for organizations with large IP address needs to obtain a Class B network and then subdivide (subnetwork) it into 256 Class C-sized networks. A perfect example of this is a large ISP needs to provide Class C-sized network to its corporate clients and does this by dividing up a Class B network.
For example, if an ISP had a Class B network of 165.65, it could divide it up into 256 different networks, ranging from 165.65.0 through 165.65.255. Each of these subnetworks would have 254 available addresses, similar to the description of Class C network in the last section.
There is a potential for confusion in this situation. How can a machine know what type of network it is on ? If a machine has an IP address of 126.96.36.199, there is no immediately apparent way for it to know if it is on the Class A network 19, a Class B-size subnetwork 19.148, or a Class C-size subnetwork 19.148.43.
This situation is resolved by the use of a network mask (or subnetwork mask), also known as a netmask (or subnetmask). A netmask is another set of dot-separated one byte integers that define which portion of the IP address identifies the network.
There are three generic netmasks: 255.0.0.0, 255.255.0.0, and 255.255.255.0. If you know the IP address and the netmask, you can define the network IP address and its range of available addresses.
Take the previous IP address, 188.8.131.52. If the netmask is 255.0.0.0, the network address is 184.108.40.206, and the range of possible addresses on that network is 220.127.116.11 through 18.104.22.168. If the netmask is 255.255.0.0, the network address is 22.214.171.124 and the range of possible addresses on that network is 126.96.36.199 through 188.8.131.52. If the netmask is 255.255.255.0, the network address is 184.108.40.206 and the range of possible addresses on that network is 220.127.116.11 through 18.104.22.168.
When a computer routes a message, it has a specific IP address.If it also has the network mask, it knows where to send that IP address.
IP Version 6 (IPv6)
We are currently in transition to IPv6 , with its 2^128 potential addresses. This transition won’t happen all at once; network hardware and software are under development to use both IPv4 and IPv6 addresses simultaneously. Since there are so many IPv6 addresses, there is enough room to incorporate all IPv4 addresses. Your current IP addresses (IPv4) will still work in an IPv6 world.
In fact, the conventions developed for IPv6 make the difference seem simpler; for example, the following IPv4 address
is equivalent to the following IPv6 address
: : 192.168.33.54
When the transition is complete, we are supposed to think of IPv6 addresses in hexadecimal, or base 16 notation. In base 16, the numbers are 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, a, b, c, d, e, f. A typical IPv6 address in hexadecimal notation might look like
Another IPv6 convention allows you to leave out leading zeros; the same IPv6 can be written as
You can convert the previously noted IPv4 address. To do so, first convert it to binary format; thus 192.168.33.54 becomes
11000000 10101000 001000001 00111000
Converting this to hexadecimal notation, this becomes
Therefore, the full corresponding IPv6 address is
: : 192.168.33.54
The broadcast address is a special address that can be used when sending information to all hosts on the network. Instead of sending separate messages to each host, a single message can be sent to a broadcast address. All computers connected to that network receive that message. The best analogy to a broadcast message is a radio or a television signal, where every unit that is listening receives the message.
The broadcast address is based on the network address, with the host portions replaced by 255. So, for the Class B network 174.148, the broadcast address is 22.214.171.124, and for the Class C network 194.148.43, the broadcast address is 126.96.36.199.
A computer configured for the local network or subnetwork has no knowledge of how to communicate with computers on external networks (for instance, on the Internet). It needs a gateway to an external network.
A gateway is a computer that provides a route to the outside world. It generally has at least two network interfaces: one connected to the local network and one to an outside network, often a corporate network or directly to the Internet. If a computer can’t identify the destination address of a message on the local network, it sends the message to a gateway. The gateway reroutes the message to the external network.
If you want to host computer to connect to an external network, you need to identify the IP address of at least one gateway that is also connected to an outside network such as the Internet.
When you access the Sybex Web site, you could type 188.8.131.52 into the address text box in your browser. But it’s easier to remember http://www.Sybex.com. Name servers provide transition. Name servers, under the Domain Name System (DNS), are a database of domain names such as www.mommabears.com or www.Sybex.com and their corresponding IP addresses.
Any computer that is connected to the Internet or any other large network needs a name server. Therefore, when configuring TCP/IP on a host in a large network, you need a name server.
ISPs provide name servers for your connections to the Internet. In fact, you don’t even need the IP address of a name server for most dial-up connections. It is automatically provided for you during your connection.