1 Fall 2005 Protocols and layering Qutaibah Malluhi Computer Science and Engineering Qatar University.

Slides:



Advertisements
Similar presentations
OSI Model OSI MODEL.
Advertisements

Answers of Exercise 7 1. Explain what are the connection-oriented communication and the connectionless communication. Give some examples for each of the.
TCP/IP1 The Underlying Technologies. What is inside the Internet? Or What are the key underlying technologies that make it work so successfully? –Packet.
Networking Theory (Part 1). Introduction Overview of the basic concepts of networking Also discusses essential topics of networking theory.
EE 122: Error detection and reliable transmission Ion Stoica September 16, 2002.
Internet Technologies Overview
CSCI 4550/8556 Computer Networks
CS335 Networking & Network Administration Tuesday, April 20, 2010.
TCP: Software for Reliable Communication. Spring 2002Computer Networks Applications Internet: a Collection of Disparate Networks Different goals: Speed,
Networking. Protocol Stack Generally speaking, sending an message is equivalent to copying a file from sender to receiver.
Chapter 2 Network Models.
Error Checking continued. Network Layers in Action Each layer in the OSI Model will add header information that pertains to that specific protocol. On.
Gursharan Singh Tatla Transport Layer 16-May
OIS Model TCP/IP Model.
SEPT, 2005CSI Part 2.2 Protocols and Protocol Layering Robert Probert, SITE, University of Ottawa.
CECS 474 Computer Network Interoperability Notes for Douglas E. Comer, Computer Networks and Internets (5 th Edition) Tracy Bradley Maples, Ph.D. Computer.
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.
Process-to-Process Delivery:
1 Transport Layer Computer Networks. 2 Where are we?
ISO Layer Model Lecture 9 October 16, The Need for Protocols Multiple hardware platforms need to have the ability to communicate. Writing communications.
Presentation on Osi & TCP/IP MODEL
Protocol Layering Chapter 10. Looked at: Architectural foundations of internetworking Architectural foundations of internetworking Forwarding of datagrams.
Network Property and ISO Reference Model Network Ownership: Private and Public Connectionless Network and Connect-Oriented Network Network Performance.
Go-Back-N ARQ  packets transmitted continuously (when available) without waiting for ACK, up to N outstanding, unACK’ed packets  a logically different.
1 Chapter 16 Protocols and Protocol Layering. 2 Protocol  Agreement about communication  Specifies  Format of messages (syntax)  Meaning of messages.
COMPUTER NETWORKS Ms. Mrinmoyee Mukherjee Assistant Professor
The OSI Model.
FALL 2005CSI 4118 – UNIVERSITY OF OTTAWA1 Part 2.5 Internetworking Chapter 25 (Transport Protocols, UDP and TCP, Protocol Port Numbers)
TCP1 Transmission Control Protocol (TCP). TCP2 Outline Transmission Control Protocol.
The Transmission Control Protocol (TCP) Application Services (Telnet, FTP, , WWW) Reliable Stream Transport (TCP) Connectionless Packet Delivery.
COP 4930 Computer Network Projects Summer C 2004 Prof. Roy B. Levow Lecture 3.
Internetworking Internet: A network among networks, or a network of networks Allows accommodation of multiple network technologies Universal Service Routers.
Networks. Common Xmit Media Shared Media Networks are a shared communication resource Only one user can access at a time.
Chapter 12(13) - WAN Technologies and Routing Route computation with a graph Redundant routing information Default routes Building routing tables Computation.
CENG 490/510 Network Programming Russell Deaton Rm
Chapter 24 Transport Control Protocol (TCP) Layer 4 protocol Responsible for reliable end-to-end transmission Provides illusion of reliable network to.
Prepared by Engr.Jawad Ali BSc(Hons)Computer Systems Engineering University of Engineering and Technology Peshawar.
Chapter 16 Protocols and Layering. Network Communication Protocol an agreement that specifies the format and meaning of messages computers exchange Network.
Protocol Layering Chapter 11.
Transport Layer: Sliding Window Reliability
1 Protocols and Protocol Layering. 2 Protocol Agreement about communication Specifies –Format of messages –Meaning of messages –Rules for exchange –Procedures.
1 Direct Link Networks: Reliable Transmission Sections 2.5.
McGraw-Hill Chapter 23 Process-to-Process Delivery: UDP, TCP Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
CSE331: Introduction to Networks and Security Lecture 4 Fall 2002.
TCP/IP1 Address Resolution Protocol Internet uses IP address to recognize a computer. But IP address needs to be translated to physical address (NIC).
TCP/IP Protocol Suite Suresh Kr Sharma 1 The OSI Model and the TCP/IP Protocol Suite Established in 1947, the International Standards Organization (ISO)
Week #8 OBJECTIVES Chapter #5. CHAPTER 5 Making Networks Work Two Networking Models –OSI OPEN SYSTEMS INTERCONNECTION PROPOSED BY ISO –INTERNATIONAL STANDARDS.
Computer Networking Lecture 16 – Reliable Transport.
Computer Engineering and Networks, College of Engineering, Majmaah University Protocols OSI reference MODEL TCp /ip model Mohammed Saleem Bhat
Data Link Control. The two main functions of the data link layer are data link control and media access control. The first, data link control, deals with.
Protocols and layering Network protocols and software Layered protocol suites The OSI 7 layer model Common network design issues and solutions.
1 Chapter 24 Internetworking Part 4 (Transport Protocols, UDP and TCP, Protocol Port Numbers)
OSI Model OSI MODEL. Communication Architecture Strategy for connecting host computers and other communicating equipment. Defines necessary elements for.
OSI Model OSI MODEL.
Go-Back-N ARQ packets transmitted continuously (when available) without waiting for ACK, up to N outstanding, unACK’ed packets a logically different sender.
Reliable Transmission
Chapter 9: Data Link Control
Ch 16 Protocols and Layering
(Ownership, Service Paradigm, Measures of Performance)
Understand the OSI Model Part 2
Protocols and Layering
Introduction of Transport Protocols
Chapter 3: Open Systems Interconnection (OSI) Model
Process-to-Process Delivery:
OSI Model OSI MODEL.
Protocols and Protocol Layering
Process-to-Process Delivery: UDP, TCP
Protocols and Protocol Layering
Chapter 9: Data Link Control
Error Checking continued
Presentation transcript:

