Internet Protocol --- Connectionless Datagram Delivery Linda Wu (CMPT 471 2003-3)

Slides:



Advertisements
Similar presentations
1 IP - The Internet Protocol Relates to Lab 2. A module on the Internet Protocol.
Advertisements

CE363 Data Communications & Networking Chapter 7 Network Layer: Internet Protocol.
U N I T - 3.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
IPv4 - The Internet Protocol Version 4
1 IP - The Internet Protocol Relates to Lab 2. A module on the Internet Protocol.
CECS 474 Computer Network Interoperability Notes for Douglas E. Comer, Computer Networks and Internets (5 th Edition) Tracy Bradley Maples, Ph.D. Computer.
Chapter 20 Network Layer: Internet Protocol Stephen Kim 20.1.
Internet Protocol (IP)
Shivkumar Kalyanaraman Rensselaer Polytechnic Institute 5-1 Internet Protocol (IP): Packet Format, Fragmentation, Options Shivkumar Kalyanaraman Rensselaer.
1 K. Salah Module 5.2: Internet Protocol CO vs. CL protocols IP Features –Fragmentation –Routing IP Datagram Format IPv6.
1 TDC TDC 365 Network Interconnections Technologies Lecture #4 Notes Spring, 2009.
CS335 Networking & Network Administration Tuesday, May 11, 2010.
CSCI 4550/8556 Computer Networks Comer, Chapter 20: IP Datagrams and Datagram Forwarding.
© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints.
© 2007 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets with Internet Applications, 4e By Douglas.
Oct 19, 2004CS573: Network Protocols and Standards1 IP: Datagram and Addressing Network Protocols and Standards Autumn
© Janice Regan, CMPT 128, CMPT 371 Data Communications and Networking Network Layer ICMP and fragmentation.
TCOM 509 – Internet Protocols (TCP/IP) Lecture 03_a
Internet Protocol: Connectionless Datagram Delivery (IPv4)
Network Layer Last Update Copyright Kenneth M. Chipps Ph.D.
Fall 2005Computer Networks20-1 Chapter 20. Network Layer Protocols: ARP, IPv4, ICMPv4, IPv6, and ICMPv ARP 20.2 IP 20.3 ICMP 20.4 IPv6.
Microsoft Windows Server 2003 TCP/IP Protocols and Services Technical Reference Slide: 1 Lesson 5 Internet Protocol (IP) Basics.
1 IP : Internet Protocol Computer Network System Sirak Kaewjamnong.
Dr. John P. Abraham Professor UTPA
Chapter 81 Internet Protocol (IP) Our greatest glory is not in never failing, but in rising up every time we fail. - Ralph Waldo Emerson.
Internetworking Internet: A network among networks, or a network of networks Allows accommodation of multiple network technologies Universal Service Routers.
ECE 4110 – Internetwork Programming IP Protocol. 2 * From TCP/IP Protocol Suite, B. A. Forouzan, Prentice Hall Position of IP in TCP/IP Protocol Suite.
Internetworking Internet: A network among networks, or a network of networks Allows accommodation of multiple network technologies Universal Service Routers.
The Internet Protocol Dr. Adil Yousif. 2  IP (Internet Protocol) is a Network Layer Protocol. Orientation.
NET0183 Networks and Communications Lectures 15 and 16 Datagram Forwarding 8/25/20091 NET0183 Networks and Communications by Dr Andy Brooks Lecture powerpoints.
TCP/IP Protocol Suite 1 Chapter 8 Upon completion you will be able to: Internet Protocol Understand the format and fields of a datagram Understand the.
Communications Services Connection Oriented Service  A connection is established  Data is sent or received over this connection  Connection may be terminated.
CS 4396 Computer Networks Lab
Jan 15, 2008CS573: Network Protocols and Standards1 The Internet Protocol: Related Protocols and Standards (IP datagram, addressing, ARP) Network Protocols.
1 Kyung Hee University Chapter 8 Internet Protocol (IP)
TCP/IP Protocol Suite 1 Chapter 8 Upon completion you will be able to: Internet Protocol Understand the format and fields of a datagram Understand the.
© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints.
CSC 600 Internetworking with TCP/IP Unit 5: IP, IP Routing, and ICMP (ch. 7, ch. 8, ch. 9, ch. 10) Dr. Cheer-Sun Yang Spring 2001.
Chapter 8 Internet Protocol (IP)
1 Computer Communication & Networks Lecture 19 Network Layer: IP and Address Mapping Waleed Ejaz.
Internet Protocol Version 4 VersionHeader Length Type of Service Total Length IdentificationFragment Offset Time to LiveProtocolHeader Checksum Source.
1 Internetworking: IP Packet Switching Reading: (except Implementation; pp )
COMPUTER NETWORKS CS610 Lecture-30 Hammad Khalid Khan.
Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
TCP/IP Protocol Suite 1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 7 Internet Protocol Version4.
Packet Switch Network Server client IP Ether IPTCPData.
IPv4 IPv4 The Internet Protocol version 4 (IPv4) is the delivery mechanism used by the TCP/IP protocols. Datagram Fragmentation Checksum Options Topics.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Behrouz A. Forouzan TCP/IP Protocol Suite, 3rd Ed.
IP - The Internet Protocol
7 Network Layer Part IV Computer Networks Tutun Juhana
Chapter 8: Internet Protocol (IP)
Chapter 7: The Infamous IP
Internet Protocol: Connectionless Datagram Delivery
IP - The Internet Protocol
Internet Protocol Version4
IP - The Internet Protocol
Chapter 7: The Infamous IP
Dr. John P. Abraham Professor UTPA
Dr. John P. Abraham Professor UTRGV, EDINBURG, TX
IP - The Internet Protocol
Dr. John P. Abraham Professor UTPA
Net 323 D: Networks Protocols
IP - The Internet Protocol
Chapter 7 Internet Protocol Version 4 (IPv4)
Internet Protocol (IP)
ITIS 6167/8167: Network and Information Security
IP - The Internet Protocol
NET 323D: Networks Protocols
Presentation transcript:

