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

Similar documents
Internet Design Principles

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

CS4700/CS5700 Fundaments of Computer Networks

Page 1. Key Value Storage" System Examples" Key Values: Examples "

Page 1. Key Value Storage" System Examples" Key Values: Examples "

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

Page 1. Review: The Problem" Software System Modularity" Solution: Intermediate Layers"

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

Probability, Preview, and Principles

CS 268: Lecture 4 (Internet Architecture & E2E Arguments)

Lecture 2: Internet Architecture

Page 1. Goals for Today" Placing Network Functionality" Basic Observation" CS162 Operating Systems and Systems Programming Lecture 15

CS3600 SYSTEMS AND NETWORKS

CS4700/5700: Network fundamentals

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

Network Architecture. EE 122, Fall 2013 Sylvia Ratnasamy

Page 1. Goals for Today" Why is Networking Important?" Example: Whatʼs in a Search Query?"

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

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

Internet Design: Goals and Principles

CSE 123A Computer Networks

Announcements Computer Networking. What is the Objective of the Internet? Today s Lecture

CS 640: Introduction to Computer Networks. Today s Lecture. Page 1

Lecture 3 Protocol Stacks and Layering

Lecture 2: Layering & End-to-End

CE 443: Computer Networks

Introduction to Networks

CSCI Computer Networks

Lecture 2: Links and Signaling

TDTS21 Advanced Networking

Page 1. CS194-3/CS16x Introduction to Systems. Lecture 21. Networking II. Review: Networking Definitions

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

416 Distributed Systems. Networks review; Day 2 of 2 Fate sharing, e2e principle And start of RPC Jan 10, 2018

Data and Computer Communications. Chapter 2 Protocol Architecture, TCP/IP, and Internet-Based Applications

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

Outline. Inter-Process Communication. IPC across machines: Problems. CSCI 4061 Introduction to Operating Systems

Lecture 3: Modulation & Layering"

CS 162 Operating Systems and Systems Programming Professor: Anthony D. Joseph Spring Lecture 21: Network Protocols (and 2 Phase Commit)

Peer entities. Protocol Layering. Protocols. Example

Operating Systems. 16. Networking. Paul Krzyzanowski. Rutgers University. Spring /6/ Paul Krzyzanowski

The Internet. Overview. Network building blocks

CS 3640: Introduction to Networks and Their Applications

Outline: Connecting Many Computers

Patrick Stuedi, Qin Yin, Timothy Roscoe Spring Semester 2015

How does the Internet Look Like?

Lecture 15 Networking Fundamentals. Today s Plan

Design Principles : Fundamentals of Computer Networks Bill Nace

Need For Protocol Architecture

Review of Topology and Access Techniques / Switching Concepts

Computer Networks. Fall 2012 (M 6:15-9:00 in Jbarry 201B) Mirela Damian.

Networking and Internetworking 1

COMS Introduction to Computers. Networking

Design Considerations : Computer Networking. Outline

Network Architecture. TOC Architecture

CMSC 322 Computer Networks Applications and End-To- End

Need For Protocol Architecture

On Inter-layer Assumptions

CSC 4900 Computer Networks: End-to-End Design

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

Applications/Design. Example. Locating Resource. End-to-end. Connection UCB. Applications EECS 122

Networking Overview. CS 161: Computer Security Prof. Vern Paxson. TAs: Jethro Beekman, Mobin Javed, Antonio Lupher, Paul Pearce & Matthias Vallentin

CS61C : Machine Structures

Last Time. Internet in a Day Day 2 of 1. Today: TCP and Apps

Network Architecture COS 461: Computer Networks

Chapter 2 Network Architectures A global view

Network Architecture

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

Part VI. Appendixes. Appendix A OSI Model and Internet Protocols Appendix B About the CD

Distributed Systems /640

CE693: Adv. Computer Networking

Page # Last Time. Lecture 2 Protocol Stacks and Layering. Today s Lecture. Why protocols and layering? What is a Protocol.

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

Networking Applications

EECS 228a Lecture 1 Overview: Networks. Jean Walrand

416 Distributed Systems. Networks review; Day 2 of 2 And start of RPC Jan 13, 2016

CSCI-GA Operating Systems. Networking. Hubertus Franke

The Transmission Control Protocol (TCP)

CSC2209 Computer Networks

