Chapter 81 Internet Protocol (IP) Our greatest glory is not in never failing, but in rising up every time we fail. - Ralph Waldo Emerson.

Slides:



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

Computer Networks20-1 Chapter 20. Network Layer: Internet Protocol 20.1 Internetworking 20.2 IPv IPv6.
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
IP Fragmentation. MTU Maximum Transmission Unit (MTU) –Largest IP packet a network will accept –Arriving IP packet may be larger IP Packet MTU.
Network Layer – IPv4 Dr. Sanjay P. Ahuja, Ph.D.
TCP/IP TCP/IP architecture
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.
Network Layer Packet Forwarding IS250 Spring 2010
IP Suite© Dr. Ayman Abdel-Hamid, CS4254 Spring CS4254 Computer Network Architecture and Programming Dr. Ayman A. Abdel-Hamid Computer Science Department.
© 2007 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets with Internet Applications, 4e By Douglas.
IP Protocol. The Internet Protocol (IP) is a network-layer (Layer 3) protocol that contains addressing information and some control information that enables.
CSCI 4550/8556 Computer Networks Comer, Chapter 20: IP Datagrams and Datagram Forwarding.
Oct 19, 2004CS573: Network Protocols and Standards1 IP: Datagram and Addressing Network Protocols and Standards Autumn
IPv6 Fundamentals Chapter 2: IPv6 Protocol
Module 10. Internet Protocol (IP) is the routed protocol of the Internet. IP addressing enables packets to be routed from source to destination using.
© Janice Regan, CMPT 128, CMPT 371 Data Communications and Networking Network Layer ICMP and fragmentation.
The Network Layer. Network Projects Must utilize sockets programming –Client and Server –Any platform Please submit one page proposal Can work individually.
TCOM 509 – Internet Protocols (TCP/IP) Lecture 03_a
© 2007 Cisco Systems, Inc. All rights reserved.Cisco Public 1 Version 4.0 OSI Network Layer Network Fundamentals – Chapter 5.
10/13/20151 TCP/IP Transmission Control Protocol Internet Protocol.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
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.
Suez Canal University – Faculty of Computers & Informatics - Cisco Local Academy Network Fundamentals.
TCOM 515 IP Routing. Syllabus Objectives IP header IP addresses, classes and subnetting Routing tables Routing decisions Directly connected routes Static.
Dr. John P. Abraham Professor UTPA
Internet Protocol --- Connectionless Datagram Delivery Linda Wu (CMPT )
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.
CS4550 Computer Networks II IP : internet protocol, part 2 : packet formats, routing, routing tables, ICMP read feit chapter 6.
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.
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
Internet Protocols (chapter 18) CSE 3213 Fall 2011.
Chapter 20 Network Layer: Internet Protocol
Network Layer4-1 Datagram networks r no call setup at network layer r routers: no state about end-to-end connections m no network-level concept of “connection”
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.
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.
Net7: IP 協定 Internet Protocol 授課教師:雲林科技大學 張慶龍 老師.
1 Internetworking: IP Packet Switching Reading: (except Implementation; pp )
IP Protocol CSE TCP/IP Concepts Connectionless Operation Internetworking involves connectionless operation at the level of the Internet Protocol.
Network Layer Protocols COMP 3270 Computer Networks Computing Science Thompson Rivers University.
Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Packet Switch Network Server client IP Ether IPTCPData.
20.1 Chapter 20 Network Layer: Internet Protocol Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Chapter 19 Network Layer Protocols
Behrouz A. Forouzan TCP/IP Protocol Suite, 3rd Ed.
IP - The Internet Protocol
Network Layer Protocols
IP - The Internet Protocol
Internet Protocol Version4
IP - The Internet Protocol
Guide to TCP/IP Fourth Edition
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
ITIS 6167/8167: Network and Information Security
IP - The Internet Protocol
NET 323D: Networks Protocols
Presentation transcript:

Chapter 81 Internet Protocol (IP) Our greatest glory is not in never failing, but in rising up every time we fail. - Ralph Waldo Emerson

Chapter 8 2 Objectives Explain how routers process IP packets in IP networks Describe the structure of the IP header and explain functions of header fields Explain the packet fragmentation process in IP and the re-assembly process

Chapter 8 3 Network Layer Protocols The primary function of a routed or routable Network layer protocol is to move datagrams through an internetwork connected by routers, with the originator as the source Network layer address, and the target as the destination Network layer address Internet Protocol is the routed or routable Network layer protocol used in the Internet protocol suite Widely used version is IP version 4 (IPv4) Internet Protocol version 6 (IPv6) is undergoing initial deployments

