Unformatted text preview:

CS 640: Introduction to Computer NetworksThe Road AheadIP PacketsIPv4 Header FieldsSlide 5Slide 6IP Delivery ModelIP FragmentationReassemblyFragmentation Related FieldsIP Fragmentation Example #1IP Fragmentation Example #2IP Fragmentation Example #3IP ReassemblyFragmentation and ReassemblyInternet Control Message Protocol (ICMP)IP MTU Discovery with ICMPSlide 18Slide 19Slide 20Router Architecture OverviewLine Card: Input PortLine Card: Output PortThree Types of Switching FabricsSwitching Via a MemorySwitching Via a BusSwitching Via an Interconnection NetworkNetwork ProcessorA Note on BufferingInput Port QueuingOutput Port QueuingForwarding: Longest Prefix MatchSpeeding up Prefix Match – Some AlternativesNext LectureCS 640: Introduction to Computer NetworksAditya AkellaLecture 9 - IP: Packets and Routers2The Road Ahead•Last lecture–How does choice of address impact network architecture and scalability?–What do IP addresses look like?–How to get an IP address?•This lecture–What do IP packets look like?–How to handle differences between LANs?–How do routers work?3IP Packets•Low-level communication model provided by Internet–Unit: “Datagram”•Datagram–Each packet self-contained•All information needed to get to destination–Analogous to letter or telegram0 4 8 12 16 19 24 28 31versionHLen TOS LengthIdentifier Flag OffsetTTL Protocol ChecksumSource AddressDestination AddressOptions (if any)DataHeaderIPv4 PacketFormat4IPv4 Header Fields•Version: IP Version–4 for IPv4–6 for IPv6•HLen: Header Length–32-bit words (typically 5)•TOS: Type of Service–Priority information•Length: Packet Length–Bytes (including header)•Header format can change with versions–First byte identifies version–IPv6 header are very different – will see later•Length field limits packets to 65,535 bytes–In practice, break into much smaller packets for network performance considerations0 4 8 12 16 19 24 28 31version HLen TOS LengthIdentifier Flags OffsetTTL Protocol ChecksumSource AddressDestination AddressOptions (if any)Data5IPv4 Header Fields•Identifier, flags, fragment offset  used primarily for fragmentation•Time to live–Must be decremented at each router–Packets with TTL=0 are thrown away–Ensure packets exit the network•Protocol–Demultiplexing to higher layer protocols–TCP = 6, ICMP = 1, UDP = 17…•Header checksum–Ensures some degree of header integrity–Relatively weak – only 16 bits•Options–E.g. Source routing, record route, etc.–Performance issues at routers•Poorly supported or not at all0 4 8 12 16 19 24 28 31version HLen TOS LengthIdentifier Flags OffsetTTL Protocol ChecksumSource AddressDestination AddressOptions (if any)Data6IPv4 Header Fields•Source Address–32-bit IP address of sender•Destination Address–32-bit IP address of destination•Like the addresses on an envelope•Globally unique identification of sender & receiver–NAT?0 4 8 12 16 19 24 28 31version HLen TOS LengthIdentifier Flags OffsetTTL Protocol ChecksumSource AddressDestination AddressOptions (if any)Data7IP Delivery Model•Best effort service–Network will do its best to get packet to destination•Does NOT guarantee:–Any maximum latency or even ultimate success–Sender will be informed if packet doesn’t make it–Packets will arrive in same order sent–Just one copy of packet will arrive•Implications–Scales very well  simple, dumb network; “plug-n-play”–Higher level protocols must make up for shortcomings•Reliably delivering ordered sequence of bytes  TCP–Some services not feasible•Latency or bandwidth guarantees•Need special support8IP Fragmentation•Every Network has Own Maximum Transmission Unit (MTU)–Largest IP datagram it can carry within its own packet frame•E.g., Ethernet is 1500 bytes–Don’t know MTUs of all intermediate networks in advance•IP Solution–When hit network with small MTU, fragment packets•Might get further fragmentation as proceed fartherhosthostrouterrouterMTU = 4000MTU = 1500MTU = 20009Reassembly•Where to do reassembly?–End nodes or at routers?•End nodes -- better–Avoids unnecessary work where large packets are fragmented multiple times –If any fragment missing, delete entire packet•Intermediate nodes -- Dangerous–How much buffer space required at routers?–What if routes in network change?•Multiple paths through network•All fragments only required to go through destination10Fragmentation Related Fields•Length–Length of IP fragment•Identification –To match up with other fragments•Fragment offset–Where this fragment lies in entire IP datagram•Flags–“More fragments” flag–“Don’t fragment” flag11IP Fragmentation Example #1hostrouterMTU = 4000IPHeaderIPDataLength = 3820, M=012IP Fragmentation Example #2routerrouterMTU = 2000IPHeaderIPDataLength = 3820, M=03800 bytesIPHeaderIPDataLength = 2000, M=1, Offset = 01980 bytesIPDataIPHeaderLength = 1840, M=0, Offset = 19801820 bytes13IP Fragmentation Example #3IPHeaderIPDataLength = 2000, M=1, Offset = 01980 bytesIPDataIPHeaderLength = 1840, M=0, Offset = 19801820 byteshostrouterMTU = 1500IPHeaderIPDataLength = 1500, M=1, Offset = 01480 bytesIPHeaderIPDataLength = 520, M=1, Offset = 1480500 bytesIPHeaderIPDataLength = 1500, M=1, Offset = 19801480 bytesIPHeaderIPDataLength = 360, M=0, Offset = 3460340 bytes14IP Reassembly•Fragments might arrive out-of-order–Don’t know how much memory required until receive final fragment•Some fragments may never arrive–After a while, give up entire processIPHeaderIPDataLength = 1500, M=1, Offset = 0IPHeaderIPDataLength = 520, M=1, Offset = 1480IPHeaderIPDataLength = 1500, M=1, Offset = 1980IPHeaderIPDataLength = 360, M=0, Offset = 3460IPDataIPDataIPDataIPData15Fragmentation and Reassembly•Demonstrates many Internet concepts–Decentralized•Every network can choose MTU–Connectionless•Each fragment contains full routing information•Fragments can proceed independently and along different routes–Complex endpoints and simple routers (david clark paper)•Reassembly at endpoints•Uses resources poorly–Forwarding, replication, encapsulations costs–Worst case: packet just bigger than MTU–Poor end-to-end performance•Loss of a fragment •How to avoid fragmentation?–Path MTU discovery protocol  determines minimum MTU along route–Uses ICMP error messages16Internet Control Message Protocol (ICMP)•Short messages used to


View Full Document

UW-Madison CS 640 - Packets and Routers

Documents in this Course
Security

Security

21 pages

Mobile IP

Mobile IP

16 pages

Lecture 7

Lecture 7

36 pages

Multicast

Multicast

38 pages

Load more
Download Packets and Routers
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Packets and Routers and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Packets and Routers 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?