Professional Documents
Culture Documents
0 0
D.2r
R = remainder[ ]
G
humans at a
shared wire (e.g., shared RF shared RF cocktail party
cabled Ethernet) (e.g., 802.11 WiFi) (satellite) (shared air, acoustical)
Data Link Layer 5-10
Multiple Access protocols
single shared broadcast channel
two or more simultaneous transmissions by nodes:
interference
collision if node receives two or more signals at the same time
multiple access protocol
distributed algorithm that determines how nodes
share channel, i.e., determine when node can transmit
communication about channel sharing must use channel
itself!
no out-of-band channel for coordination
“Taking turns”
Nodes take turns, but nodes with more to send can take
longer turns
FDM cable
Pros Cons
single active node can collisions, wasting slots
continuously transmit idle slots
at full rate of channel nodes may be able to
highly decentralized: detect collision in less
only slots in nodes than time to transmit
packet
need to be in sync
clock synchronization
simple
Data Link Layer 5-18
Slotted Aloha efficiency
Efficiency is the long-run For max efficiency
fraction of successful slots with N nodes, find p*
when there are many nodes, that maximizes
each with many frames to send Np(1-p)N-1
For many nodes, take
Suppose N nodes with limit of Np*(1-p*)N-1
many frames to send, as N goes to infinity,
each transmits in slot gives 1/e = .37
with probability p
prob that node 1 has At best: channel
success in a slot used for useful
= p(1-p)N-1 transmissions 37%
prob that any node has of time!
a success = Np(1-p)N-1
Data Link Layer 5-19
Pure (unslotted) ALOHA
unslotted Aloha: simpler, no synchronization
when frame first arrives
transmit immediately
= 1/(2e) = .18
collision:
entire packet transmission
time wasted
note:
role of distance & propagation
delay in determining collision
probability
collision:
entire packet transmission
time wasted
note:
role of distance & propagation
delay in determining collision
probability
t=0
t=D- t=D--
D = Propagation delay (A to B) t=D
(determined by Network Size)
t=2D-
• A starts at t=0
• B starts at t=D--
r Transmission time must be as large
• Collision occurs at t=D-
as twice the propagation delay, else
you may finish transmission before • B detects collision at t=D
detecting a potential collision • A detects collision: t= (D) + (D--)
r Why? Consider the scenario above!
Data Link Layer 5-29
Maximum Frame Size (MTU)
Every data link incurs bit error rate
It is the probability that a bit is in error
T
T
1 D
where aº
T 2 DW T 3D 1 3a T
1
1 5a
twisted pair
hub
plug-and-play, self-learning
switches do not need to be configured
A A A’
switch learns which hosts
can be reached through C’ B
which interfaces
1 2
when frame received, 6 3
switch “learns” location of
4
sender: incoming LAN 5
segment
C
records sender/location
pair in switch table B’ A’
example C’ B
frame destination 1 2
unknown: flood A6A’ 3
5 4
destination A location
known: C
A’ A
selective send
B’ A’
S4
S1
S3
A S2
F
D I
B C
G H
E
1 S4
S1 2 S3
A S2
F
D I
B C
G H
E
mail server
to external
network
router web server
IP subnet