NETWORK PROGRAMMING FALL 2015 Lecture 2 - Protocol Stacks Some material taken from publicly available lecture slides including Srini Seshan’s and David.

Slides:



Advertisements
Similar presentations
Layering and the network layer CS168, Fall 2014 Sylvia Ratnasamy
Advertisements

15-744: Computer Networking L-2 Design Considerations.
COS 461 Fall 1997 Networks and Protocols u networks and protocols –definitions –motivation –history u protocol hierarchy –reasons for layering –quick tour.
1 CS 640: Introduction to Computer Networks Aditya Akella Lecture 2 Layering, Protocol Stacks, and Standards.
Data and Computer Communications Eighth Edition by William Stallings Lecture slides by Lawrie Brown Chapter 2 – Protocol Architecture, TCP/IP, and Internet-Based.
L-2 Internet Design Philosophy 1. 2 Today’s Lecture Layers and protocols Design principles in internetworks.
Data and Computer Communications Eighth Edition by William Stallings Lecture slides by Lawrie Brown Chapter 2 – Protocol Architecture, TCP/IP, and Internet-Based.
PROTOCOLS AND ARCHITECTURE Lesson 2 NETS2150/2850.
CSE 486/586, Spring 2012 CSE 486/586 Distributed Systems The Internet in 2 Hours: The First Hour Steve Ko Computer Sciences and Engineering University.
CS 268: Lecture 2 (Layering & End-to-End Arguments)
Semester Copyright USM EEE442 Computer Networks Introduction: Protocols En. Mohd Nazri Mahmud MPhil (Cambridge, UK) BEng (Essex, UK)
Protocols and the TCP/IP Suite
EE 122: Layering and the Internet Architecture Kevin Lai September 4, 2002.
EE 4272Spring, 2003 Protocols & Architecture A Protocol Architecture is the layered structure of hardware & software that supports the exchange of data.
Computer Networking Lecture 2 - Protocol Stacks.
Data Communications Architecture Models. What is a Protocol? For two entities to communicate successfully, they must “speak the same language”. What is.
William Stallings Data and Computer Communications 7 th Edition Chapter 2 Protocols and Architecture.
1 Computer Networks Transport Layer Protocols. 2 Application-layer Protocols Application-layer protocols –one “piece” of an app –define messages exchanged.
COE 342: Data & Computer Communications (T042) Dr. Marwan Abu-Amara Chapter 2: Protocols and Architecture.
 The Open Systems Interconnection model (OSI model) is a product of the Open Systems Interconnection effort at the International Organization for Standardization.
