Professional Documents
Culture Documents
Lectures 8-10 Data Link Layer: Computer Communications
Lectures 8-10 Data Link Layer: Computer Communications
Lectures 8-10
Data Link Layer
Required Reading: Tanenbaum (chapter 3), Peterson &
Davie (chapter 1)
Transfer data from the network layer at source to the network layer at
destination
Common services
Unacknowledged connectionless service: suitable for low error rate channels, realtime traffic
Acknowledged connectionless service: useful for wireless systems
Acknowledged connection-oriented service: provides the illusion of a reliable bit
stream
Framing
Breaking the bit stream into discrete frames
Methods:
Insert time gaps
Character count
Flag bytes with byte stuffing
Starting and ending flags, with bit stuffing
Physical layer coding violations
Flow Control
Feedback-based
Rate-based
10
11
Protocol Definitions
Continued
Protocol
Definitions
(ctd.)
Some definitions
needed in the
protocols to follow.
These are located in
the file protocol.h.
13
Unrestricted Simplex
Protocol
Unidirectional
transmission
Network layers at
sender and receiver
always ready
Negligible
processing time
Infinite buffers
Error-free channel
14
15
Continued
16
18
19
10
Continued
21
22
11
Two scenarios for protocol 4. (a) Normal case. (b) Abnormal case.
The notation is (seq, ack, packet number). An asterisk indicates where a
network layer accepts a packet.
23
Terminology
Bandwidth (of channel/link/network/end-to-end)
Network engineers often use the term bandwidth
Not the same bandwidth in Hz
Instead in bps, refers to capacity or maximum data rate or maximum bit-rate
Differentiate with throughput effective data rate
24
12
100
50
20
10
5
2
1
10
RTT (ms)
100
25
Example:
50Kbps satellite channel with 500ms round-trip propagation delay
1000-bit frames 20ms transmit time
Minimum time required for sender to receive an ACK: 520ms 500ms idle
time (could have send 25 more frames)
26
13
Delay
Bandwidth
Network as a pipe
27
Pipelining
To achieve higher efficiency when BDP is large
Send w frames before blocking, i.e., increase sender window size to w,
instead of just 1
Match w (window size) to bandwidth-delay product (pipe volume)
28
14
30
15
Sliding Window
Protocol Using Go
Back N
Continued
31
Continued
32
16
Continued
33
34
17
35
Continued
36
18
Continued
37
Continued
38
19
39
20
Additional issues:
#Buffers at receiver = window size
#Timers = #Buffers
Use of auxiliary timer at receiver for sending separate ACKs when no
reverse traffic to piggyback them
Length of the timeout?
41
21
Hamming Codes
Can correct single errors
Can also be used to correct a single burst errors via interleaved
transmission
Similar approach also works with parity bits to detect a burst errors
43
22
23
24