McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Chapter 11 Data Link Control and Protocols.

Slides:



Advertisements
Similar presentations
Assume that a file is transferred from a node A to a node B. The file has been fragmented in 5 frames. Frame 0 is corrupted, the ACK of frame 1 is corrupted,
Advertisements

William Stallings Data and Computer Communications 7th Edition
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Data Link Control We want to minimize the amount of error correcting and detecting we need to do.
Chapter 11 Data Link Control
Data and Computer Communications Updated: 2/9/2009.
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.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
11-5 NOISY CHANNELS Although the Stop-and-Wait Protocol gives us an idea of how to add flow control to its predecessor, noiseless channels are nonexistent.
The two main functions of the data link layer are data link control and media access control. Data link control deals with the design and procedures for.
TCP/IP Protocol Suite 1 Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. Chapter 13 Introduction to the Transport.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
11-6 HDLC High-level Data Link Control (HDLC) is a bit-oriented protocol for communication over point-to-point and multipoint links. It implements the.
Chapter 7 – Data Link Control Protocols
The Data Link Layer Chapter 3. Position of the data-link layer.
Chapter 9: Data Link Control Business Data Communications, 4e.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
15 - Winter 2006 ECE ECE 766 Computer Interfacing and Protocols 1 Data Link Control Physical layer is only responsible for data transmission Data link.
Data Link Control Protocols
Data Link Control Protocols Dr. Muazzam A. Khan. Flow Control Ensuring the sending entity does not overwhelm the receiving entity —Preventing buffer overflow.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
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.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
1 Kyung Hee University Chapter 11 Data Link Control.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Data Link Control and Protocols.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
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 Kyung Hee University Data Link Protocols. 2 Kyung Hee University 11 장 Data Link Control and Protocols 11.1 Flow and Error Control 11.2 Stop-and-Wait.
Computer Networks Module 3: Data Link Layer (Framing) Dr. Vikram Shete St. Francis Institute of Technology.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Chapter 11 Data Link Control and Protocols.
Chapter 11 Data Link Control
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.
Chapter 3: Channel Coding (part 3). Automatic repeat request (ARQ) protocols ▫Used in combination with error detection/correction ▫Block of data with.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
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.
1 Flow&Error Control R. Supakorn. 2 Flow Control Flow control refers to a set of procedure used to restrict the amount of data that the sender can send.
Chapter 11 Data Link Control.
Part III. Data Link Layer Chapter 11. Data Link Control COMP 3270 Computer Networks Computing Science Thompson Rivers University.
Chapter 11 Data Link Control and Protocols Flow and Error Control Flow Control Error Control.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Data and Computer Communications Data Link Control Protocols.
DATA LINK CONTROL. DATA LINK LAYER RESPONSIBILTIES  FRAMING  ERROR CONTROL  FLOW CONTROL.
11.1 Chapter 11 Data Link Control Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
Chapter 9: Data Link Control Business Data Communications, 4e.
NET 222: COMMUNICATIONS AND NETWORKS FUNDAMENTALS ( NET 222: COMMUNICATIONS AND NETWORKS FUNDAMENTALS (PRACTICAL PART) Tutorial 4 : Chapter 7 Data & computer.
Data Link Layer.
McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Chapter 11 Data Link Control and Protocols 1.
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.
Computer Communication & Networks
2.10 Flow and Error Control Before that ...
Chapter 11 Data Link Control and Protocols
Part III Datalink Layer 10.
UNIT 4 Data Link Control Line Discipline Flow Control Error Control
Instructor Mazhar Hussain
Chapter 3 Data Link Layer.
CIS 321 Data Communications & Networking
Subject Name: Computer Communication Networks Subject Code: 10EC71
Flow Control.
Data Link Layer: Data Link Control
Flow and Error Control.
Chapter 11 Data Link Control and Protocols.
Kendali Data Link dan Protokol
Chapter 11 Data Link Control
Presentation transcript:

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Chapter 11 Data Link Control and Protocols

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Flow and Error Control Flow control refers to a set of procedures used to restrict the amount of data that the sender can send before waiting for acknowledgment. Flow control refers to a set of procedures used to restrict the amount of data that the sender can send before waiting for acknowledgment. Error control in the data link layer is based on automatic repeat request (ARQ), which is the retransmission of data. Error control in the data link layer is based on automatic repeat request (ARQ), which is the retransmission of data.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Flow and Error Control Mechanisms Stop-AND-WAIT ARQ Go-BACK-N ARQ SELECTIVE REPEAT ARQ Flow and Error control Mechanisms

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Stop-and-Wait ARQ Keep a copy of the frame until ACK is received. Frame 0 is acknowledged by ACK 1 and vice-versa. Lost and corrupted frames are considered as same and No ACK is sent. Sender’s control variable S = holds number of recently sent frame Receiver’s control variable R = holds number of the next frame expected Sender starts a timer when it sends a frame. If an ack does not arrive within an allotted time period, sender assumes that packet is corrupted or lost. Sender will resend the same packet.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Operation of Stop-and-Wait ARQ 1.Normal Operation 2.Frame is lost 3.Acknowledgment is lost 4.Ack nowledgment is delayed

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Operation of Stop-and-Wait ARQ Frame is lost

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Operation of Stop-and-Wait ARQ lost ACK frame In Stop-and-Wait ARQ, numbering frames prevents the retaining of duplicate frames.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Stop-and-Wait ARQ, delayed ACK The value of R at the receiver site is still 1, which means the receiver expects to see frame 1. Numbered acknowledgments are needed if an acknowledgment is delayed and the next frame is lost.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Piggybacking Bidirectional transmission Method to combine a data frame with an acknowledgement.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Go-back-N ARQ Sending multiple frames at a time. Keep the copy of the frames before ACK is received. Sequence number is included in each frame in the header. If there are m bits for sequence number then we can have maximum 2 m – 1. Sender Sliding Window Window size is fixed here.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Size of window at receiver site is always 1. Receiver is always looking for a specific frame to arrive in a specific order. Receiver sliding window

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Control variables S = Sequence number of the recently sent frame S F = Sequence number of first frame in the window S L = Sequence number of last frame in the window Window Size = S L – S F + 1 If sequence number of received frame is same as R, accept it.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Timers The sender set timer for each frame Receiver has no timer. Acknowledgment Resending Frames When a frame is lost or damaged, sender send a block of frames. This block starts from one that has lost or damaged up to the current frame sent. More Important Variables

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Go-Back-N ARQ, normal operation

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Go-Back-N ARQ, lost frame Frame 2 is lost. When the receiver receives frame 3, it is discarded because the receiver is expecting frame 2, not frame 3 (according to its window) Acknowledgements are cumulative

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Go-Back-N ARQ, Lost Acknowledgment Two cases are possible ACK arrives before the expiry of the timer No need to resend the frames ACK arrives before the expiry of the timer Resend all the frames starting with one for which timer has expired to the last one sent. Delayed ACK

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Go-Back-N ARQ: sender window size If size of window is less than 2 m, and all three ACK are lost, the frame 0 timer expires and all three frames are resent. Receiver discards them as duplicate. If size of window is equal to 2 m, and all three ACK are lost, sender will send the duplicate frame 0 but receiver will accept it as next frame as it expects that

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Selective Repeat ARQ, sender and receiver windows Go-back-N resends multiple frames and its inefficient in noisy links. Sender and receiver window size is at most one-half of the value 2 m. Specifies the range of accepted frames. Receiver reports the damaged frame using negative ACK (NAK)

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Selective Repeat ARQ, lost frame

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Selective Repeat ARQ, sender window size Size of window is 2 and all acknowledgements are lost, the timer for frame 0 expires and frame 0 is resent. Receiver is expecting frame 2, not frame 0, so this duplicate frame is correctly discarded. Size of window is 3 and all acknowledgements are lost, the sender sends a duplicate of frame 0. Receiver expects 0 as part of window and so accepts it.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Example 1 In a Stop-and-Wait ARQ system, the bandwidth of the line is 1 Mbps, and 1 bit takes 20 ms to make a round trip. What is the bandwidth-delay product? If the system data frames are 1000 bits in length, what is the utilization percentage of the link? Solution The bandwidth-delay product is 1  10 6  20  = 20,000 bits The system can send 20,000 bits during the time it takes for the data to go from the sender to the receiver and then back again. However, the system sends only 1000 bits. We can say that the link utilization is only 1000/20,000, or 5%. For this reason, for a link with high bandwidth or long delay, use of Stop-and-Wait ARQ wastes the capacity of the link.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Example 2 What is the utilization percentage of the link in Example 1 if the link uses Go- Back-N ARQ with a 15-frame sequence? Solution The bandwidth-delay product is still 20,000. The system can send up to 15 frames or 15,000 bits during a round trip. This means the utilization is 15,000/20,000, or 75 percent. Of course, if there are damaged frames, the utilization percentage is much less because frames have to be resent.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Pipelining A new task is taken before the last task finished is known as pipelining. Stop-and-Wait ARQ Not a pipelined case. Go-Back-N ARQ and Selective Repeat are examples of pipelining.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 HDLC HDLC (High-level Data Link Control) is an actual protocol designed to support both half-duplex and full-duplex communication over point-to- point and multipoint links. NRM- Normal Response Mode ABM- Asynchronous Balanced Mode I-Frame (Information frame): Used to transport user data and control information relating to user data (piggybacking). S-frame (Supervisory frame): Used only to transport control information. U-frame (Unnumbered frame): Reserved for system management.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 HDLC frame types I-Frame has sequence and ACK numbers S-frame contains the code for Receive Ready, Receive Not Ready, Reject, Selective Reject. U-frame is used for session management and control information

McGraw-Hill©The McGraw-Hill Companies, Inc., Example 3

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Example 4 In Example 3, suppose frame 1 sent from station B to station A has an error. Station A informs station B to resend frames 1 and 2 (the system is using the Go-Back- N mechanism). Station A sends a reject supervisory frame to announce the error in frame 1. Figure shows the exchange.

McGraw-Hill©The McGraw-Hill Companies, Inc., Example 4

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Bit stuffing and removal Data field can not have the field reserved for the flag field. Bit stuffing is the process of adding one extra 0 whenever there are five consecutive 1s in the data so that the receiver does not mistake the data for a flag.

McGraw-Hill©The McGraw-Hill Companies, Inc., 2004 Bit stuffing in HDLC