Internet Protocol --- Connectionless Datagram Delivery Linda Wu (CMPT )

Notes-5 CMPT 471  Content  TCP/IP internet services  Internet datagram format  Fragmentation & Reassembly  Datagram fields Reference: chapter 7

Notes-5 CMPT 471  TCP/IP Internet Services  Networking services are arranged in a hierarchy  Internet software is designed around three conceptual networking services  Replacing one service will not disturb others Application services (SMTP, FTP, DNS, … SNMP) Reliable transport service (TCP, UDP) Connectionless packet delivery service (IP, ICMP, IGMP, ARP, RARP) Application layer Transport layer Network layer

Notes-5 CMPT 471  TCP/IP Internet Services (cont.)  Connectionless delivery system Data are split into several packets Unreliable: delivery is not guaranteed; packet may be lost, duplicated, delayed Connectionless: each packet is treated independently from all others Best-effort: internet software makes an earnest attempt to deliver packets; unreliability arises only when resources are exhausted or networks fail

Notes-5 CMPT 471  TCP/IP Internet Services (cont.)  Internet protocol (IP) IP protocol defines the unreliable, connectionless delivery mechanism, and provides 3 important definitions: Format of data passed across the internet  internet transfer unit is called internet datagram Routing function Rules of unreliable packet delivery: packet processing, error handling, etc.

Notes-5 CMPT 471  Internet Datagram Format  Internet datagram (IP datagram, datagram)  Datagram vs. frame DatagramFrame Divided into header and data Transfer unit of internet Transfer unit of physical network Handled by softwareRecognized by hardware Header contains src. / dest. IP addresses Header contains src. / dest. physical addresses Datagram headerDatagram data area

Notes-5 CMPT 471  Internet Datagram Format (cont.)  Datagram format VERSHLENSVC TYPETOTAL LENGTH IDENTIFICATIONFLAGSFRAGMENT OFFSET TIME TO LIVE PROTOCOLHEADER CHECKSUM SOURCE IP ADDRESS DESTINATION IP ADDRESS IP OPTIONS (IF ANY)PADDING DATA ……

Notes-5 CMPT 471  Fragmentation & Reassembly  IPv4 datagram length  2 16 –1 = 65,535 Includes the length of header and data  Network MTU Maximum transfer unit (MTU): each hardware technology places a fixed upper bound on the amount of data transferred in one frame Ethernet MTU: 1500 (bytes/frame) FDDI MTU: 4470