CS 268: Computer Networking

Introduction to computer networking

Introduction to Open System Interconnection Reference Model

CS162 Operating Systems and Systems Programming Lecture 21. Networking. Page 1

b) Diverse forms of physical connection - all sorts of wired connections, wireless connections, fiber optics, etc.

CPS221 Lecture: Layered Network Architecture

Introduction to TCP/IP networking

CS 4390 Computer Networks. Transport Services and Protocols

CCNA Exploration1 Chapter 7: OSI Data Link Layer

Internet II. CS10 : Beauty and Joy of Computing. cs10.berkeley.edu. !!Senior Lecturer SOE Dan Garcia!!! Garcia UCB!

Architectural Principles

Introduction to Information Science and Technology 2017 Networking I. Sören Schwertfeger 师泽仁

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

Lecture (02) Network Protocols and Standards

Introduction to Protocols

Computer Network : Lecture Notes Nepal Engineering College Compiled by: Junior Professor: Daya Ram Budhathoki Nepal Engineering college, Changunarayan

CSE 461: Protocols and Layering. This Lecture. 1. A top-down look at the Internet 2. Mechanics of protocols and layering 3. The OSI/Internet models

Links Reading: Chapter 2. Goals of Todayʼs Lecture. Message, Segment, Packet, and Frame

ITEC 3800 Data Communication and Network. Introducing Networks

CS457 Transport Protocols. CS 457 Fall 2014

COS 318: Internetworking

Layered Architecture

Transcription:

Goals for Today" CS162 Operating Systems and Systems Programming Lecture 10 Protocols, Layering and e2e Argument" What is a protocol?! Layering! End-to-end arguments!! October 3, 2011! Anthony D. Joseph and Ion Stoica! http://inst.eecs.berkeley.edu/~cs162! Many slides generated from my lecture notes by Vern Paxson, and Scott Shenker." Lec 10.2! What Is A Protocol?" A protocol is an agreement on how to communicate! Includes! Syntax: how a communication is specified & structured!» Format, order messages are sent and received! Semantics: what a communication means!» Actions taken when transmitting, receiving, or when a timer expires! Examples of Protocols in Human Interactions" Telephone! 1. (Pick up / open up the phone.)! 2. Listen for a dial tone / see that you have service.! 3. Dial.! 4. Should hear ringing! 5. Callee: Hello?! 6. Caller: Hi, it s Alice. Or: Hi, it s me ( what s that about?)! 7. Caller: Hey, do you think blah blah blah pause! 8. Callee: Yeah, blah blah blah pause" 9. Caller: Bye! 10. Callee: Bye! 11. Hang up! Lec 10.3! Lec 10.4! Page 1

Examples of Protocols in Human Interactions" Asking a question! 1. Raise your hand.! 2. Wait to be called on.! 3. Or: wait for speaker to pause and vocalize! The Internet Protocol (IP): Best-Effort Packet Delivery" Datagram packet switching! Send data in packets! Header with source & destination address! Service it provides:! Packets may be lost! Packets may be corrupted! Packets may be delivered out of order! source destination IP network Lec 10.5! Lec 10.6! Example: Transmission Control Protocol (TCP)" Communication service! Ordered, reliable byte stream! Simultaneous transmission in both directions! Key mechanisms at end hosts! Retransmit lost and corrupted packets! Discard duplicate packets and put packets in order! Flow control to avoid overloading the receiver buffer! Congestion control to adapt sending rate to network load! TCP connection Protocol Standardization" Ensure communicating hosts speak the same protocol! Standardization to enable multiple implementations! Or, the same folks have to write all the software! Standardization: Internet Engineering Task Force! Based on working groups that focus on specific issues! Produces Request For Comments (RFCs)!» Promoted to standards via rough consensus and running code! IETF Web site is http://www.ietf.org! RFCs archived at http://www.rfc-editor.org! De facto standards: same folks writing the code! P2P file sharing, Skype, <your protocol here>! source network destination Lec 10.7! Lec 10.8! Page 2