CS 268: Lecture 3 (TCP/IP Architecture) Ion Stoica January 28, 2003.
Lecture slides prepared for “Business Data Communications”, 7/e, by William Stallings and Tom Case, Chapter 8 “TCP/IP”.
* EECS 582 Advanced Operating Systems James Priestley University of Michigan Day 4: Internetworking January 12, 2012 Credit for the majority of these slides.
Protocols and the TCP/IP Suite Chapter 4. Multilayer communication. A series of layers, each built upon the one below it. The purpose of each layer is.
Chapter 17 Networking Dave Bremer Otago Polytechnic, N.Z. ©2008, Prentice Hall Operating Systems: Internals and Design Principles, 6/E William Stallings.
Data and Computer Communications Eighth Edition by William Stallings Lecture slides by Lawrie Brown Chapter 2 – Protocol Architecture, TCP/IP, and Internet-Based.
Feb 20, 2001CSCI {4,6}900: Ubiquitous Computing1 Announcements.
EPL606 Topic 1 Introduction Part B - Design Considerations 1 The majority of the slides in this course are adapted from the accompanying slides to the.
CS 268: Lecture 3 (Layering & End-to-End Arguments)
Review: – computer networks – topology: pair-wise connection, point-to-point networks and broadcast networks – switching techniques packet switching and.
Chapter 1 Overview Review Overview of demonstration network
Presentation on Osi & TCP/IP MODEL
What is a Protocol A set of definitions and rules defining the method by which data is transferred between two or more entities or systems. The key elements.
Protocol Layering Chapter 10. Looked at: Architectural foundations of internetworking Architectural foundations of internetworking Forwarding of datagrams.
Protocols and the TCP/IP Suite
1 CS 640: Introduction to Computer Networks Aditya Akella Lecture 2 Layering, Protocol Stacks, and Standards.
William Stallings Data and Computer Communications 7 th Edition Data Communications and Networks Overview Protocols and Architecture.
1 Chapter 1 OSI Architecture The OSI 7-layer Model OSI – Open Systems Interconnection.
TCP/IP Essentials A Lab-Based Approach Shivendra Panwar, Shiwen Mao Jeong-dong Ryoo, and Yihan Li Chapter 5 UDP and Its Applications.
Lect1..ppt - 01/06/05 CDA 6505 Network Architecture and Client/Server Computing Lecture 2 Protocols and the TCP/IP Suite by Zornitza Genova Prodanoff.
Mukesh N. Tekwani Elphinstone College Mumbai
Department of Electronic Engineering City University of Hong Kong EE3900 Computer Networks Introduction Slide 1 A Communications Model Source: generates.
Introduction to Networks CS587x Lecture 1 Department of Computer Science Iowa State University.
Data and Computer Communications Chapter 2 – Protocol Architecture, TCP/IP, and Internet-Based Applications.
Advance Computer Networking L-2 Design Considerations Acknowledgments: Lecture slides are from the graduate level Computer Networks course thought by Srinivasan.
Computer Networking. 2 Outline 3 Objectives Understand the state-of-the-art in network protocols, architectures and applications Understand how networking.
TCOM 509 – Internet Protocols (TCP/IP) Lecture 03_b Protocol Layering Instructor: Dr. Li-Chuan Chen Date: 09/15/2003 Based in part upon slides of Prof.
Internet Protocol ECS 152B Ref: slides by J. Kurose and K. Ross.
CS 268: Computer Networking L-2 Design Considerations.
Computer Security Workshops Networking 101. Reasons To Know Networking In Regard to Computer Security To understand the flow of information on the Internet.
Chapter 2 Protocols and the TCP/IP Suite 1 Chapter 2 Protocols and the TCP/IP Suite.
William Stallings Data and Computer Communications
CS 4396 Computer Networks Lab
CHAPTER 4 PROTOCOLS AND THE TCP/IP SUITE Acknowledgement: The Slides Were Provided By Cory Beard, William Stallings For Their Textbook “Wireless Communication.
1 Chapter 4. Protocols and the TCP/IP Suite Wen-Shyang Hwang KUAS EE.
1 Protocol Layering Myungchul Kim Tel:
Protocol Layering Chapter 11.
CSci5221: Internet Design 1 Internet Design: Big Picture Internet architectural, design and implementation principles –not “ scriptures ”, but guidelines.
Data and Computer Communications Chapter 2 – Protocol Architecture, TCP/IP, and Internet-Based Applications.
What is a Protocol A set of definitions and rules defining the method by which data is transferred between two or more entities or systems. The key elements.
Distributed Systems (Section B)
Protocols and the TCP/IP Suite
IP - The Internet Protocol
Advance Computer Networking
1 TRANSMISSION CONTROL PROTOCOL / INTERNET PROTOCOL (TCP/IP) K. PALANIVEL Systems Analyst, Computer Centre Pondicherry University, Puducherry –
IP - The Internet Protocol
Protocols and the TCP/IP Suite
IP - The Internet Protocol
Presentation transcript:

NETWORK PROGRAMMING FALL 2015 Lecture 2 - Protocol Stacks Some material taken from publicly available lecture slides including Srini Seshan’s and David Anderson’s