Notes-5 CMPT 471  Fragmentation & Reassembly (cont.)  Datagram encapsulation Carrying one datagram in one frame Hardware does not recognize datagram format Efficient transportation Datagram header Datagram data area Frame header Frame data areaFrame trailer  MTU

Notes-5 CMPT 471  Fragmentation & Reassembly (cont.)  MTU vs. datagram length Limiting datagram to fit the smallest possible MTU makes transfer inefficient Allowing datagrams to be larger than the minimum MTU means a datagram cannot always fit into a single frame Solution in IP protocol: datagram fragmentation

Notes-5 CMPT 471  Fragmentation & Reassembly (cont.)  Datagram fragmentation The source chooses a convenient datagram size Intermediate routers divide large datagram into small fragments when needed Fragments may not be of equal size; their sizes must be multiple of 8 Each fragment can be shipped in a single frame Router must accept datagram up to the maximal MTUs of the networks they attach to Fragments travel to the destination as separate datagrams

Notes-5 CMPT 471  Fragmentation & Reassembly (cont.) Header 20 bytes Data1 600 bytes Data2 600 bytes Data3 200 bytes A Net 1 MTU=1500 B Net 3 MTU=1500 Net 2 MTU=620 R1 R2 Fragmt. 2 header Data2 Fragmt. 1 header Data1 Fragmt. 3 header Data3 Fragment 1 (offset: 0/8) Fragment 2 (offset: 600/8) Fragment 3 (offset: 1200/8) Original datagram: A  B (1400 bytes of data) Fragment header duplicates most of the fields in the datagram header Fragmentation at R1:

Notes-5 CMPT 471  Fragmentation & Reassembly (cont.)  Reassembly at ultimate destination Reassembly timer  Started when an initial fragment is received  If the timer expires before all fragments arrive, all the received fragments will be discarded Advantages  Fragments are routed independently  Intermediate routers are not required to store or reassemble fragments Disadvantages  Small fragments may traverse on networks with large MTU capability  If any fragment is lost, datagram cannot be reassembled

Notes-5 CMPT 471  Datagram Fields  VERS 4 bits Specifies the version of IP protocol used to create the datagram To verify that sender, receiver and any router in between them agree on the datagram format Machines reject datagram with protocol version that differs from theirs Current version: 4 (IPv4)

Notes-5 CMPT 471  Datagram Fields (cont.)  HLEN 4 bits Specifies datagram header length (unit: 32-bit word / 4 bytes)  TOTAL LENGTH 16 bits Specifies # of bytes in header and data (unit: byte) TOTAL LENGTH  2 16 –1 = 65,535 Size of data = TOTAL LENGTH - HLEN

Notes-5 CMPT 471  Datagram Fields (cont.)  SERVICE TYPE 8 bits Original TOS interpretation PrecedenceDTR Unused Precedence: importance of datagram D: low delay T: high throughput R: high reliability

Notes-5 CMPT 471  Datagram Fields (cont.) Revised differentiated services interpretation  A codepoint value maps to an underlying service definition  3 right-most bits of codepoint All 0s: xxx000 (backward compatible with original interpretation) Not all 0s: 3 administrative groups Codepoint (DSCP)Unused PoolCodepointInterpretation assigned by 1xxxxx0IETF (Internet Authority) 2xxxx11Local or experimental 3xxxx01Local or experimental for now

Notes-5 CMPT 471  Datagram Fields (cont.)  Fragmentation control fields IDENTIFICATION  Datagram sender generates a unique IDENTIFICATION for each datagram  It is copied to fragment header for reassembly at a later time  Source address + IDENTIFICATION: to identify datagram FRAGMENT OFFSET  The offset in the original datagram of the data carried in the fragment (unit: 8 bytes)

Notes-5 CMPT 471  Datagram Fields (cont.) FLAGS: 3 bits  D: do not fragment When a router needs to fragment a datagram with D bit set, it will discard the datagram and send an error message to the source  M: more fragments To indicate whether a fragment is the tail of the datagram Destination gets the TOTAL LENGTH of the fragment instead of the original datagram Upon receiving a fragment F with M bit off, calculate total length of the datagram based on F’s total length and F’s fragment offset 012 ReservedD M

