Download presentation
Presentation is loading. Please wait.
Published byJeremy Mills Modified over 9 years ago
1
Fragmentation Fragmentation and reassembly are done by the IP layer Fragmentation and reassembly are done by the IP layer Identification (16 bits) Identification (16 bits) –To identify fragments as pieces of the original (along with source and destination addresses, and “protocol” field)
2
Fragmentation Flags (3 bits) Flags (3 bits) –“More” bit –“Don’t fragment” bit –Unused Offset (13 bits) Offset (13 bits) –Offset in 8-byte units from the beginning of the payload of the original
3
Fragmentation Id = abcd Frag 1 Frag 2 Id = abcd, More = 1, Offset = 0 Id = abcd, More = 0, Offset = x
4
Fragmentation Each fragment becomes a packet on its own Each fragment becomes a packet on its own –Routed independently of others Reassembly timer at receiver Reassembly timer at receiver –If all fragments do not arrive by the reassembly time-out, original packet cannot be obtained –ICMP error generated IP: RFC 791 IP: RFC 791
5
Class B address: 144.16.x.y 144.16.68.22 144.16.68.25 144.16.68.8 144.16.64.3 144.16.64.37 To the Internet eth0 eth1 144.16.64.3eth0 144.16.64.37eth0 144.16.68.22 eth1 144.16.68.25 eth1 Routing table
6
Problem Too many entries Too many entries No way to aggregate No way to aggregate Can we “extend” the network-id somehow? Can we “extend” the network-id somehow?
7
Subnetting The bits in the hostid part are further divided: The bits in the hostid part are further divided: netidhostid subnetid hostid
8
Subnet masks To extract the netid and subnetid parts from the IP address To extract the netid and subnetid parts from the IP address String of 1-s with trailing 0-s in the hostid part String of 1-s with trailing 0-s in the hostid part 14416 68117 255 0 14416 68 0 Bit-wise AND
9
Class B address: 144.16.x.y 144.16.68.22 144.16.68.25 144.16.68.8 144.16.64.3 144.16.64.37 To the Internet eth0 eth1 144.16.64.*eth0 144.16.68.* eth1 Routing table
10
Router operation Subnet mask: 255.255.255.0 Subnet mask: 255.255.255.0 Router should store this Router should store this Apply it to the D.A. field of incoming packet Apply it to the D.A. field of incoming packet Compare with 144.16.64.0 and 144.16.68.0 Compare with 144.16.64.0 and 144.16.68.0
11
Forwarding Compact routing table Compact routing table Example was with a router Example was with a router –Same considerations for a host with multiple interfaces
12
N/w C1 N/w C2N/w C50
13
N/w C1 N/w C2N/w C50 Without subnetting C1 C2 … C50 Core router C1 C2 … C50 Core router
14
Subnetting Imagine now that instead of 50 Class C addresses, the organizations shared a single Class B address with subnetting Imagine now that instead of 50 Class C addresses, the organizations shared a single Class B address with subnetting
15
With subnetting B Core router B B1 B2 … B50 Edge router
16
Subnetting: drawbacks The size of the routing tables in the core routers decreases The size of the routing tables in the core routers decreases But problem: a class B address is used up! But problem: a class B address is used up! With 50 Class C addresses: 50x254=12700 hosts With 50 Class C addresses: 50x254=12700 hosts With a Class B address: 65534 hosts! With a Class B address: 65534 hosts! –Many addresses likely to be unused Class B address space starting to get exhausted Class B address space starting to get exhausted
17
Earlier example again N/w C1 N/w C2N/w C50 C1 C2 … C50 Core router C1 C2 … C50 Core router
18
Aggregation again? What if the 50 Class C addresses are allocated “nicely”, so that they can be aggregated? What if the 50 Class C addresses are allocated “nicely”, so that they can be aggregated? Leads to the idea of supernetting Leads to the idea of supernetting
19
Supernetting Example Example –C1: 194.51.2.0 –C2: 194.51.3.0 3 rd octet: 3 rd octet: –0000 0010 –0000 0011 Aggregation: 0000 001 Aggregation: 0000 001 Single r.t. entry: Single r.t. entry: –194.51..* Mask to be used: 23 bits Mask to be used: 23 bits
20
Supernetting N/w C1 N/w C2N/w C50 Aggr C Core router Aggr C Core router
21
Supernetting Avoids routing table size explosion Avoids routing table size explosion Also avoids wasted (unused) IP addresses Also avoids wasted (unused) IP addresses A “best of both worlds” solution A “best of both worlds” solution Key: allocate Class C addresses appropriately, so that aggregation is possible Key: allocate Class C addresses appropriately, so that aggregation is possible
22
CIDR With classes A, B and C, the number of netid bits (i.e., “netmask length”) is implicitly fixed: 8, 16 and 24 With classes A, B and C, the number of netid bits (i.e., “netmask length”) is implicitly fixed: 8, 16 and 24 But with aggregation, variable-length netmasks are necessary But with aggregation, variable-length netmasks are necessary Classless Inter-Domain Routing Classless Inter-Domain Routing
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.