Last Lecture (3 min summary) 2  What is a distributed system?  What does it do for you (application developers/users)?

What is a Distributed System?  A distributed system is: “A collection of independent computers that appears to its users as a single coherent system” "A distributed system is one in which the failure of a c omputer you didn't even know existed can render your own computer unusable." – Leslie Lamport 3

Distributed Systems  The middleware layer extends over multiple machine s, and offers each application the same interface. 4

5 What does it do? Hides complexity to programmers/users Hides the fact that its processes and resources are physically distributed across multiple machines.

Today’s Lecture 6  Layers and protocols  Design principles in internetworks

What is Layering? 7  Modular approach to network functionality  Example: Link hardware Host-to-host connectivity Application-to-application channels Application

What is Layering? 8 Host Application Transport Network Link User AUser B Modular approach to network functionality Peer Layer

Layering Characteristics 9  Each layer relies on services from layer below and exports services to layer above  Interface defines interaction with peer on other hosts  Hides implementation - layers can change without disturbing other layers (black box)

What are Protocols?  An agreement between parties on how communication should take place  Module in layered structure  Protocols define:  Interface to higher layers (API)  Interface to peer (syntax & semantics) Actions taken on receipt of a messages Format and order of messages Error handling, termination, ordering of requests, etc.  Example: Buying airline ticket 10 Friendly greeting Want an airline ticket Destination? Seoul Credit card..

The Internet Engineering Task Force 11  Standardization is key to network interoperability  The hardware/software of communicating parties are often not built by the same vendor  yet they can communicate because they use the same protocol  Internet Engineering Task Force  Based on working groups that focus on specific issues  Request for Comments  Document that provides information or defines standard  Requests feedback from the community  Can be “promoted” to standard under certain conditions consensus in the committee interoperating implementations

OSI Model: 7 Protocol Layers 12  Physical: how to transmit bits  Data link: how to transmit frames  Network: how to route packets  Transport: how to send packets end2end  Session: how to tie flows together  Presentation: byte ordering, security  Application: everything else  TCP/IP has been amazingly successful, and it’s not based on a rigid OSI model. The OSI model has been very successful at shaping thought

OSI Layers and Locations 13 Bridge/Switch Router/Gateway Host Application Transport Network Data Link Presentation Session Physical

IP Layering 14  Relatively simple Bridge/Switch Router/Gateway Host Application Transport Network Link Physical

The Internet Protocol Suite 15 UDPTCP Data Link Physical Applications The Hourglass Model Waist The waist facilitates interoperability FTPHTTPTFTPNV TCPUDP IP NET 1 NET 2 NET n …

Layer Encapsulation 16 Get index.html Connection ID Source/Destination Link Address User AUser B

Multiplexing and Demultiplexing  There may be multiple implementations of each layer.  How does the receiver know what version of a layer to use?  Each header includes a demultiplexing field that is used to identify the next layer.  Filled in by the sender  Used by the receiver  Multiplexing occurs at multiple layers. E.g., IP, TCP, … 17 IP TCP IP TCP V/HL TOS Length ID Flags/Offset TTL Prot. H. Checksum Source IP address Destination IP address Options..

Protocol Demultiplexing 18  Multiple choices at each layer FTPHTTPTFTPNV TCPUDP IP NET 1 NET 2 NET n … TCP/UDPIP IPX Port Number Network Protocol Field Type Field

Is Layering Harmful? 19  Layer N may duplicate lower level functionality (e.g., error recovery)  Layers may need same info (timestamp, MTU)  Strict adherence to layering may hurt performance  Some layers are not always cleanly separated.  Inter-layer dependencies in implementations for performance reasons  Some dependencies in the standards (header checksums)  Interfaces are not really standardized.  It would be hard to mix and match layers from independent implementations, e.g., windows network apps on unix (w/out compatibility library)  Many cross-layer assumptions, e.g. buffer management

