Network Layer4-1 Lower limit on the number of check bits r We want to design a code m with m message bits and r check bits Allowing all single errors to.

Slides:



Advertisements
Similar presentations
Channel Allocation Protocols. Dynamic Channel Allocation Parameters Station Model. –N independent stations, each acting as a Poisson Process for the purpose.
Advertisements

The ALOHA Protocol “Free for all”: whenever station has a frame to send, it does so. –Station listens for maximum RTT for an ACK. –If no ACK after a specified.
EECC694 - Shaaban #1 lec #5 Spring Data Link In Broadcast Networks: The Media Access Sublayer Broadcast networks with multi-access (or random.
5-1 Link Layer: Introduction Some terminology: r hosts and routers are nodes r communication channels that connect adjacent nodes along communication path.
1 Pertemuan 13 Teknik Akses Jaringan - Random Matakuliah: H0174/Jaringan Komputer Tahun: 2006 Versi: 1/0.
EEC-484/584 Computer Networks Lecture 7 Wenbing Zhao
15 – Data link layer Chapter 5: The Data Link Layer Our goals: r understand principles behind data link layer services: m error detection, correction.
5: DataLink Layer5-1 Data Link Layer r What is Data Link Layer? r Multiple access protocols r Ethernet.
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 17 Introduction to Computer Networks.
EEC-484/584 Computer Networks Lecture 13 Wenbing Zhao
Review r Multicast Routing m Three options m source-based tree: one tree per source shortest path trees reverse path forwarding m group-shared tree: group.
EEC-484/584 Computer Networks Lecture 7 Wenbing Zhao
DataLink Layer session 1 TELE3118: Network Technologies Week 2: Data Link Layer Framing, Error Control, Multiple Access Some slides have been taken.
EEC-484/584 Computer Networks Lecture 13 Wenbing Zhao
5-1 Data Link Layer r Today, we will study the data link layer… r This is the last layer in the network protocol stack we will study in this class…
5: DataLink Layer5-1 Link Layer – Error Detection/Correction and MAC.
5: DataLink Layer5-1 Chapter 5 Link Layer and LANs Computer Networking: A Top Down Approach Featuring the Internet, 3 rd edition. Jim Kurose, Keith Ross.
ECE358: Computer Networks Spring 2012
EEC-484/584 Computer Networks Lecture 13 Wenbing Zhao
CS352- Link Layer Dept. of Computer Science Rutgers University.
EEC-484/584 Computer Networks Lecture 7 Wenbing Zhao
Semester EEE449 Computer Networks The Data Link Layer Part 2: Media Access Control En. Mohd Nazri Mahmud MPhil (Cambridge, UK) BEng (Essex,
Medium Access Control Sublayer
Introduction1-1 1DT014/1TT821 Computer Networks I Chapter 5 Link Layer and LANs.
ICOM 6115©Manuel Rodriguez-Martinez ICOM 6115 – Computer Networks and the WWW Manuel Rodriguez-Martinez, Ph.D. Lecture 17.
1 ECE453 – Introduction to Computer Networks Lecture 7 – Multiple Access Control (I)
5: DataLink Layer5-1 Chapter 5 Link Layer and LANs Part 3: MAC Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley.
Chi-Cheng Lin, Winona State University CS412 Introduction to Computer Networking & Telecommunication Medium Access Control Sublayer.
4-1 Last time □ Link layer overview ♦ Services ♦ Adapters □ Error detection and correction ♦ Parity check ♦ Internet checksum ♦ CRC □ PPP ♦ Byte stuffing.
NUS.SOC.CS2105 Ooi Wei Tsang Application Transport Network Link Physical you are here.
LECTURE9 NET301. DYNAMIC MAC PROTOCOL: CONTENTION PROTOCOL Carrier Sense Multiple Access (CSMA): A protocol in which a node verifies the absence of other.
جلسه دهم شبکه های کامپیوتری به نــــــــــــام خدا.
Chapter 5 Link Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 Link Layer multiple.
Link Layer5-1 Chapter 5: Link layer our goals:  understand principles behind link layer services:  error detection, correction  sharing a broadcast.
Medium Access Control NWEN302 Computer Network Design.
Chi-Cheng Lin, Winona State University CS 313 Introduction to Computer Networking & Telecommunication Medium Access Control Sublayer.
جلسه یازدهم شبکه های کامپیوتری به نــــــــــــام خدا.
4: DataLink Layer1 Multiple Access Links and Protocols Three types of “links”: r point-to-point (single wire, e.g. PPP, SLIP) r broadcast (shared wire.
Medium Access Control Sub Layer
5: DataLink Layer5-1 Link Layer r 5.1 Introduction and services r 5.2 Error detection and correction r 5.3Multiple access protocols r 5.4 Link-Layer Addressing.
11/25/20151 EEC-484 Computer Networks Lecture 12 Wenbing Zhao Cleveland State University
Ethernet. Ethernet (802.3) 1-persistent CSMA, CD, binary exponential backoff Carrier sense: station listens to channel first. 1-persistent: If idle, station.
5: DataLink Layer 5a-1 Multiple Access protocol. 5: DataLink Layer 5a-2 Multiple Access Links and Protocols Three types of “links”: r point-to-point (single.
5: DataLink Layer5-1 Chapter 5: The Data Link Layer Our goals: r Understand principles behind data link layer services: m error detection, error correction.
EEC-484/584 Computer Networks
5: DataLink Layer5-1 Chapter 5: The Data Link Layer Our goals: r Understand principles behind data link layer services: m error detection, error correction.
5: DataLink Layer5a-1 Chapter 5: The Data Link Layer Our goals: r understand principles behind data link layer services: m error detection, correction.
EE 122: Lecture 6 Ion Stoica September 13, 2001 (* this talk is based in part on the on-line slides of J. Kurose & K. Rose)
MAC Layer Protocols for Wireless Networks. What is MAC? MAC stands for Media Access Control. A MAC layer protocol is the protocol that controls access.
5: DataLink Layer5-1 Chapter 5: The Data Link Layer Our goals: r understand principles behind data link layer services: m error detection, error correction.
Transport Layer 3-1 Chapter 5 Link Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012  CPSC.
Network Layer4-1 Chapter 5: The Data Link Layer Our goals: r understand principles behind data link layer services: m error detection, correction m sharing.
5: DataLink Layer5-1 Chapter 5 Link Layer and LANs Computer Networking: A Top Down Approach Featuring the Internet, 3 rd edition. Jim Kurose, Keith Ross.
5: DataLink Layer5-1 Link Layer r 5.1 Introduction and services r 5.2 Error detection and correction r 5.3Multiple access protocols r 5.4 Link-layer Addressing.
Chapter 4 The Medum Access Sublayer. MA Sublayer Additional Reference –Local and Metropolitan Area Networks, William Stallings, Prentice Hall, 2000, 6th.
THE MEDIUM ACCESS CONTROL SUBLAYER 4.1 THE CHANNEL ALLOCATION PROBLEM 4.2 MULTIPLE ACCESS PROTOCOLS.
COMPUTER NETWORKS Data-link Layer (The Medium Access Control Sublayer) MAC Sublayer.
EEC-484/584 Computer Networks
Chapter 5 Link Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley March 2012 A note on the use of these.
Example DLL Protocols 1. High-Level Data Link Control (HDLC).
Chapter 5 Link Layer and LANs
CS 457 – Lecture 6 Ethernet Spring 2012.
Services of DLL Framing Link access Reliable delivery
Multiple access.
2017 session 1 TELE3118: Network Technologies Week 2: Data Link Layer Framing, Error Control, Multiple Access Slides have been adapted from: Computer.
2012 session 1 TELE3118: Network Technologies Week 2: Data Link Layer Framing, Error Control, Multiple Access Some slides have been taken from: Computer.
The Medium Access Control Sublayer
Link Layer and LANs Not everyone is meant to make a difference. But for me, the choice to lead an ordinary life is no longer an option 5: DataLink Layer.
Link Layer: Multiple Access
Chapter 6 Multiple Radio Access.
Presentation transcript:

Network Layer4-1 Lower limit on the number of check bits r We want to design a code m with m message bits and r check bits Allowing all single errors to be corrected m This requirement becomes m This put a lower limit on the number of check bits Needed to correct a single error

Network Layer4-2 Error correcting code: Hamming code r A data bit in position k m is checked by just those check bits occurring in its expansion

Network Layer4-3 Use of Hamming code to correct burst errors

Network Layer4-4 Parity Checking Single Bit Parity: Detect single bit errors Two Dimensional Bit Parity: Detect and correct single bit errors 0 0

Network Layer4-5 Error detecting codes r Cyclic Redundancy Check (CRC) m is in widespread use, and called polynomial code treats bits as 0 and 1 coefficients of polynomials –For example: represents x 5 +x 4 + x 0 m Sender and receiver agree upon a generator polynomial G(x) To compute the checksum for some frame of m bits M(x) => append a checksum to the end of frame –such that polynomial is divisible by G(x) Receiver divides check-summed frame by G(x) –If there is a remainder => there has been an error

Network Layer4-6 Checksumming: Cyclic Redundancy Check r view data bits, D, as a binary number r choose r+1 bit pattern (generator), G r goal: choose r CRC bits, R, such that m exactly divisible by G (modulo 2) m receiver knows G, divides by G. If non-zero remainder: error detected! m can detect all burst errors less than r+1 bits r widely used in practice (Ethernet, WiFi, ATM)

Network Layer4-7 Algorithm for computing the checksum r Let r be the degree of G(x) m Append r zeros to the low-order end of the frame m => x r M(x) r Divide the bit string corresponding to G(x) m Into the bit string corresponding x r M(x) using Modulo 2 division r Subtract the remainder from x r M(x) m The result is the checksumed frame to be transmitted

Network Layer4-8 Error detecting codes: example Calculation of the polynomial code checksum.

Network Layer4-9 CRC Example Want: D. 2 r XOR R = nG equivalently: D. 2 r = nG XOR R equivalently: if we divide D. 2 r by G, want remainder R R = remainder[ ] D.2rGD.2rG

Network Layer4-10 Link Layer r 5.1 Introduction and services r 5.2 Error detection and correction r 5.3Multiple access protocols r 5.4 Link-layer Addressing r 5.5 Ethernet r 5.6 Link-layer switches r 5.7 PPP r 5.8 Link Virtualization: ATM, MPLS

Network Layer4-11 Multiple Access Links and Protocols Two types of “links”: r point-to-point m PPP for dial-up access m point-to-point link between Ethernet switch and host r broadcast (shared wire or medium) m old-fashioned Ethernet m upstream HFC m wireless LAN shared wire (e.g., cabled Ethernet) shared RF (e.g., WiFi) shared RF (satellite) humans at a cocktail party (shared air, acoustical)

Network Layer4-12 Multiple Access protocols r single shared broadcast channel r two or more simultaneous transmissions by nodes: interference m collision if node receives two or more signals at the same time multiple access protocol r distributed algorithm that determines how nodes share channel, i.e., determine when node can transmit r communication about channel sharing must use channel itself! m no out-of-band channel for coordination

Network Layer4-13 CSMA (Carrier Sense Multiple Access) CSMA: listen before transmit: If channel sensed idle: transmit entire frame r If channel sensed busy, defer transmission r human analogy: don’t interrupt others!

Network Layer4-14 CSMA/CD (Collision Detection) CSMA/CD: carrier sensing, deferral as in CSMA m collisions detected within short time m colliding transmissions aborted, reducing channel wastage r collision detection: m easy in wired LANs: measure signal strengths, compare transmitted, received signals m difficult in wireless LANs: received signal strength overwhelmed by local transmission strength r human analogy: the polite conversationalist

Network Layer4-15 Link Layer r 5.1 Introduction and services r 5.2 Error detection and correction r 5.3Multiple access protocols r 5.4 Link-layer Addressing r 5.5 Ethernet r 5.6 Link-layer switches r 5.7 PPP r 5.8 Link Virtualization: ATM, MPLS

Network Layer4-16 Multiple Access Links and Protocols Two types of “links”: r point-to-point m PPP for dial-up access m point-to-point link between Ethernet switch and host r broadcast (shared wire or medium) m old-fashioned Ethernet m upstream HFC m wireless LAN shared wire (e.g., cabled Ethernet) shared RF (e.g., WiFi) shared RF (satellite) humans at a cocktail party (shared air, acoustical)

Network Layer4-17 LANs structure r LANs m Use a multi-access channel as basis for communication Broadcast channel m Key issue Determine who gets to use the channel when –There is a competition for it m Medium Access Control protocols of data link layer Determines who goes next on a multi-access channel MAC sublayer is especially important in LANs

Network Layer4-18 Dynamic channel allocation in LANs and MANs r Work in this area based on 2 assumptions m Single channel Available for all communication m Collision assumption If 2 frames are simultaneously sent => collision A collided frame must be sent again later There are no errors other than those generated by collisions

Network Layer4-19 Multiple Access protocols r single shared broadcast channel r two or more simultaneous transmissions by nodes: interference m collision if node receives two or more signals at the same time multiple access protocol r distributed algorithm that determines how nodes share channel, i.e., determine when node can transmit r communication about channel sharing must use channel itself! m no out-of-band channel for coordination

Network Layer4-20 MAC function: arbitration r Imagine trying to get thru an intersection m When all traffic light are out You all want to use the intersection But you had better use it one at a time cannot allow cars from every direction to enter intersection –At the same time without having serious collisions r Data frames can collide if devices send any time m During collision, LAN is unusable Not too different from a car crash in middle of an intersection r MAC arbitrate the use of physical medium m To avoid collisions or recover when they occur

Network Layer4-21 CSMA (Carrier Sense Multiple Access) CSMA: listen before transmit: If channel sensed idle: transmit entire frame r If channel sensed busy, defer transmission r human analogy: don’t interrupt others!

Network Layer4-22 CSMA/CD (Collision Detection) CSMA/CD: carrier sensing, deferral as in CSMA m collisions detected within short time m colliding transmissions aborted, reducing channel wastage r collision detection: m easy in wired LANs: measure signal strengths, compare transmitted, received signals m difficult in wireless LANs: received signal strength overwhelmed by local transmission strength r human analogy: the polite conversationalist

Network Layer4-23 CSMA with Collision Detection: operational description r A user who wishes to transmit m 1) listen to see if the channel is free. If channel is idle => it transmits Otherwise, keeps on listening until channel is free –Then transmits immediately (1-persistent) m 2) during transmission keeps listening to detect collisions If a collision is detected => stops transmission immediately –Quickly terminating saves time and bandwidth And wait a random time before goes back to step 1 r CSMA/CD is widely used on LANs (basis of Ethernet)

Network Layer4-24 CSMA/CD: animation

Network Layer4-25 CSMA/CD: conceptual model r at t 0, more than one station try to send => collision m Each station aborts its transmission, wait a random time m => model consists of alternating periods Of contention and transmission, –idle occurs when there is no work r If 2 stations start transmitting at time t 0 m How long will it take them to realize they are in collision?

Network Layer4-26 Collision detection r The min time to detect the collision m is the time it takes the signal to reach another station if a station does not hear a collision after this full time –Can it assume that it has seized the channel? –All other stations knew it was transmitting and not interfere r Worst case scenario m Time for signal to propagate between farthest stations is m At the most distant station decides to send It will sense the collision very fast But first station will not get the collision burst till after

Network Layer4-27 Contention period r In the worst case, a station cannot be sure m It has seized the channel until it has transmitted for Without hearing a collision

Network Layer4-28 Minimum length frame r Reason for having a min length frame m To prevent a station from completing transmission Before the first bit has reached the far end Where it may collide with another frame m When B detects collision It sends a 48 bit noise burst to let everyone know about it

Network Layer4-29 Minimum length frame (cont’d) r If a station tries to send a very short frame m It might happen that sender finishes sending Before the noise burst arrives at A frame must take more than to send –that transmission is still taking place when noise gets back r For a 10 Mbps LAN m with a max length of 2500 meters and 4 repeaters m The round trip delay = 50 microseconds m The small frame is 500 bits (at 10 Mbps, 1 bit take 100 ns) With some margin of safety this was added to 512 or 64 bytes

Network Layer4-30 Network speed impact r As network speed goes up m The min frame length must go up m Or the maximum cable length must come down r For a 250-meter LAN m Operating at 1 Gbps m The min frame size should be 640 bytes

Network Layer4-31 Binary backoff exponential algorithm r How is randomization done in case of collision? m After a collision, time is divided into discrete slots Whose length is set to 512 bit times or 51.2 microseconds m After the first collision Each station waits for 0 or 1 slots. –If both pick the same number => Each one picks between 0, 1, 2, or 3 slots –If collision again => pick from 0 to After i collisions a random # between 0 and 2 i -1 is chosen –After 10 collisions => number is frozen at 1023 slots –After 16 collisions => give up

Network Layer4-32 In-class exercise r Let A and B be 2 stations attempting to transmit on Ethernet m Each has a steady stream of frames ready to send A’s frame are numbered: A1, A2, … B’s are similarly #ered m Let T = 51.2 microseconds = exponential backoff unit r Suppose A and B simultaneously m attempt to send frame 1, collide and happen to choose backoff times –0.T and 1.T respectively, meaning A wins the race r B will attempt to retransmit B1 while A transmit A2

Network Layer4-33 In-class exercise (cont’d) r These first attempts will collide m but A backoffs for either 0xT or 1xT m While B backoffs for time equal to one of 0xT, …, 3xT r Give the probability that A wins m the second backoff race immediately after the first collision

Network Layer4-34 Ethernet performance r Ethernet uses CSMA/CD + binary exp. Backoff m If each station transmits during a contention slot With probability p m The probability A that some station acquires the channel In that same slot is A is maximized when p = 1/k, with A → 1/e as k → infinity –Where k is the # stations ready to transmit Probability that contention interval has exactly j slots in it

Network Layer4-35 Channel efficiency r The mean number of slots per contention interval r Since each slot has a duration m The mean contention interval, w, is r If the mean frame takes P sec to transmit

Network Layer4-36 Channel efficiency vs. # stations trying to send r F, frame length, bandwidth B m Cable length L, speed of propagation c, m e contentions per frame