Professional Documents
Culture Documents
Some of the
options
• Classful addressing:
– inefficient use of address space, address space exhaustion
– e.g., class B net allocated enough addresses for 65K hosts, even if only 2K hosts in that
network
• CIDR solves the problem of IP address shortage
– Allocate remaining IP addresses in variable-sized blocks, without regards to classes.
network host
part part
11001000 00010111 00010000 00000000
200.23.16.0/23
11/7/23 Computer Networks AP 16-14
Longest Prefix Match
Destination Address 128.143.71.21
• Longest Prefix Match: Search for the
routing table entry that has the longest
match with the prefix of the destination IP Destination address Next hop
address
1. Search for a match on all 32 bits 10.0.0.0/8 R1
2. Search for a match for 31 bits 128.143.0.0/16 R2
3. ……….. 128.143.64.0/20 R3
4. Search for a match on 0 bits 128.143.192.0/20 R3
128.143.71.0/24 R4
Example: Packet will 128.143.71.55/32 R3
be routed to Router 3 default R5
15
11/7/23 Computer Networks
Getting a datagram from source to dest.
223.1.3.1 223.1.3.2
• Motivation: local network can use just one IP address as far as outside
world is concerned:
– no need to be allocated range of addresses from ISP - just one IP
address is used for all devices
– can change addresses of devices in local network without notifying
outside world
– can change ISP without changing addresses of devices in local
network
– devices inside local net not explicitly addressable, visible by outside
world (a security plus).
R4
R5 BGP
R3 AS3
(OSPF intra-AS
AS1 AS2 routing)
(RIP intra-AS (OSPF
routing) BGP intra-AS
routing)
R1 R2
Source
OSPF
IGP RIP
IS-IS
EGP BGP
Policy:
• Inter-AS: admin wants control over how its traffic routed, who routes through its net.
• Intra-AS: single admin, so no policy decisions needed
Scale:
• hierarchical routing saves table size, reduced update traffic
Performance:
• Intra-AS: can focus on performance
• Inter-AS: policy may dominate over performance