Sie sind auf Seite 1von 11


Problem: Organizations
have multiple networks University
which are independently UniversityNetwork
managed Engineering Medical
Solution 1: Allocate one or School School
more addresses for each
Difficult to manage Library
From the outside of the
organization, each network
must be addressable.
Solution 2: Add another
level of hierarchy to the Subnetting
IP addressing structure
Basic Idea of Subnetting

Split the host number portion of an IP address into a

subnet number and a (smaller) host number.
Result is a 3-layer hierarchy

network prefix host number

network prefix subnet number host number

extended network prefix

Subnets can be freely assigned within the organization
Internally, subnets are treated as separate networks
Subnet structure is not visible outside the organization
Subnet Masks

Routers and hosts use an extended network prefix (subnet

mask) to identify the start of the host numbers

Class B 10 network host

16 bits
Network Prefix (16 bits)

with 10 network subnet host

Extended Network Prefix (24 bits)
mask 1111111111111111111111100000000

* There are different ways of subnetting. Commonly used netmasks for university
networks with /16 prefix (Class B) are and
Advantages of Subnetting

With subnetting, IP addresses use a 3-layer hierarchy:

Improves efficiency of IP addresses by not consuming an
entire address space for each physical network.
Reduces router complexity. Since external routers do not
know about subnetting, the complexity of routing tables at
external routers is reduced.

Note: Length of the subnet mask need not be identical at all

CIDR - Classless Interdomain Routing

IP backbone routers have one routing table entry for each network
With subnetting, a backbone router only needs to know one entry
for each network
This is acceptable for Class A and Class B networks
27 = 128 Class A networks
214 = 16,384 Class B networks
But this is not acceptable for Class C networks
221 = 2,097,152 Class C networks
In 1993, the size of the routing tables started to outgrow the capacity
of routers
Consequence: The Class-based assignment of IP addresses had to
be abandoned
CIDR Example

CIDR notation of a network address:
"18" says that the first 18 bits are the network part of the
address (and 14 bits are available for specific host
The network part is called the prefix

Assume that a site requires a network address with 1000 addresses

With CIDR, the network is assigned a continuous block of 1024 addresses
with a 22-bit long prefix
CIDR: Prefix Size vs. Network Size

CIDR Block Prefix # of Host Addresses

/27 32 hosts
/26 64 hosts
/25 128 hosts
/24 256 hosts
/23 512 hosts
/22 1,024 hosts
/21 2,048 hosts
/20 4,096 hosts
/19 8,192 hosts
/18 16,384 hosts
/17 32,768 hosts
/16 65,536 hosts
/15 131,072 hosts
/14 262,144 hosts
/13 524,288 hosts
CIDR and Address assignments

Backbone ISPs obtain large block of IP addresses space and

then reallocate portions of their address blocks to their

Assume that an ISP owns the address block, which
represents 16,384 (214) IP addresses
Suppose a client requires 800 host addresses
With classful addresses: need to assign a class B address (and
waste ~64,700 addresses= 216 -800) .
With CIDR: Assign a /22 block, e.g.,, and allocate a block
of 1,024 (210) IP addresses.
CIDR and Routing Information

Company X :
ISP X owns:
Backbone ISP y :

Organization z1 : Organization z2 :
CIDR and Routing Information
ISP y sends everything which matches
Backbone routers do not know the prefix:
anything about Company X, ISP to Organizations z1
Y, or Organizations z1, z2. to Organizations z2
Company X :
ISP X does not know about ISP X owns:
Organizations z1, z2.
ISP X sends everything which
matches the prefix: ISP y : to Company X, to ISP y

Backbone sends everything

which matches the prefixes
Organization z1 : Organization z2 :,, to ISP X.
You can find about ownership of IP addresses in
Example North America via

The IP Address:

207 2 88 170

11001111 00000010 01011000 10101010

Belongs to:
City of Charlottesville, VA: -
11001111 00000010 01011000 00000000

Belongs to:
Cable & Wireless USA -
11001111 00000000 00000000 00000000