Notes-5 CMPT 471  Datagram Fields (cont.)  TIME TO LIVE (TTL) Defines hop limit of a datagram Each router along the path from source to destination decrements TTL by 1 If datagram’s TTL filed is 0, router discards datagram and sends back an error message to the source Objective: to guarantees that datagrams cannot travel around internet forever

Notes-5 CMPT 471  Datagram Fields (cont.)  PROTOCOL 8 bits Defines the higher-level protocol to which datagram should be delivered ValueProtocol 1ICMP 2IGMP 6TCP 17UDP 89OSPF

Notes-5 CMPT 471  Datagram Fields (cont.)  HEADER CHECKSUM To ensure integrity of header  Calculated at the sender and the value obtained is sent with datagram  The receiver repeats the same calculation If the result is satisfactory, accept the datagram Otherwise, reject it Only applies to values in header, not to data

Notes-5 CMPT 471  Datagram Fields (cont.)  SOURCE / DESTINATION IP ADDRESS Specifies sender / intended recipient of datagram Never changes when datagram is routed through intermediate routers  DATA Specifies the data sent in datagram Variable length  PADDING Composed of all 0s Its length depends on IP OPTIONS selected To ensure the datagram header extends to an exact multiple of 32 bits

Notes-5 CMPT 471  Datagram Fields (cont.)  IP OPTIONS Optional fields with variable length Appear contiguously without separators between them Format CODE (8 bits) LENGTH ( 8 bits) DATA (variable length) COPY 1 bit CLASS 2 bits NUMBER 5 bits COPY 0 Copy only in the first fragment 1 Copy in all fragments CLASS 00 Datagram control 01 Reserved 10Debugging and management 11 Reserved NUMBER See examples on P109 LENGTH: total length of the option, including code field and length field DATA: data that specific options require

Notes-5 CMPT 471  Datagram Fields (cont.)  Record route option To record the routers that handle the datagram POINTER: the offset within option of the next available slot When a machine handles a datagram with record route option  If POINTER > LENGTH, forward datagram without inserting its entry  Otherwise, insert its entry, increase POINTER by CODE (7)LENGTHPOINTER First IP Address (empty when started) Second IP Address (empty when started) ……

Notes-5 CMPT 471  Datagram Fields (cont.)  Source route option Used by the source to predetermine a route for the datagram At the router side  If POINTER > LENGTH, do routing as usual  Otherwise, follow POINTER to pickup IP address, replace it with its outgoing IP address, increase POINTER by 4, and forward the datagram CODE (137 / 131) LENGTHPOINTER IP Address of First Hop (filled when started) IP Address of Second Hop (filled when started) ……

Notes-5 CMPT 471  Datagram Fields (cont.) Strict source route (CODE 137)  All the routers in the option must be visited  A router not listed in the option must not be visited  If datagram visits a router not in the list, or, if it arrives at destination with some listed routers not visited, the datagram is discarded and an error message is issued Loose source route (CODE 131)  Each router in the list must be visited  The datagram can visit other routers as well

Notes-5 CMPT 471  Datagram Fields (cont.)  Timestamp option To record the time at which router processes datagram To keep track of router behavior in the internet OFLOW: # of routers that cannot supply a timestamp because the option is full FLAGS: specifies the visited router responsibilities Timestamp: time and date at which router processes datagram; expressed as milliseconds since midnight, Universal Time CODE (68)LENGTHPOINTEROFLOWFLAGS First IP Address First Timestamp …

Notes-5 CMPT 471  Datagram Fields (cont.) Subfield: FLAGS FLAGS valueMeaning 0Record timestamp only; omit IP address 1Precede each timestamp by an IP address 3IP addresses are specified by sender; a router only records a timestamp if its IP address matches the next IP address in the list

Notes-5 CMPT 471  Datagram Fields (cont.)  Processing IP OPTIONs during fragmentation The function of COPY bit in fragmentation  Some IP OPTIONs are replicated in all fragments  Some IP OPTIONs are placed in one fragment Record route option should only be copied into one of the fragments Source route option should be copied into all fragments