1 Fall 2005 Protocols and layering Qutaibah Malluhi Computer Science and Engineering Qatar University

2 Introduction  LAN/WAN hardware can not solve all computer communication problems –Sending data through raw hardware is awkward and inconvenient »Equivalent to accessing files by making calls to disk controller to position read/write head and accessing individual sectors »Network software provides high-level interface to applications  Software is needed –What problems should software handle? –Complex  Layering is a structuring technique –Separate hardware and software functions –Organize networking software design and implementation –Manage complexity

3 Network Protocols  Agreement on set of rules to be used for communication  Specifies –Format of messages –Meaning of messages –Rules for exchange –Procedures for handling problems  Protocols are implemented by protocol software

4 Need for Protocols  Hardware is low level. Software needed to handle a number of problems.  Many problems can occur –Bits corrupted or destroyed –Entire packet lost –Packet duplicated –Packets delivered out of order  Need mechanisms to distinguish among –Multiple computers on a network –Multiple applications on a computer –Multiple copies of a single application on a computer

5 Protocol Suites  A set of related protocols that are designed for compatibility is called a protocol suite  Protocol suite designers: –Analyze communication problem –Divide problems into subproblems –Design a protocol for each subproblem  A well-designed protocol suite –Is efficient and effective - solves the problem without redundancy and makes best use of network capacity –Allows replacement of individual protocols without changes to other protocols

6 Protocol Layering  A way of managing the complexity  Model suggests dividing the network protocol into layers, each of which solves part of the network communication problem  Network protocol suite designed to have a protocol or protocols for each layer

7 The ISO 7-Layer Reference Model  International Organization for Standards (ISO) defined a 7-layer reference model as a guide to the design of a network protocol suite  Layers are named and numbered –reference to ``layer n'' often means the nth layer of the ISO 7-layer reference model  Many modern protocols do not exactly fit the ISO model, and the ISO protocol suite is mostly of historic interest  Reference model: used provides a common terminology among different protocol stacks.  Concepts are still largely useful and terminology persists

8 The Seven Layers  Layer 7: Application –Application-specific protocols such as HTTP, FTP and SMTP (electronic mail)  Layer 6: Presentation –Common formats for representation of data  Layer 5: Session –Management of sessions such as login to a remote computer and authentication  Layer 4: Transport –Reliable delivery of data between computers  Layer 3: Network –Address assignment, routing and data delivery across a physical network  Layer 2: Data Link –Format of data in frames and delivery of frames through network interface  Layer 1: Physical –Basic network hardware - such as RS-232 or Ethernet. –Includes media, hardware interfaces, bit encoding, etc.

9 Stacks: Software Layers  Software stack: Software implementation of layered design  Software modules can be viewed as:

10 Commercial Protocol Stack Examples  Although the stacks share many general concepts, the details differ, making them incompatible

11 Layering Principle  The software for each layer depends only on the services provided by lower layers  The software at layer n at the destination receives exactly the same protocol message sent by layer n at the sender  Each layer can be designed, implemented and tested independent of other layers  Change of implementation of any layer’s should be transparent to rest of system.

12 Multiple Nested Headers  The software at each layer at the sender communicates with the corresponding layer at the receiver through information stored in headers (a trailer may also be added)

13 Stacks and Messages (1)  On the sender, each layer: –Accepts an outgoing message from the layer above –Adds a header and other processing –Passes resulting message to next lower layer  On the receiver, each layer: –Receives an incoming message from the layer below –Removes the header for that layer and performs other processing –Passes the resulting message to the next higher layer