Layering: The Problem" The Problem (cont d)" Many different applications! email, web, P2P, etc.! Skype SSH NFS HTTP Many different network styles and technologies! Circuit-switched vs packet-switched, etc.! Wireless vs. wired vs optical, etc.! How do we organize this mess?! Transmission Media Coaxial cable Fiber optic Radio Re-implement every application for every technology?! No! But how does the Internet design avoid this?! Lec 10.9! Lec 10.10! Solution: Intermediate Layers" Architecture" Introduce intermediate layers that provide set of abstractions for various network functionality & technologies! A new app/media implemented only once! Variation on add another level of indirection! Intermediate layers Skype SSH NFS HTTP Architecture is not the implementation itself! Architecture is how to organize/structure the elements of the system & their implementation! What s are supported!» Using what sort of abstractions! Where functionality is implemented! The modular design of the network! Transmission Media Coaxial cable Fiber optic Packet radio Lec 10.11! Lec 10.12! Page 3

Software System Modularity" Partition system into modules & abstractions:! Well-defined s give flexibility! Hides implementation - thus, it can be freely changed! Extend functionality of system by adding new modules! E.g., libraries encapsulating set of functionality! E.g., programming language + compiler abstracts away not only how the particular CPU works! but also the basic computational model! Well-defined s hide information! Isolate assumptions! Present high-level abstractions! But can impair performance! System Modularity" Like software modularity, but:! Implementation distributed across many machines (routers and hosts)! Must decide:! How to break system into modules!» Layering! What functionality does each module implement!» End-to-End Principle" Where state is stored!» Fate-sharing! We will address these choices in turn! Lec 10.13! Lec 10.14! Layering: A Modular Approach" Properties of Layers (OSI Model)" Partition the system! Each layer solely relies on services from layer below! Each layer solely exports services to layer above! Interface between layers defines interaction! Hides implementation details! Layers can change without disturbing other layers! Service: what a layer does! Service : how to access the service! Interface for layer above! Protocol (peer ): how peers communicate to achieve the service! Set of rules and formats that specify the communication between network elements! Does not specify the implementation on a single machine, but how the layer is implemented between machines! Lec 10.15! Lec 10.16! Page 4

Layer (1)" Service: move information between two systems connected by a physical link! Interface: specifies how to send and receive bits! Protocol: coding scheme used to represent a bit, voltage levels, duration of a bit! Examples: coaxial cable, optical fiber links; transmitters, receivers! " Present." Session" " " " " " (Data) Link Layer (2)" Present." Session" " " " " Service:! Enable end hosts to exchange atomic messages with one another!» Using abstract addresses (i.e., not just direct physical connections)! Perhaps over multiple physical links!» But using the same framing (headers/trailers)! Possible other services:!» arbitrate access to common physical media!» reliable transmission, flow control! Interface: send messages (frames) to other end hosts; receive messages addressed to end host! Protocols: addressing, routing, Media Access Control (MAC) (e.g., CSMA/CD - Carrier Sense Multiple Access / Collision Detection)! Lec 10.17! Lec 10.18! (Inter) Layer (3)" Service:! Deliver packets to specified inter-network destination!» Inter-network = across multiple layer-2 networks" Works across networking technologies (e.g., Ethernet + 802.11 + Frame Relay )!» No longer the same framing all the way! Possible other services:!» packet scheduling/priority!» buffer management! Interface: send packets to specified inter-network destinations; receive packets destined for end host! Protocols: define inter-network addresses (globally unique); construct routing tables! " Present." Session" " " " " Layer (4)" " Present." Session" " " " " Service:! Provide end-to-end communication between processes! Demultiplexing of communication between hosts! Possible other services:!» Reliability in the presence of errors!» Timing properties!» Rate adaption (flow-control, congestion control)! Interface: send message to specific process at given destination; local process receives messages sent to it! Protocol: port numbers, perhaps implement reliability, flow control, packetization of large messages, framing! Examples: TCP and UDP! Lec 10.19! Lec 10.20! Page 5

Layer (7 - not 5!)" Service: any service provided to the end user! Interface: depends on the application! Protocol: depends on the application! " Present." Session" " " " " Examples: Skype, SMTP (email), HTTP (Web), Halo, BitTorrent! 5 Minute Break" What happened to layers 5 & 6?! Session and Presentation layers! Part of OSI architecture, but not Internet architecture!! Questions Before We Proceed?! Lec 10.21! Who Does What?" Logical Communication" Five layers! Lower three layers implemented everywhere! Top two layers implemented only at hosts! Layers interacts with peer s corresponding layer! Host A Router Host B Host A Router Host B Lec 10.23! Lec 10.24! Page 6

