Goal of Today s Lecture. EE 122: Designing IP. The Internet Hourglass. Our Story So Far (Context) Our Story So Far (Context), Con t

Similar documents
Announcements. Designing IP. Our Story So Far (Context) Goals of Today s Lecture. Our Story So Far (Context), Con t. The Internet Hourglass

IP Packet Switching. Goals of Todayʼs Lecture. Simple Network: Nodes and a Link. Connectivity Links and nodes Circuit switching Packet switching

Goals for Today s Class. EE 122: Networks & Protocols. What Global (non-digital) Communication Network Do You Use Every Day?

Ref: A. Leon Garcia and I. Widjaja, Communication Networks, 2 nd Ed. McGraw Hill, 2006 Latest update of this lecture was on

Lecture 9: Internetworking

EE 122: IP Forwarding and Transport Protocols

IP - The Internet Protocol. Based on the slides of Dr. Jorg Liebeherr, University of Virginia

CS4450. Computer Networks: Architecture and Protocols. Lecture 13 THE Internet Protocol. Spring 2018 Rachit Agarwal

Page 1. Goals for Today" What Is A Protocol?" CS162 Operating Systems and Systems Programming Lecture 10. Protocols, Layering and e2e Argument"

Announcements. IP Forwarding & Transport Protocols. Goals of Today s Lecture. Are 32-bit Addresses Enough? Summary of IP Addressing.

ECE 4450:427/527 - Computer Networks Spring 2017

Position of IP and other network-layer protocols in TCP/IP protocol suite

Internet Design Principles

IPv4 Lecture 10a. COMPSCI 726 Network Defence and Countermeasures. Muhammad Rizwan Asghar. August 14, 2017

Department of Computer and IT Engineering University of Kurdistan. Network Layer. By: Dr. Alireza Abdollahpouri

Introduction to Internetworking

ECE 158A: Lecture 7. Fall 2015

Introduction. IP Datagrams. Internet Service Paradigm. Routers and Routing Tables. Datagram Forwarding. Example Internet and Conceptual Routing Table

Introduction to Internetworking

Chapter 5 OSI Network Layer

CompSci 356: Computer Network Architectures. Lecture 8: Spanning Tree Algorithm and Basic Internetworking Ch & 3.2. Xiaowei Yang

EE 122: Introduction To Communication Networks. Some Questions & Answers

The Transmission Control Protocol (TCP)

Communications Software. CSE 123b. CSE 123b. Spring Lecture 2: Internet architecture and. Internetworking. Stefan Savage

ECE4110 Internetwork Programming. Introduction and Overview

STEVEN R. BAGLEY PACKETS

CS519: Computer Networks. Lecture 2: Feb 2, 2004 IP (Internet Protocol)

ET4254 Communications and Networking 1

Chapter 20 Network Layer: Internet Protocol 20.1

Lecture 17 Overview. Last Lecture. Wide Area Networking (2) This Lecture. Internet Protocol (1) Source: chapters 2.2, 2.3,18.4, 19.1, 9.

Prof. Shervin Shirmohammadi SITE, University of Ottawa. Internet Protocol (IP) Lecture 2: Prof. Shervin Shirmohammadi CEG

416 Distributed Systems. Networks review; Day 1 of 2 Jan 5 + 8, 2018

Ch.7 Internet Protocol: Connectionless Datagram Delivery (IPv4, IPv6)

TCP Service Model. Today s Lecture. TCP Support for Reliable Delivery. EE 122:TCP, Connection Setup, Reliability

OSI Network Layer. Network Fundamentals Chapter 5. Version Cisco Systems, Inc. All rights reserved. Cisco Public 1

Internet Protocols (chapter 18)

Question. Reliable Transport: The Prequel. Don t parse my words too carefully. Don t be intimidated. Decisions and Their Principles.

Internet Control Message Protocol (ICMP)

Internet Networking recitation #2 IP Checksum, Fragmentation

The Internetworking Problem. Internetworking. A Translation-based Solution

Fragmentation. Agenda for Today. IP Addressing and Forwarding (with some review of IP) Why do I care about fragmentation?

Vorlesung Kommunikationsnetze

COMP/ELEC 429/556 Introduction to Computer Networks

IP Addressing and Forwarding (with some review of IP)

Internetwork Protocols

CS 4390 Computer Networks. Transport Services and Protocols

