CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 13 Introduction to Computer Networks.

Slides:



Advertisements
Similar presentations
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 14 Introduction to Computer Networks.
Advertisements

Chapter 3 The Data Link Layer.
Data Link Layer Protocols Flow Control in Data Link Layer.
The Data Link Layer Chapter 3. Data Link Layer Design Issues Services Provided to the Network Layer Framing Error Control Flow Control.
Network Operations & administration CS 4592 Lecture 15 Instructor: Ibrahim Tariq.
EE 4272Spring, 2003 Chapter 7 Data Link Control Objectives: Effective & reliable data communication between two directly connected transmitting-receiving.
EIE325: Telecommunication TechnologiesMaciej J. Ogorza ł ek, PolyU, EIE Telecommunication Technologies Week 8 Flow Control Error Control.
William Stallings Data and Computer Communications 7th Edition
Chapter 3: The Datalink Layer CS 455/555. Topics to be covered Design Issues Error detection and correction Elementary datalink protocols Sliding window.
Chapter 11 Data Link Control
Data link control. Data Link Control –Flow Control how much data may sent –Error Control How can error be detected and corrected.
Flow and Error Control. Flow Control Flow control coordinates the amount of data that can be sent before receiving acknowledgement It is one of the most.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Chapter 11 Data Link Control and Protocols.
I N THE N AME OF G OD C OMPUTER N ETWORKS C HAPTER 3: T HE D ATA L INK L AYER ( PART 3) Dr. Shahriar Bijani Shahed University March 2014.
Data Link Layer Review Advanced Computer Networks.
Chapter 7 – Data Link Control Protocols
Networks: Data Link Layer1 Data Link Layer. Networks: Data Link Layer2 Data Link Layer Provides a well-defined service interface to the network layer.
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 10 Introduction to Computer Networks.
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 12 Introduction to Computer Networks.
The Data Link Layer Chapter 3. Position of the data-link layer.
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 11 Introduction to Computer Networks.
CMPE 150 – Winter 2009 Lecture 6 January 22, 2009 P.E. Mantey.
CSC 450/550 Part 2: The Data Link Layer. CSC 450/550 Summary Part A Functions (1)Functions of the data link layer (2)Framing (3)Error control (3.1) Error.
The Data Link Layer Chapter 3. Data Link Layer Design Issues Services Provided to the Network Layer Framing Error Control Flow Control.
20101 The Data Link Layer Chapter Design Issues Controls communication between 2 machines directly connected by “wire”-like link Services Provided.
Adapted from Tanenbaum's Slides for Computer Networking, 4e The Data Link Layer Chapter 3.
Data Link Control Protocols
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Data Link Layer We have now discussed the prevalent shared channel technologies  Ethernet/IEEE  Wireless LANs (802.11) We have now covered chapters.
Chapter 3 THE DATA LINK LAYER
Chapter 5 Peer-to-Peer Protocols and Data Link Layer PART I: Peer-to-Peer Protocols ARQ Protocols and Reliable Data Transfer Flow Control.
1 Transport Layer Lecture 10 Imran Ahmed University of Management & Technology.
The data link layer. Data Link Layer Design Issues Services Provided to the Network Layer Framing Error Control Flow Control.
The Data Link Layer. Functions of the Data Link Layer Provide service interface to the network layer Dealing with transmission errors Error detection.
The Data Link Layer Chapter 3 10/28/2015www.noteshit.com1.
Data Link and Flow Control Networks and Protocols Prepared by: TGK First Prepared on: Last Modified on: Quality checked by: Copyright 2009 Asia Pacific.
Computer Networks Lecture 3: Data Link - part II Based on slides from D. Choffnes Northeastern U. and P. Gill from StonyBrook University Revised Autumn.
Eighth Edition by William Stallings Chapter 7 – Data Link Control Protocols Data Link Control Protocols need layer of logic above Physical to manage exchange.
Data Link Layer: Data Link Control : Data Communication and Computer Networks Asst. Prof. Chaiporn Jaikaeo, Ph.D.
The Data Link Layer Chapter 3 1/21/2016www.ishuchita.com1.
Lecture Focus: Data Communications and Networking  Data Link Layer  Data Link Control Lecture 22 CSCS 311.
11.1 Flow and Error Control Flow Control Error Control.
Data Link Layer Flow and Error Control. Flow Control Flow Control Flow Control Specifies the amount of data can be transmitted by sender before receiving.
Telecommunications & Networking Lesson 3. ISO Open System Interconnect (OSI) Application Presentation Session Transport Network Data Link Physical Application.
Computer Networks, Fifth Edition by Andrew Tanenbaum and David Wetherall, © Pearson Education-Prentice Hall, 2011 The Data Link Layer Chapter 3.
CSCI 465 D ata Communications and Networks Lecture 11 Martin van Bommel CSCI 465 Data Communications & Networks 1.
Chi-Cheng Lin, Winona State University CS412 Introduction to Computer Networking & Telecommunication Data Link Layer Part II – Sliding Window Protocols.
1 The Data Link Layer A. S. Tanenbaum Computer Networks W. Stallings Data and Computer Communications Chapter 3.
DATA LINK CONTROL. DATA LINK LAYER RESPONSIBILTIES  FRAMING  ERROR CONTROL  FLOW CONTROL.
Computer Networking Lecture 16 – Reliable Transport.
NET 222: COMMUNICATIONS AND NETWORKS FUNDAMENTALS ( NET 222: COMMUNICATIONS AND NETWORKS FUNDAMENTALS (PRACTICAL PART) Tutorial 4 : Chapter 7 Data & computer.
Data Link Layer.
Chapter 3: The Data Link Layer –to achieve reliable, efficient communication between two physically connected machines. –Design issues: services interface.
Powerpoint Templates Data Communication Muhammad Waseem Iqbal Lec # 15.
Computer Communication & Networks
Data Link Layer Flow Control.
Data Link Layer - 3 Dr. Sanjay P. Ahuja, Ph.D.
Part III Datalink Layer 10.
Chap. 4 Data link layer 2.
Instructor Mazhar Hussain
Data Link Layer What does it do?
Flow Control.
Chapter 3 – Part 1 The Data Link Layer.
Data Link Layer: Data Link Control
Flow and Error Control.
Overview Jaringan Komputer (2)
Data Link Layer (cont’d)
Data Link Layer (cont’d)
Presentation transcript:

CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 13 Introduction to Computer Networks

CMPE 150- Introduction to Computer Networks 2 Announcements Midterm postponed! –Instead of 10.28, it will be on 11.04! Lab next week: –Discussion sessions on protocol pseudo-code (from Tanenbaum Chapter 3). –Also, checksum calculation practice! Homework 2 due on Monday,

CMPE 150- Introduction to Computer Networks 3 Hamming Code (Revisited)

CMPE 150- Introduction to Computer Networks 4 Hamming Code Check bits in power-of-two positions. Each check bit verifies a set of data bits. A data bit is checked by multiple check bits.

CMPE 150- Introduction to Computer Networks 5 Hamming Code (Cont’d) Parity computations: –11: 1, 2, 8 - 6: 2, 4 –10: 2, 8 - 5: 1, 4 –9: 1, 8 - 3: 1, 2 –7: 1, 2, 4

CMPE 150- Introduction to Computer Networks 6 Hamming Code: Example : 1, 3, 5, 7, 9, 11 Data: using even parity (counting from right to left).

CMPE 150- Introduction to Computer Networks 7 Hamming Code: Example 1 (Cont’d) : 1, 3, 5, 7, 9, 11 Data: using even parity (counting from right to left) : 3, 6, 7, 10,

CMPE 150- Introduction to Computer Networks 8 Hamming Code: Example 2 What if instead of , receiver gets ?. Receiver takes frame received and re-computes check bits.. 1, 3, 5, 7, 9, 11: 1, 1, 0, 0, 1 => 1. 2, 3, 6, 7, 10, 11: 0, 1, 1, 0, 0, 1 => 1. 4, 5, 6, 7 : 0, 0, 1, 0 => 1. 8, 9, 10, 11: 1, 0, 0, 1 => Result: Bit in position is wrong!

CMPE 150- Introduction to Computer Networks 9 How much code redundancy? How many check bits needed, i.e., given m data bits, how many more bits (r) are needed to allow all single-bit errors to be corrected? –Resulting frame is m + r. –(m+r+1) <= 2 r. –Given m, then find r. –Example: If m = 7 (ASCII 7 code), minimum r is 4.

CMPE 150- Introduction to Computer Networks 10 Hamming Code: Example 7-bit. Hamming codes can only correct single errors.. But, to correct bursts of errors, send column by column.

CMPE 150- Introduction to Computer Networks 11 Flow + Error Control Frame revisited. –Layer 2 encapsulation/decapsulation. –Flags. –Trailer: checksum. –Header: type, sequence number, ack.

CMPE 150- Introduction to Computer Networks 12 Stop-and-Wait Simplest form of flow control. How does it work? (assume error-free channel) –(1) Send 1 frame; –(2) Wait for ACK. –(3) Go to 1.

CMPE 150- Introduction to Computer Networks 13 Stop-and-Wait: Pros and Cons Very simple! But, poor link utilization. –High data rates. –Long propagation delay.

CMPE 150- Introduction to Computer Networks 14 Stop-and-Wait in Noisy Channels Need timers, retransmissions, and duplicate detection. Use sequence numbers. –Why? –Distinguish frames. –How large (e.g., in number of bits) are sequence numbers?

CMPE 150- Introduction to Computer Networks 15 ARQ Protocols Automatic Repeat Request. –Protocols that wait for ACK before sending more data. ACKs now are used for flow AND error control. What can happen? –At receiver: frame arrives correctly, frame arrives damaged, or frame does not arrive. –At sender: ACK arrives correctly, ACK arrives damaged, or ACK does not arrive.

CMPE 150- Introduction to Computer Networks 16 ARQ Protocols Sender: –Send frame 0. –Start timer. –If ACK 0, arrives, send frame 1. –If timeout, re-send frame 0. Receiver: –**Waits for frame. –If frame arrives, check if correct sequence number. –Then send ACK for that frame. –Go to (**)

CMPE 150- Introduction to Computer Networks 17 Simplex versus Duplex Transmission Simplex: –Send data in one channel and control in another channel. Duplex: –Send data and control on the same chanel.

CMPE 150- Introduction to Computer Networks 18 Can we do better? –Piggybacking. –Bi-directional transmission. –Wait for data packet and use that to piggyback the ACK. –Use ACK field: only a few additional bits in the header. But, how long should Layer 2 wait to send an ACK? –ACK timers!

CMPE 150- Introduction to Computer Networks 19 Sliding Window Protocols Window: number of “outstanding” frames at any given point in time. –So what’s the window size of Stop and Wait? Every ACK received, window slides.

CMPE 150- Introduction to Computer Networks 20 Sliding Window: Example A sliding window of size 1, with a 3-bit sequence number.(a) Initially; (b) After the first frame has been sent; (c) After the first frame has been received;(d) After the first acknowledgement has been received.

CMPE 150- Introduction to Computer Networks 21 Sliding Window: Basics Allows multiple frames to be in transit at the same time. Receiver allocates buffer space for n frames. Transmitter is allowed to send n (window size) frames without receiving ACK. Frame sequence number: labels frames.

CMPE 150- Introduction to Computer Networks 22 Sliding Window: Receiver Receiver ack’s frame by including sequence number of next expected frame. –Cumulative ACK: ack’s multiple frames. Example: if receiver receives frames 2,3, and 4, it sends an ACK with sequence number 5, which ack’s receipt of 2, 3, and 4.

CMPE 150- Introduction to Computer Networks 23 More Sliding Window … Sender maintains sequence numbers it’s allowed to send; receiver maintains sequence number it can receive. Sequence numbers are bounded; if frame reserves k-bit field for sequence numbers, then they can range from 0 … 2 k -1 k. Transmission window shrinks each time frame is sent, and grows each time an ACK is received.

CMPE 150- Introduction to Computer Networks 24 Example: 3-bit sequence number and window size ACK ACK A (Sender) B (Receiver) …

CMPE 150- Introduction to Computer Networks 25 One-Bit Sliding Window Protocol Two scenarios: (a) Normal case. (b) Abnormal case. Notation is (seq, ack, packet number). An * indicates where a network layer accepts packet. ACK indicates last sequence number received.

CMPE 150- Introduction to Computer Networks 26 Bandwidth-Delay Product How large should the sender’s window be? Function of how “fat” is the pipe? S R RTT BW W = BW*RTT/data size

CMPE 150- Introduction to Computer Networks 27 Pipelining Pipelining and error recovery. Effect on error when (a) Receiver’s window size is 1. (b) Receiver’s window size is large. Receiver’s window size is 1: discard frames after error with no ACK. Receiver’s window size is large: buffers all frames until error recovered. Selective Repeat Go Back N