Chapter 8 4 Sending IP Datagrams IP offers connectionless service with end-to-end Network layer addressing To build an IP datagram (or, an IP packet) and to send it on the physical medium, we must know the: –IP addresses of the source and destination –Hardware addresses of the source and recipient of the data link frame Source host needs to resolve a destination host name to an IP address. This is called the name resolution process

Chapter 8 5 Destination host is local or remote? After determining the destination IP address, the source host compares the network portion of the destination address to its own local network address If they are the same, the destination is on the same local network. Otherwise, the destination is on a remote network

Chapter 8 6 When the source and destination hosts are on the same network If the source host determines that the destination is local, it encapsulates the IP packet in a data link frame with destination host’s MAC address and sends this frame to the local network. Destination host on the local network accepts this frame, removes the data link header and trailer and forwards the IP packet to its network layer. A router does not get involved when the source and destination hosts are on the same network.

Chapter 8 7 Example In Figure 2.18 a host with physical address 10 sends a frame to a host with physical address 87. The two hosts are on the same LAN. At the data link level this frame contains physical (link) addresses in the header. These are the only addresses needed. The rest of the header contains other information needed at this level. The trailer usually contains extra bits needed for error detection.

Chapter 8 8 Frame delivery using Physical (or, MAC) addresses at Data Link Layer Figure. 2.18

Chapter 8 9 When the destination host is remote... If the source host determines that the destination host is remote (i.e., in a different network), the IP packet must be forwarded to a router on the local network. The router will then forward the packet towards its final destination. Source host consults its “Routing Table” and determines the IP address of the local router the packet should be forwarded to. Using ARP (Address Resolution Protocol) Cache entries or ARP process, source host finds the MAC address of the router, builds a data link frame and sends it to the local network.

Chapter 8 10 Example Hosts A & P are in different networks. A packet sent by A contains source and destination IP addresses (A and P, in Fig. 2.19). They remain the same from the original source to the final destination and will not change when packets go from one network to another network. However, the physical addresses will change as the packet moves from one network to another.

Chapter 8 11 Packets moving from one network to another (Fig. 2.19)

Chapter 8 12 Processing done by the local router... When a router receives a data link frame, after checking for errors, the data link header and trailer are removed (de-capsulation) and the IP packet is sent to the network layer of the router. After checking the IP Header Checksum, the destination IP address is extracted from the packet header. Router consults its routing table to determine the interface on which the received packet should be forwarded on.

Chapter 8 13 Processing done by the local router... Router builds a data link frame encapsulating the IP packet and forwards it through the interface indicated by the routing table. If the router has a direct connection to the destination network, in building the data link frame, it uses the MAC address of the destination host as the destination MAC address in the data link frame header. Router uses the MAC address of its interface used to forward the packet as the source MAC address in the frame header.

Chapter 8 14 When the packet reaches the destination network... Source and Destination IP addresses are not changed by routers (unless a router has to substitute the source address in the packet with a different IP address, as a part of the Network Address Translation process). The destination host accepts the data link frame addressed to it (with destination host’s MAC address as the destination address in the frame). Through the de-capsulation process in data link, network and transport layers, the data sent by the source application is finally forwarded to the destination host’s application.

Chapter 8 15 Internet Protocol (IP) Originally defined in RFC 791 IP header fields and functions Lifetime of an IP datagram Fragmentation and reassembly Supporting Quality of Service (QoS) Checksum calculations and IP Options will not be discussed

Chapter 8 16 IP Header Fields and Functions

Chapter 8 17 Version field Most widely used version is 4 Total Length field Total length of the IP datagram in bytes (including IP Header and the payload)

Chapter 8 18 Protocol Field Identifies the upper layer protocol process on the destination host, to which the received IP data should be delivered Examples: (see RFC 1700 for complete list) “Protocol” valueForward IP Payload to: 1ICMP 2IGMP 6TCP 17UDP

Chapter 8 19 Header Checksum field Provides error detection (not correction) on the IP header bytes only. This checksum does not cover the IP payload. The receiving host/router computes the Header Checksum and compares its computed checksum with the checksum in the received IP header. If they don’t match, the packet is discarded and an ICMP message is sent to the source host.

Chapter 8 20 Source Address field Contains the IP address of the host that originated the packet Destination Address field Indicates the IP address of the destination host This field can include a unicast, multicast or a broadcast address