The IP Data Plane: Packets and Routers

ELEC / COMP 177 Fall Some slides from Kurose and Ross, Computer Networking, 5 th Edition

Goals of Today s Lecture. Adaptors Communicating

EE 610 Part 2: Encapsulation and network utilities

Network Layer (1) Networked Systems 3 Lecture 8

CS 356: Computer Network Architectures. Lecture 10: IP Fragmentation, ARP, and ICMP. Xiaowei Yang

Where we are in the Course

Information Network Systems The network layer. Stephan Sigg

TCP/IP THE TCP/IP ARCHITECTURE

TCP /IP Fundamentals Mr. Cantu

CMPE 80N: Introduction to Networking and the Internet

Network Layer. IP Protocol Stack: Key AbstracHons. Best- Effort Global Packet Delivery. Circuit Switching (e.g., Phone Network)

INTERNET SYSTEM. Internet Protocol. Kent State University Dept. of Computer Science. CS 4/55231 Internet Engineering. Large Scale Networking

CSCI-1680 Network Layer: IP & Forwarding Rodrigo Fonseca

Internetworking Terms. Internet Structure. Internet Structure. Chapter 15&16 Internetworking. Internetwork Structure & Terms

Lecture 18 Overview. Last Lecture. This Lecture. Next Lecture. Internet Protocol (1) Internet Protocol (2)

Administrivia CSC458 Lecture 4 Bridging LANs and IP. Last Time. This Time -- Switching (a.k.a. Bridging)

Telecom Systems Chae Y. Lee. Contents. Overview. Issues. Addressing ARP. Adapting Datagram Size Notes

CSE 123b Communications Software

Probability, Preview, and Principles

CS 268: Internet Architecture & E2E Arguments. Today s Agenda. Scott Shenker and Ion Stoica (Fall, 2010) Design goals.

Lecture 2: Basic routing, ARP, and basic IP

Chapter 7 Internet Protocol Version 4 (IPv4) Kyung Hee University

CC231 Introduction to Networks Dr. Ayman A. Abdel-Hamid. Internet Protocol Suite

User Datagram Protocol

Internet Protocol. Outline Introduction to Internet Protocol Header and address formats ICMP Tools CS 640 1

The Internet. 9.1 Introduction. The Internet is a global network that supports a variety of interpersonal and interactive multimedia applications.

Networking: Network layer

Computer Network Fundamentals Spring Week 4 Network Layer Andreas Terzis

Chapter 2 - Part 1. The TCP/IP Protocol: The Language of the Internet

OSI Network Layer. Chapter 5

EP2120 Internetworking/Internetteknik IK2218 Internets Protokoll och Principer

CS 457 Lecture 11 More IP Networking. Fall 2011

The Network Layer. Antonio Carzaniga. April 22, Faculty of Informatics University of Lugano Antonio Carzaniga

cs144 Midterm Review Fall 2010

Page 1. Goals for Today" Discussion" Example: Reliable File Transfer" CS162 Operating Systems and Systems Programming Lecture 11

CSCI-1680 Network Layer: IP & Forwarding Rodrigo Fonseca

The OSI Model. Open Systems Interconnection (OSI). Developed by the International Organization for Standardization (ISO).

CSCI-1680 Network Layer: IP & Forwarding John Jannotti

CSE/EE 461 The Network Layer. Application Presentation Session Transport Network Data Link Physical

IP : Internet Protocol

B.Sc. (Hons.) Computer Science with Network Security B.Eng. (Hons) Telecommunications B.Sc. (Hons) Business Information Systems

ICS 451: Today's plan

CS 457 Networking and the Internet. Network Overview (cont d) 8/29/16. Circuit Switching (e.g., Phone Network) Fall 2016 Indrajit Ray

Welcome (day 2) CSE 123b Communications Software. Application layer (HTTP) Application layer? Name resolution (DNS) Transport layer (TCP)

Lecture 8. Basic Internetworking (IP) Outline. Basic Internetworking (IP) Basic Internetworking (IP) Service Model

ECE 461 Internetworking Fall Quiz 1

Introduction to TCP/IP networking

Networking Overview. CS Computer Security Profs. Vern Paxson & David Wagner

Introduction to Networks and the Internet

Lecture 8. Reminder: Homework 3, Programming Project 2 due on Thursday. Questions? Tuesday, September 20 CS 475 Networks - Lecture 8 1

