Professional Documents
Culture Documents
Chapter 5
Link Layer and LANs
Our goals:
Computer Networking:
A Top Down Approach
4th edition.
Jim Kurose, Keith Ross
Addison-Wesley, July
2007.
5: DataLink Layer
5-1
5: DataLink Layer
5-2
Link Layer
point-to-point
old-fashioned Ethernet
upstream HFC
802.11 wireless LAN
5-3
shared RF
(e.g., 802.11 WiFi)
shared RF
(satellite)
humans at a
cocktail party
(shared air, acoustical)
5: DataLink Layer
5-4
5: DataLink Layer
4. simple
5: DataLink Layer
5-6
Taking turns
Random Access
5-5
6-slot
frame
nodes take turns, but nodes with more to send can take
longer turns
5: DataLink Layer
5-7
5: DataLink Layer
5-8
FDM cable
frequency bands
time
5: DataLink Layer
slotted ALOHA
ALOHA
CSMA, CSMA/CD, CSMA/CA
5-9
5: DataLink Layer
5-10
Slotted ALOHA
Slotted ALOHA
Assumptions:
all frames same size
time divided into equal
size slots (time to
transmit 1 frame)
nodes start to transmit
only slot beginning
nodes are synchronized
if 2 or more nodes
transmit in slot, all
nodes detect collision
Operation:
when node obtains fresh
frame, transmits in next
slot
if no collision: node can
send new frame in next
slot
if collision: node
retransmits frame in
each subsequent slot
with prob. p until
success
5: DataLink Layer
5-11
Pros
single active node can
continuously transmit
at full rate of channel
highly decentralized:
only slots in nodes
need to be in sync
simple
Cons
collisions, wasting slots
idle slots
nodes may be able to
detect collision in less
than time to transmit
packet
clock synchronization
5: DataLink Layer
5-12
Efficiency : long-run
fraction of successful slots
(many nodes, all with many
frames to send)
transmit immediately
At best: channel
!
5-13
5: DataLink Layer
5-14
= 1/(2e) = .18
5: DataLink Layer
5-15
5: DataLink Layer
5-16
CSMA collisions
collisions
colliding
wastage
collision:
collision detection:
easy in wired LANs: measure signal strengths,
compare transmitted, received signals
difficult in wireless LANs: received signal strength
overwhelmed by local transmission strength
note:
5-17
5: DataLink Layer
5-18
5: DataLink Layer
5-19
5: DataLink Layer
5-20
polling overhead
latency
single point of
failure (master)
data
poll
master
data
slaves
(nothing
to send)
token overhead
latency
single point of failure
(token)
data
5: DataLink Layer
5-21
access
addressing
Ethernet
switches
PPP
taking turns
5-22
LAN technologies
5: DataLink Layer
5: DataLink Layer
5-23
5: DataLink Layer
5-24
Link Layer
32-bit IP address:
network-layer
address
used to get datagram to destination IP subnet
address:
function:
48
5: DataLink Layer
5-25
5: DataLink Layer
5-26
1A-2F-BB-76-09-AD
71-65-F7-2B-08-53
LAN
(wired or
wireless)
Broadcast address =
FF-FF-FF-FF-FF-FF
= adapter
58-23-D7-FA-20-B0
0C-C4-11-6F-E3-98
5: DataLink Layer
5-27
5: DataLink Layer
5-28
MAC address of B
knowing Bs IP address?
137.196.7.78
1A-2F-BB-76-09-AD
137.196.7.23
137.196.7.14
LAN
71-65-F7-2B-08-53
137.196.7.88
58-23-D7-FA-20-B0
0C-C4-11-6F-E3-98
5: DataLink Layer
ARP is plug-and-play:
5-29
5: DataLink Layer
111.111.111.111
E6-E9-00-17-BB-4B
1A-23-F9-CD-06-9B
destined to B
222.222.222.221
222.222.222.222
88-B2-2F-54-1A-0F
74-29-9C-E8-FF-55
49-BD-D2-C7-56-2A
E6-E9-00-17-BB-4B
CC-49-DE-D0-AB-7D
111.111.111.111
111.111.111.112
88-B2-2F-54-1A-0F
74-29-9C-E8-FF-55
5-30
222.222.222.220
111.111.111.110
111.111.111.112
222.222.222.221
1A-23-F9-CD-06-9B
222.222.222.222
49-BD-D2-C7-56-2A
CC-49-DE-D0-AB-7D
5: DataLink Layer
5-31
5: DataLink Layer
5-32