Today’s Lecture 20  Layers and protocols  Design principles in internetworks

Goals [Clark88] 21 0 Connect existing networks initially ARPANET and ARPA packet radio network 1. Survivability ensure communication service even in the presence of network and router failures 2. Support multiple types of services 3. Must accommodate a variety of networks 4. Allow distributed management 5. Allow host attachment with a low level of effort 6. Be cost effective 7. Allow resource accountability

Priorities 22  The effects of the order of items in that list are still felt today  E.g., resource accounting is a hard, current research topic  Let’s look at them in detail

Goal 0: Connecting Networks 23  How to internetwork various network technologies  ARPANET, X.25 networks, LANs, satellite networks, packet networks, serial links…  Many differences between networks  Address formats  Performance – bandwidth/latency  Packet size  Loss rate/pattern/handling  Routing

Challenge 1: Address Formats 24  Map one address format to another?  Bad idea  many translations needed  Provide one common format  Map lower level addresses to common format

Challenge 2: Different Packet Sizes 25  Define a maximum packet size over all networks?  Either inefficient or high threshold to support  Implement fragmentation/re-assembly  Who is doing fragmentation?  Who is doing re-assembly?

Gateway Alternatives 26  Translation  Difficulty in dealing with different features supported by networks  Scales poorly with number of network types (N^2 conversions)  Standardization  “IP over everything” (Design Principle 1)  Minimal assumptions about network  Hourglass design

IP Standardization 27  Minimum set of assumptions for underlying net  Minimum packet size  Reasonable delivery odds, but not 100%  Some form of addressing unless point to point  Important non-assumptions:  Perfect reliability  Broadcast, multicast  Priority handling of traffic  Internal knowledge of delays, speeds, failures, etc  Also achieves Goal 3: Supporting Varieties of Networks

IP Hourglass 28  Need to interconnect many existing networks  Hide underlying technology from applications  Decisions:  Network provides minimal functionality  “Narrow waist” Tradeoff: No assumptions, no guarantees. Technology Applications WWW phone... SMTP HTTP RTP... TCP UDP… IP ethernet PPP… CSMA async sonet... copper fiber radio...

IP Layering (Principle 2) 29 Router Host Application Transport Network Link

Goal 1: Survivability 30  If network is disrupted and reconfigured…  Communicating entities should not care!  No higher-level state reconfiguration  How to achieve such reliability?  Where can communication state be stored? NetworkHost Failure handingReplication“Fate sharing” Net EngineeringToughSimple SwitchesMaintain stateStateless Host trustLessMore

Principle 3: Fate Sharing 31  Lose state information for an entity if and only if the entity itself is lost.  Examples:  OK to lose TCP state if one endpoint crashes NOT okay to lose if an intermediate router reboots  Is this still true in today’s network? NATs and firewalls  Tradeoffs  Survivability: Heterogeneous network  less information available to end hosts and Internet level recovery mechanisms  Trust: must trust endpoints more Connection State State No State

Principle 4: Soft-state 32  Soft-state (as oppose to hard-state)  Announce state  Refresh state  Timeout state  Penalty for timeout – poor performance  Robust way to identify communication flows (firewall)  Possible mechanism to provide non-best effort service  Helps survivability

Principle 5: End-to-End Argument 33  Deals with where to place functionality  Inside the network (in switching elements)  At the edges  Argument  There are functions that can only be correctly implemented by the endpoints – do not try to completely implement these elsewhere  Guideline not a law

Example: Reliable File Transfer 34  Solution 1: make each step reliable, and then concatenate them  Solution 2: end-to-end check and retry OS Appl. OS Appl. Host AHost B OK

E2E Example: File Transfer 35  Even if network guaranteed reliable delivery  Need to provide end-to-end checks  E.g., network card may malfunction  The receiver has to do the check anyway!  Full functionality can only be entirely implemented at application layer; no need for reliability from lower layers  Does FTP look like E2E file transfer?  TCP provides reliability between kernels not disks  Is there any need to implement reliability at lower layers?