Announcement. Homework 1 due last night, how is that? Will discuss some problems in the lecture next week

Goals and topics. Verkkomedian perusteet Fundamentals of Network Media T Circuit switching networks. Topics. Packet-switching networks

CHAPTER-2 IP CONCEPTS

Transcription:

Goal of Today s Lecture EE 122: Designing IP Ion Stoica TAs: Junda Liu, DK Moon, David Zats http://inst.eecs.berkeley.edu/~ee122/ (Materials with thanks to Vern Paxson, Jennifer Rexford, and colleagues at UC Berkeley) Work through process of designing IP, the Internet s (sole) network-layer protocol 1 2 Our Story So Far (Context) The Internet Hourglass The Internet uses packet-switching rather than circuitswitching in order to Achieve higher levels of utilization (we can use statistical multiplexing to more aggressively share network links) Avoid state inside the network (robust fail-over) Make interconnection between different parties easy (minimal service promises) The Internet architecture uses layering to partition functionality into modules The internetworking layer (or just network layer) forms the waist of the layering hourglass 3 SMTP HTTP TCP IP DNS UDP NTP Ethernet SONET 82.11 Copper Fiber Waist Radio Applications Transport Data Link Physical The Hourglass Model There is just one network-layer protocol, IP. The narrow waist facilitates interoperability. Our Story So Far (Context), Con t The End-to-End Principle guides us in where to place functionality If hosts can implement functionality correctly, implement it in a lower layer only as a performance enhancement But do so only if it does not impose burden on applications that do not require that functionality The principle of Fate Sharing guides us to keep state with the elements that rely on it, when possible IP Service: Best-Effort Packet Delivery source Packet switching Divide messages into a sequence of packets Each packet (datagram) is dealt with individually Best-effort delivery Packets may be lost Packets may be corrupted Packets may be delivered out of order IP network destination 1

IP Service Model: Why Best-Effort? IP means never having to say you re sorry Don t need to reserve bandwidth and memory Don t need to do error detection & correction Don t need to remember from one packet to next Easier to survive failures Transient disruptions are okay during failover but, applications do want efficient, accurate transfer of data in order, in a timely fashion IP Service: Best Effort Suffices No error detection or correction Higher-level protocol can provide error checking Successive packets may not follow the same path Not a problem as long as packets reach the destination Packets can be delivered out-of-order Receiver can put packets back in order (if necessary) Packets may be lost or arbitrarily delayed Sender can send the packets again (if desired) No network congestion control (beyond drop ) Sender can slow down in response to loss or delay 7 8 Let s Design IP What does it mean to design a protocol? Answer: specify the syntax of its messages and their meaning (semantics). Syntax = elements in packet header, their types & layout representation Semantics = interpretation of elements information For IP, what fields do we need & why? Information to Capture in IP Addresses: datagram destination & source Framing: datagram length Priority: any special forwarding? Extensibility: what if we need to tweak/change IP? Dealing with problems: Integrity: is the header what it s supposed to be? Loop avoidance: make sure packets don t endlessly circulate Fragmentation: what if the datagram is too large? 9 1 Minute Break Questions Before We Proceed? IP 1-bit Total (Bytes) 1-bit Checksum 11 2

1-bit Total (Bytes) 1-bit Checksum IP Packet Fields number ( bits) Indicates the version of the IP protocol Necessary to know what other fields to expect Typically (for IPv), and sometimes (for IPv) length ( bits) Number of 32-bit words in the header Typically (for a 2-byte IPv header) Can be more when IP options are used Type-of-Service (8 bits) Allow packets to be treated differently based on needs E.g., low delay for audio, high bandwidth for bulk transfer 1 1-bit Total (Bytes) 1-bit Checksum IP Packet Fields (Continued) Total length (1 bits) Number of bytes in the packet Maximum size is,3 bytes (2 1-1) though underlying links may impose smaller limits Fragmentation: when forwarding a packet, an Internet router can split it into multiple pieces ( fragments ) if too big for next hop link Fragmentation information (32 bits) Packet identifier, flags, and fragment offset 1 Where does Reassemble Happen? Where does Reassemble Happen? Host A MTU=B R1 R2 Host B Host A MTU=B R1 R2 Host B MTU (Maximum Transfer Unit) = Maximum packet size handled by network MTU (Maximum Transfer Unit) = Maximum packet size handled by network A1: router R2 A2: end-host B (receiver) 17 18 3