14 Stacks and Messages (2)

15 Control Messages  Protocol layers often need to communicate directly without exchanging data –Acknowledge incoming data –Request next data packet  Layers use control packets –Generated by layer n on sender –Interpreted by layer n on receiver –Transmitted like any other packet by layers n-1 and below

16 General Protocol Techniques  Reliable communication –Protocol techniques: parity bit, checksum and CRC  Out-of –order delivery –Packet sequence numbers  Duplicate packets –Packet sequence numbers (duplicate seq. numbers)  Lost packets –Positive acknowledgement with retransmission (see later)  Replay (caused by excessive delay) –Unique session ID (see later)  Data Overrun –Flow control mechanisms (see later).

17 Acknowledgement & Retransmission  Error causes receiver to discard packet  How does the sender decide that a packet has been lost?  Protocols use positive acknowledgment with retransmission –Receiver sends short message acknowledging receipt of packets –Sender infers lost packets from missing acknowledgments –Sender retransmits lost packets  Sender sets timer for each outgoing packet –Saves copy of packet –If timer expires before acknowledgment is received, sender can retransmit saved copy  Protocols define upper bound on number of retransmissions to detect unrecoverable network failure  Lost acknowledgement causes duplicate packets

18 What Can Go Wrong...

19 Replay  Sufficiently delayed packets may affect later sessions  Suppose two computers exchange data with packets numbered 1 to 5  Packet 4 encounters an extraordinary delay; computers use retransmission to deliver valid copy of packet 4  Two computers exchange data later on with packets numbered 1 to 10  Initial `packet 4' can arrive during second session, so that the data from that old packet (rather than the current `packet 4' is inserted into the data  Protocols attach session number to each packet in a protocol session to differentiate packets from different sessions

20 Flow Control  Data overrun can occur when sender transmits data faster than receiver can process incoming data  Protocols use flow control mechanisms (related to buffering) –Stop-and-go –Fixed-size sliding window –Variable-size sliding window (credit-based flow control)

21 Stop-And-Go Flow Control  Sending side –Transmits one packet –Waits for signal from receiver  Receiving side –Receives and consumes packet –Transmits signal to sender  Inefficient

22 Stop-And-Go is Inefficient  Example: consider 2 Mbps link and a network latency of 50 ms (i.e., round trip time (RTT) = 100 ms), then a 1 KB packet takes about 100 ms. Or maximum rate is 80 Kbps. Use 4% of the available capacity. (i.e., rest of the time link stays idle waiting for the ACK) Frame 0 Ack 0 Frame 1 Ack 1 cycle Sender Receiver

23 Sliding Window Flow Control  Allows sender to transmit multiple packets before receiving an acknowledgment  Number of packets that can be sent before an acknowledgement is received is defined by the protocol and called the window  As acknowledgments arrive from the receiver, the window is moved along the data packets; hence ``sliding window''  Sender maintains window. Window size is the number of frames that can be in flight (sent but not acknowledged)

24 Sliding Window On Sending Side  Window tells how many packets can be sent without acknowledgement –Window size = 5 in the example  Window moves as acknowledgements arrive Window Window Acknowledged Unsent Window

25 Comparison of Flow Control SenderReceiver frame Ack. frame Ack. frame Ack. frame Ack. SenderReceiver 4 frames Acknowledgements Stop-and-goSliding Window

26 Transmission Times  For stop-and-go, each packet takes 2L time to deliver (where L is the latency, or network delivery time)  Sliding window can improve by number of packets in window: R w = R g * W (R w is sliding window throughput, R g is stop-and-go throughput  Transmission time also limited by network transmission rate: R w = min(B, R g * W) (B is maximum network bandwidth)

27 Congestion  Fundamental problem in networks  Caused by traffic, not hardware failure  Analogous to congestion on a highway  Principle cause of delay Multiple sources Bottleneck

28 Avoiding and Recovering from Congestion  Protocols attempt to avoid congestion and recover from network collapse by monitoring the state of the network and taking appropriate action  Can use two techniques: –Notification from packet switches –Infer congestion from packet loss  Packet loss can be used to detect congestion because modern networks are reliable and rarely lose packets through hardware failure  Sender can infer congestion from packet loss through missing acknowledgments

29 Congestion Control  Dynamically adjust the window size 1.Rate or percentage of lost packets can be used to gauge degree of congestion »Sliding window can be used for congestion control u Gauge the window size: decrease on high-loss and increase on no loss 2.Receiver may tell sender if it is congested on window size to use »Credit-based flow control u Receiver issues credit (window size to use) to sender

30 Summary  Layering is a technique for guiding protocol design and implementation  Protocols are grouped together into related protocol suites – sometimes called a protocol stack  Protocols use a variety of techniques for solving the reliable data delivery problems –Reliable communication –Out-of –order delivery –Duplicate packets –Lost packets and congestion –Replay –Data Overrun