Discussion 36  Yes, but only to improve performance  If network is highly unreliable  Adding some level of reliability helps performance, not correctness  Don’t try to achieve perfect reliability!  Implementing a functionality at a lower level should have minimum performance impact on the applications that do not use the functionality

Examples 37  What should be done at the end points, and what by the network?  Reliable/sequenced delivery?  Addressing/routing?  Security?  What about Ethernet collision detection?  Multicast?  Real-time guarantees?

Goal 2: Types of Service 38  Principle 6: network layer provides one simple service: best effort datagram (packet) delivery  All packets are treated the same  Relatively simple core network elements  Building block from which other services (such as reliable data stream) can be built  Contributes to scalability of network  Issues: No QoS support assumed from below  In fact, some underlying nets only supported reliable delivery Made Internet datagram service less useful!  Hard to implement without network support  QoS is an ongoing debate…

Types of Service 39  TCP vs. UDP  Elastic apps that need reliability: remote login or  Inelastic, loss-tolerant apps: real-time voice or video  Others in between, or with stronger requirements  Biggest cause of delay variation: reliable delivery Today’s net: ~100ms RTT Reliable delivery can add seconds.

Goal 4: Decentralization 40  Principle 7: Each network owned and managed separately  Will see this in BGP routing especially

The “Other” goals Attaching a host  Host must implement hard part   transport services Not too bad 6. Cost effectiveness  Packet overhead less important by the year  Packet loss rates low  Economies of scale won out  Internet cheaper than most dedicated networks  But…

7. Accountability 42  Huge problem  Accounting  Billing? (mostly flat-rate. But phones have become that way also - people like it!)  Inter-ISP payments Complicated. Political. Hard.  Accountability and security  Huge problem.  Worms, viruses, etc. Partly a host problem. But hosts very trusted.  Authentication Purely optional. Many philosophical issues of privacy vs. security.  Greedy sources aren’t handled well

Other IP Design Weaknesses 43  Weak administration and management tools  Incremental deployment difficult at times  Result of no centralized control  No more “flag” days

Changes Over Time  New Principles? 44  Developed in simpler times  Common goals, consistent vision  With success came multiple goals – examples:  ISPs must talk to provide connectivity but are fierce competitors  Privacy of users vs. government’s need to monitor  User’s desire to exchange files vs. copyright owners  Must deal with the tussle between concerns in design  Provide choice  allow all parties to make choices on interactions  Creates competition  Fear between providers helps shape the tussle

New Principles? 45  Design for variation in outcome  Allow design to be flexible to different uses/results  Isolate tussles  QoS designs uses separate ToS bits instead of overloading other parts of packet like port number  Separate QoS decisions from application/protocol design  Provide choice  allow all parties to make choices on interactions  Creates competition  Fear between providers helps shape the tussle

Summary: Internet Architecture 46  Packet-switched datagram network  IP is the “compatibility layer”  Hourglass architecture  All hosts and routers run IP  Stateless architecture  no per flow state inside network IP TCPUDP ATM Satellite Ethernet

Summary: Minimalist Approach 47  Dumb network  IP provide minimal functionalities to support connectivity Addressing, forwarding, routing  Smart end system  Transport layer or application performs more sophisticated f unctionalities Flow control, error control, congestion control  Advantages  Accommodate heterogeneous technologies (Ethernet, modem, satellite, wireless)  Support diverse applications (telnet, ftp, Web, X windows)  Decentralized network administration

Summary  Successes: IP on everything!  Drawbacks… but perhaps they’re totally worth it in the context of the original Internet. Might not have worked without them! “This set of goals might seem to be nothing more than a checklist of all the desirable network features. It is important to understand that these goals are in order of importance, and an entirely different network architecture would result if the order were changed.” 48