Where does Reassemble Happen? Host A R1 MTU=B R3 R2 Host B 1-bit Total (Bytes) RF/DF/ MF 1-bit Checksum MTU (Maximum Transfer Unit) = Maximum packet size handled by network A2: correct answer Fragments can travel across different paths! 19 Fragmentation (con t) Identifier (1 bits): used to tell which fragments belong together (3 bits): Reserved (RF): unused bit (why reserved?) Don t Fragment (DF): instruct routers to not fragment the packet even if it won t fit Instead, they drop the packet and send back a Too Large ICMP control message Forms the basis for Path MTU Discovery, covered later More (MF): this fragment is not the last one Offset (13 bits): what part of datagram this fragment covers in 8-byte units Thus, a fragment has either MF set or Offset > 21 Example of Fragmentation Suppose we have a, byte datagram sent from host 1.2.3. to host 3... Identification: 273 Source Address: 1.2.3. Total : // Fragment Offset: Destination Address: 3... (398 more bytes here) Checksum: 19 and it traverses a link that limits datagrams to 1, bytes 22 Example of Fragmentation (con t) Datagram split into 3 pieces Example: Example of Fragmentation (con t) Possible first piece: 2 398 Identification: 273 Total : 1 (2 + 18 = 1) //1 Fragment Offset: 2 18 2 12 2 13 Source Address: 1.2.3. Checksum: xxx 1 122 132 Destination Address: 3... 23 2

Example of Fragmentation (con t) Possible second piece: Example of Fragmentation (con t) Possible third piece: Identification: 273 //1 Total : 122 (2 + 12 = 122) Fragment Offset: 18 (18 * 8 = 18) Identification: 273 Total : 132 (2 + 388 28 = 132) // Fragment Offset: 33 (33 * 8 = 28) Checksum: yyy Checksum: zzz Source Address: 1.2.3. Destination Address: 3... Source Address: 1.2.3. Destination Address: 3... 2 2 Some Fragmentation Design Decisions Q: where are fragments reassembled? A: usually at the final destination. Why? Because different fragments can take different paths through the network - the whole collection might only be available at the receiver Q: why use a byte-offset for fragments rather than a numbering each fragment? Ans #1: with a byte offset, the receiver can lay down the bytes in memory when they arrive Ans #2 (more fundamental): allows further fragmentation of fragments 27 1-bit Total (Bytes) 1-bit Checksum Time-to- Field (8 bits) Potentially lethal problem Forwarding loops can cause packets to cycle forever As these accumulate, eventually consume all capacity IP Packet Fields (cont d) (8 bits) Identifies the higher-level protocol E.g., for the Transmission Control (TCP) E.g., 17 for the User Datagram (UDP) Important for demultiplexing at receiving host Indicates what kind of header to expect next Time-to-live field in packet header Decremented at each hop, packet discarded if reaches and time exceeded message is sent to the source Using ICMP control message; basis for traceroute 29 protocol= IP header TCP header protocol=17 IP header UDP header 3

IP Packet Fields (cont d) One s Complement Checksum (1 bits) Complement of the one s-complement sum of all 1-bit words in the IP packet header Each router computes ones-complement sum of entire header including checksum should get (or xffff) If not, router discards packet as corrupted So it doesn t act on bogus information 31 Assume numbers Numbers starting with are positive E.g., 1111 1; Numbers starting with 1 are negative; negative number is obtained by inverting all bits of the positive number E.g., 111-1 and 11111111 both represent Addition: add carry-on to result 1111 (1) + 1111111 (-8) 1 11 + 1 111 (7) 32 Checksum Example 11111 11 111 111 111 11 + 1 1 111 11 + 111 1 1 111 11 +1 111 111 + 11 11 1 11 +1 11 11 data (header) complement checksum 1111 33 1-bit Total (Bytes) 1-bit Checksum IP Packet (cont d) Two IP addresses Source IP address (32 bits) Destination IP address (32 bits) Destination address Unique identifier/locator for the receiving host Allows each node to make forwarding decisions Source address Unique identifier/locator for the sending host Recipient can decide whether to accept packet Enables recipient to send a reply back to source Next Lecture IP Addressing & Forwarding Read K&R:..2 If you want to check out IPv: K&R.. 3 3