Communication" IP Suite: End Hosts vs. Routers" host host Communication goes down to physical network! Then from network peer to peer! HTTP HTTP message HTTP Then up to relevant layer! TCP IP IP packet router IP TCP segment IP packet router IP IP packet TCP IP Host A Router Host B Ethernet Ethernet SONET SONET Ethernet Ethernet Lec 10.25! Lec 10.26! Layer Encapsulation" The Internet Hourglass" User A User B SMTP! HTTP! DNS! NTP! s" Appl: Get index.html TCP! IP! UDP! Waist! " Trans: Connection ID Net: Source/Dest Ethernet! SONET! 802.11! Data Link" " Link: Src/Dest Copper! Fiber! Radio! The Hourglass Model" Common case: 20 bytes TCP header + 20 bytes IP header + 14 bytes Ethernet header = 54 bytes overhead" Lec 10.27! There is just one network-layer protocol, IP.! The narrow waist facilitates interoperability.! Lec 10.28! Page 7

Implications of Hourglass" Single Internet-layer module (IP):! Allows arbitrary networks to interoperate! Any network technology that supports IP can exchange packets! Allows applications to function on all networks! s that can run on IP can use any network! Supports simultaneous innovations above and below IP! But changing IP itself, i.e., IPv6, very involved! Drawbacks of Layering" Layer N may duplicate layer N-1 functionality! E.g., error recovery to retransmit lost data! Layers may need same information! E.g., timestamps, maximum transmission unit size! Layering can hurt performance! E.g., hiding details about what is really going on! Some layers are not always cleanly separated! Inter-layer dependencies for performance reasons! Some dependencies in standards (header checksums)! Headers start to get really big! Sometimes header bytes >> actual content! Lec 10.29! Lec 10.30! Placing Functionality" Basic Observation" Hugely influential paper: End-to-End Arguments in System Design by Saltzer, Reed, and Clark ( 84)! Sacred Text of the Internet! Endless disputes about what it means! Everyone cites it as supporting their position! Some types of network functionality can only be correctly implemented end-to-end! Reliability, security, etc! Because of this, end hosts:! Can satisfy the requirement without network s help! Will/must do so, since can t rely on network s help! Therefore don t go out of your way to implement them in the network! Lec 10.31! Lec 10.32! Page 8

Example: Reliable File Transfer" Discussion" Host A Appl. Host B Appl. Solution 1 is incomplete! What happens if memory is corrupted?! Receiver has to do the check anyway!! OS OK OS Solution 1: make each step reliable, and then concatenate them! Solution 2: end-to-end check and try again if necessary! Solution 2 is complete! Full functionality can be entirely implemented at application layer with no need for reliability from lower layers! Is there any need to implement reliability at lower layers?! Well, it could be more efficient! Lec 10.33! Lec 10.34! Summary of End-to-End Principle" Conservative Interpretation of E2E" Implementing this functionality in the network:! Doesn t reduce host implementation complexity! Does increase network complexity! Probably imposes delay and overhead on all applications, even if they don t need functionality! However, implementing in network can enhance performance in some cases! E.g., very losy link! Don t implement a function at the lower levels of the system unless it can be completely implemented at this level! Unless you can relieve the burden from hosts, don t bother! Lec 10.35! Lec 10.36! Page 9

Moderate Interpretation" Think twice before implementing functionality in the network! 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! Related Notion of Fate-Sharing! Idea: when storing state in a distributed system, keep it co-located with the entities that ultimately rely on the state! Fate-sharing is a technique for dealing with failure! Only way that failure can cause loss of the critical state is if the entity that cares about it also fails...! in which case it doesn t matter! Often argues for keeping network state at end hosts rather than inside routers! In keeping with End-to-End principle! E.g., packet-switching rather than circuit-switching! E.g., NFS file handles, HTTP cookies! Lec 10.37! Lec 10.38! Summary" Roles of! Standardization! Clients, servers, peer-to-peer! Layered architecture as a powerful means for organizing complex networks! Though layering has its drawbacks too! Unified Internet layering (// Internetwork/Link/) decouples apps from networking technologies! E2E argument encourages us to keep IP simple! Commercial realities (need to control the network) can greatly stress this! Lec 10.39! Page 10