Before we can discuss CIDR (Classless Inter-Domain Routing), we need to understand what IP address is, how it is divided (subnetting), and what versions of IP addresses are available. Currently, there are IPv4 (version 4) and IPv6 (version 6) addresses. IPv4 was introduced in 1980, and it is a 32-bit number having a total of about 4.3 million addresses. With the prosperity of the Internet and smart devices joining the network, 4.3 million IP addresses weren't enough to connect all devices available worldwide, and hence 128-bit IPv6 address was invented in 1998. For each computer, smartphone, tablet, and IoT devices joining the Internet, the number of IP addresses available within IPv4 wasn't enough to connect all devices.
The traditional IPv4 address was classified as class A, class B and class C; and entire block of class A, class B or class C IP addresses were assigned to ISPs and corporations. The classful routing system was inefficient in allocating IP addresses amongst organizations as class A, class B, and class C blocks are a predefined set of IP addresses that cannot further break down into smaller units. The classful address blocks are defined as follows:
- Class A: 8-bit network address and 24-bit host address having 16,777,216 IP addresses.
- Class B: 16-bit network address and 16-bit host address having 65,534 IP addresses.
- Class C: 24-bit network address and 8-bit host address having 256 IP addresses.
As you can see from the above, the entire 16,777,216 IP addresses are assigned to a single organization registering a class A network. This is a very inefficient allocation of IP addresses, especially when more and more devices are joining the Internet. To efficiently allocate the IP addresses into smaller blocks, CIDR (Classless Inter-Domain Routing) was invented in 1993. This is 5 years before IPv6 was introduced.
What is CIDR?
The introduction of CIDR extended the lifespan of IPv4 as well as the growth of routing tables. CIDR is only applicable to IPv4 addresses, and significantly improves the allocation of IP blocks in smaller chunks. For example, if a small business requires only 6 IP addresses, the smallest allocation in the classful system would be a class C assigning 255 IP addresses to this organization instead of 6. With the CIDR allocation system, a block of 8 IP addresses would be assigned to this small business enhancing the way how IPs are allocated.
How does CIDR work?
When setting up a network, a subnet mask is used to break the IP address into a network address and a host address. The 32-bit IP address is broken into 2-parts, and the first part becomes the network address and the tail end becomes the host address. The subnet mask is used to mask the host address, and the network address can be revealed. CIDR uses variable-length subnet masking (VLSM), so that it can mask any number of bits instead of 8-bit chunks in a classful system. CIDR notation is used in the following manner: Network Address / # of bits used in the network. For example, 192.168.1.0/24 is identical to class A network beginning at 192.168.1.0. The /24 is class C, /25 would be half of that which is 128 hosts, /26 would be 64 hosts in a subnetwork.
The table below is the reproduction of the CIDR network table provided in the various articles within our website.
|Class||Network Address||Number of Hosts||Netmask|
Note: (1) 127 Network Address reserved for loopback test. (2) Class D (224-247, Multicast) and Class E (248-255, Experimental) are not intended to be used in public operation.
CIDR was introduced in the IPv4 system to efficiently allocate the IP addresses into smaller blocks, and improve the efficiency of IP distribution to prolong the life of IPv4. IPv6 is now being actively used along with the IPv4 and eliminated the IP exhaustion issues, but CIDR is still being actively used to efficiently manage subnetworks within IPv4 space.
Leave a comment
All comments are moderated. Spammy and bot submitted comments are deleted. Please submit the comments that are helpful to others, and we'll approve your comments. A comment that includes outbound link will only be approved if the content is relevant to the topic, and has some value to our readers.