Chapter 8 21 Header Length field Indicates the length of the IP header in multiples of four bytes If the “Header Length” field is 5, length of the IP header is 5 x 4 => 20 bytes Used by a receiving host/router to extract the header bytes. Because of “Options”, the receiving host/router will otherwise not know exact length of the IP header.

Chapter 8 22 Time to Live (TTL) field Built-in mechanism to ensure that packets cannot indefinitely travel due to routing loops Source host sets the TTL value to some default initial value (such as: 32, 64, 128) When a router receives an IP packet, it decrements the TTL value by 1 before forwarding it to the next router After decrementing, if TTL value is 0, router must discard the packet and send an ICMP message to the source indicating why packet was discarded

Chapter 8 23 Lifetime of an IP Datagram If a packet with TTL=1 arrives at a host, what should the host do? –The host will process the packet The hosts do not need to decrement the TTL value upon receipt TRACEROUTE uses the TTL value to trace the end-to-end path through an internetwork

Chapter 8 24 Identification Field Each IP packet is given a unique ID number by the source host If the packet must be fragmented by a router to fit on a network that has a smaller MTU (Max. Transmission Unit) size, the same ID number is placed in each fragment During reassembly, a destination host uses ID value to identify fragments that belong to the same original datagram

Chapter 8 25 Fragmentation and Reassembly IP fragmentation enables a larger packet to be fragmented by a router into smaller packets to cross a link that supports a smaller MTU size Once fragmented, no reassembly occurs until all the fragments arrive at the destination. Routers along the path to the destination host do not attempt reassembly of fragmented datagrams - Why?

Chapter 8 26 Fragment Offset field Used by the destination host in reassembling the received fragments in the correct order to form the original datagram If the packet is a fragment, this field shows the destination host where to place this packet’s data when the fragments are reassembled

Chapter 8 27 Flags field Three bits: Reserved, DF and MF bits DF (Don’t Fragment) bit: –If 0, routers can fragment the packet, if needed –If 1, routers must not fragment the packet MF (More Fragments) bit: –Used during reassembly by destination host –If 0, this is the last fragment –If 1, more fragments to follow

Chapter 8 28 Fragmentation and Reassembly The first fragment of a packet: –More bit = 1; Offset = 0 Intermediate fragments: –More bit = 1; Offset = non-zero Last fragment –More bit = 0; Offset = non-zero When the fragments arrive at the destination IP host, they are put back in the correct order based on the Fragment Offset value in the IP header

Chapter 8 29 Type of Service field TOS byte has two components: –3 Precedence bits –4 Type of Service bits –1 Reserved bit Not implemented by routers or applications If implemented, a router uses precedence bits to determine what packet to send next when many packets are queued up for forwarding through an interface –Reduces the waiting time (delay or latency) for a high precedence packet inside a router

Chapter 8 30 Type of Service (TOS) Bits If implemented, routers use TOS bits in determining the interface on which a packet should be forwarded, when multiple paths are available to the destination Does not reduce the delay experienced by a packet inside a router, but impacts the path taken by a packet through the network TOS Value Interpretation by a router 0Default 4Maximize throughput 8Minimize delay 15Maximize security

Chapter 8 31 Type of Service (TOS) Bits If implemented, routers use TOS bits in determining the interface on which a packet should be forwarded, when multiple paths are available to the destination Does not reduce the delay experienced by a packet inside a router, but impacts the path taken by a packet through the network Protocol TOS Value Interpretation by a router ICMP 0Routine (Default) SNMP2Maximize reliability FTP Data4Maximize throughput Telnet8Minimize delay

Chapter 8 32 Redefining the TOS Byte... RFC 2474 “Definition of the Differentiated Services Field (DS Field) in the IPv4 and IPv6 Headers” has redefined the original TOS byte as Differentiated Services Code Point (DSCP) field (6 bits) for supporting Quality of Service (QoS) for new applications such as voice Two bits in the original TOS byte were left as “unused” by RFC 2474

Chapter 8 33 Redefining the TOS Byte...

Chapter 8 34 Options field The IP header can be extended by several options (although these options are not often used) If the header is extended with options, those options must end on a 4-byte boundary because the Internet Header Length (IHL) field defines the header length in 4-byte boundaries Padding bytes are used to make the length of “Options” field to be a multiple of 4 bytes

Chapter 8 35 References RFC 1180, A TCP/IP Tutorial, Jan Douglas Comer, “Internetworking With TCP/IP Volume 1: Principles Protocols, and Architecture,” 5th Edition, Prentice Hall, 2006 W. Richard Stevens, “TCP/IP Illustrated Volume 1: The Protocols,” Addison Wesley, 1994

Chapter 8 36