One of the most important design decisions of an Internet engineer is the assignment of IP addresses, 32-bit numbers that identify Internet hosts. These numbers are placed in the IP packet header and are used to route packets to their destination. Several things should be kept in mind about IP address assignment:
Prefix-based addressing. A basic concept of IP addressing is that initial prefixes of the IP address can be used for generalized routing decisions. For example, the first 16 bits of an address might identify Acme Company, the first 20 bits identify the Acme's Jonestown office, the first 26 bits identify a particular Ethernet in that office, and the entire 32 bits identify a particular host on that Ethernet. Prefix-based addressing has its origins in IP Address Classes, and has evolved into Subnetting and CIDR.
Per-interface assignment. IP addresses are assigned on a per-interface basis, so a host might possess several IP addresses if it has several interfaces. For example, a host with both Ethernet and serial interfaces would have an IP address for each. This is an important consequence of prefix-based addressing. An IP address doesn't really refer to a host, it refers to an interface. If a host is known by multiple addresses, then every service on this host can be referred to by multiple names! Addressing this host requires picking one of these. Since the packet is addressed to the interface and not the host, path information is introduced into the address. The exact ramifications of this effect depend heavily on the network design. In particular, careless design can result in a host becoming reachable by one address but not by another. The simplest solution to this problem is to select the host's most reliable interface and advertise its IP address as the host's primary IP address.
Virtual addresses. It is sometimes useful to configure a host with additional IP addresses, usually to use one server to offer Web service for several addresses. Although no real standard exists for such virtual addresses, the typical configuration is to assign additional addresses on an Ethernet (or other multicast medium) and then answer ARP requests for the virtual addresses. Special support is needed both in the server's operating system and in the actual server software. Dynamic addressing. Many hosts, particularly user workstations, do not need to be assigned any particular IP address, and can be dynamically addressed. Aside from obeying the general principles of prefix-based addressing (i.e, hosts on a particular Ethernet must have addresses with a particular prefix), such hosts will operate using any IP address. Other hosts, mainly servers, must have a particular IP address because other devices expect them to answer at that address, and must be statically addressed. Dynamically addressed hosts use management protocols to obtain their IP addresses from a server; most statically addressed hosts are manually configured with their IP address.
Address Classes In the original Internet routing scheme developed in the 1970s, sites were assigned addresses from one of three classes: Class A, Class B and Class C. The address classes differ in size and number. Class A addresses are the largest, but there are few of them. Class Cs are the smallest, but they are numerous. Classes D and E are also defined, but not used in normal operation.
To say that class-based IP addressing in still used would be true only in the loosest sense. Many addressing designs are still class-based, but an increasing number can only be explained using the more general concept of CIDR, which is backwards compatible with address classes.
Suffice it to say that at one point in time, you could request the Internet NIC to assign you a class A, B or C address. To get the larger class B addresses, you might have to supply some justification, but only the class A was really tough to get. In any case, NIC would set the network bits, or n-bits, to some unique value and inform the local network engineer. It would then be up to the engineer to assign each of his hosts an IP address starting with the assigned n-bits, followed by host bits, or h-bits, to make the address unique.
Internet routing used to work like this: A router receiving an IP packet extracted its Destination Address, which was classified (literally) by examining its first one to four bits. Once the address's class had been determined, it was broken down into network and host bits. Routers ignored the host bits, and only needed to match the network bits to find a route to the network. Once a packet reached its target network, its host field was examined for final delivery.
Summary of IP Address Classes
Class A - 0nnnnnnn hhhhhhhh hhhhhhhh hhhhhhhh First bit 0; 7 network bits; 24 host bits Initial byte: 0 - 127 126 Class As exist (0 and 127 are reserved) 16,777,214 hosts on each Class A
Class B - 10nnnnnn nnnnnnnn hhhhhhhh hhhhhhhh First two bits 10; 14 network bits; 16 host bits Initial byte: 128 - 191 16,384 Class Bs exist 65,532 hosts on each Class B
Class C - 110nnnnn nnnnnnnn nnnnnnnn hhhhhhhh First three bits 110; 21 network bits; 8 host bits Initial byte: 192 - 223 2,097,152 Class Cs exist 254 hosts on each Class C Class D - 1110mmmm mmmmmmmm mmmmmmmm mmmmmmmm First four bits 1110; 28 multicast address bits Initial byte: 224 - 247 Class Ds are multicast addresses - see RFC 1112
Class E - 1111rrrr rrrrrrrr rrrrrrrr rrrrrrrr First four bits 1111; 28 reserved address bits Initial byte: 248 - 255 Reserved for experimental use
Message from the Salty one: If you have any Questions/comments /suggestions or you would like to contribute to NeoTech email me SaltyNetGuru@NeoTechCC.orgor AIM me at SaltyNetGuru.