0% found this document useful (0 votes)
36 views136 pages

G Unit-Iii

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views136 pages

G Unit-Iii

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 136

Medium Access Sub Layer

Unit-III
OSI
Application
Presentation
Session LOGICAL LINK sublayer

Transport Framing
Network Error
control
Data Link
Flow
control
Physical

MEDIA ACCESS sublayer

Transmission/reception
of frames
The Medium Access Sub layer

deals with

BROADCAST NETWORKS AND


THEIR PROTOCOLS

Broadcast channels are sometimes referred to


as multi-access channels or random access
channels.
Topics
 Introduction
 Channel Allocation problem
 Multiple Access Protocols
 IEEE Standard 802 for LANs
 Wireless LAN
 Bridges & its types.
Introduction
 Medium Access Control (MAC) sub layer is
part of Data Link layer.
 In fact, it is the bottom part of DLL
(interfacing with the physical layer)
 This chapter deals with broadcast networks
The Channel Allocation Problem

• Static Channel Allocation in LANs and MANs


• Dynamic Channel Allocation in LANs and MANs
Channel Allocation problem

 Static Channel Allocation in LANs and MANs


 FDM & TDM

 FDM:

1.The traditional way of allocating a single channel, among


multiple competing users is Frequency division
multiplexing(FDM).
2. If there are N users, the bandwidth is divided into N equal-
sized portions, each user being assigned one portion.
3. Here each user has a private frequency band, there is no
interference between users.
4.When there is only a small and constant number of users, each
of which has heavy load of traffic, FDM is simple and
efficient.
5. When number of senders is large and continuously varying,
FDM presents few problems.
6.If spectrum is cut up into N regions and <N users are interested
in communication, the spectrum is wasted.
7.If more than N users want to communicate, some of them will
be denied permission for lack of bandwidth.
8. Assuming that the number of users be held constant at N,
dividing the channel into sub-channels is inefficient.
9.The basic problem is, when some users are quiet their
bandwidth is simply lost. They are not using it, and no one else
is allowed to use it either.
Performance of static FDM from a simple queueing theory is as
follows:
• Assume that the mean time delay, T, for a channel of capacity
C bps, with an arrival rate of λ frames/sec, each frame having
a length from an exponential probability density function with
1/μ bits/frame.
• With these, the arrival rate is λ frames/sec and the service rate
is μC frames/sec.
• From queueing theory it can be shown that for Poisson arrival
and service times,

T= 1
μC - λ
• Now let us divide the single channel into N independent sub-
channels, each with capacity C/N bps. The mean input rate on
each sub-channels will be λ/N.
• Recomputing T we get
TFDM = 1
μ(C/N)-(λ /N)

= N
μC – λ
= NT
The mean delay using FDM is N times worse than if all the
frames were somehow magically arranged orederly in a big
central queue.
TDM:
• The same arguments that apply to FDM also apply to
TDM.
• Each user is statically allocated every Nth time slot. If
a user does not use the allocated slot, it just lies
fallow.
• The same holds if we split up the network physically.

Note: None of the traditional static channel allocation


methods work well with bursty traffic.
Dynamic Channel Allocation in LANs and MANs

 Station Model.

 Single Channel Assumption.

 Collision Assumption.

 (a) Continuous Time.


(b) Slotted Time.

 (a) Carrier Sense.(LAN)


(b) No Carrier Sense.(SATELLITE)
1.Station Model:
• The model consists of N independent Stations, each
with a program or user that generates frames for
transmission. Stations are called Terminals.
• The probability of a frame being generated in an
interval of length Δt is λΔt, where λ is a
constant(arrival rate of new frames).
• Once a frame is generated the station is blocked and
does nothing until the frame has been successfully
transmitted.
2. Single Channel Assumption:
• A single channel is available for all communication.
• All stations can transmit on it and all can receive from it.
3. Collision Assumption:
• If two frames are transmitted simultaneously, they overlap in
time and the resulting signal is garbled. This event is called a
Collision.
• All stations can detect collisions.
• A collided frame must be transmitted again later.
4a. Continuous Time:

• Frame transmission can begin at any instant.


• There is no master clock dividing time into discrete intervals.

4b.Slotted Time:

• Time is divided into slots. Frame transmission always begins


at the start of a slot.
• A slot can have 0,1, or more frames, corresponding to an idle
slot, a successful transmission, or a collision respectively.
5a. Carrier Sense:
• Stations can tell if the channel is in use before trying to use it.
• If the channel is sensed as a busy, no station will attempt to
use it until it goes idle.
5b. No Carrier Sense:
• Stations cannot sense the channel before trying to use it.
• They just go ahead and transmit. Only later can they determine
whether the transmission was successful.
Multiple Access Protocols

• ALOHA
• Carrier Sense Multiple Access Protocols
• Collision-Free Protocols
• Limited-Contention Protocols
• Wavelength Division Multiple Access Protocols
• Wireless LAN Protocols
Medium Access Sub Layer
ALOHA

Aloha
 Pure ALOHA (Mr. Norman Abramson in 1970s)

 Slotted ALOHA (Mr.Roberts in 1972)

ALOHA system used to ground based radio broadcasting.


Pure ALOHA
 Users transmit whenever they have data to be sent.

Fig. In pure ALOHA, frames are transmitted at


completely arbitrary times
• Systems in which multiple users share a common channel in a
way that can lead to conflicts are widely known as contention
system.
• The frame size is fixed because the throughput of ALOHA
systems is maximized.
•We need to resend the frames that have been destroyed during
transmission.
•A collision involves two or more stations. If all these try to
resend their frames after the time-out, the frames will collide
again.
•Pure ALOHA states that when the time-out period passes, each
station waits a random amount of time before resending its
frame(TB).
• Pure ALOHA has a second method to prevent congesting the
channel with retransmitted frames. After a maximum no.of
retransmission attempts Kmax, a station must give up and try
later.
• The time-out period is equal to maximum possible round-trip
propagation delay, which is twice the amount of the time
required to send a frame between the two most widely
separated stations(2 * Tp ).
• The back-off time TB is a random value that depends on K.
(binary exponential back-off )
Pure ALOHA

 Whenever two frames try to occupy the channel at the


same time, there will be a collision and both will be
garbled.
 If the first bit of the new frame overlaps with the last
bit of a frame almost finished , both frames will be
totally destroyed, and both will be retransmitted later.
 Throughput for pure ALOHA decreases.
Pure ALOHA

Disadvantage
 More number of users share common channels in a
way that can lead to conflicts.
 More number of collisions occur.
 Collision detected: stations waits a random amount
of time.
Issues with pure aloha
 Contention, collision detection, retransmission
 Vulnerable period for a frame
 If G is the mean number of transmission
attempts (old and new) per frame time (offered
load), S is the throughput per frame time, then
S = Ge-2G for pure ALOHA.
 Maximum throughput occurs at G = 0.5 with
S=1/(2e)=0.1839. I.e., maximum channel
utilization is 18 percent.
• In other words, if one-half a frame is generated during one
frame transmission time, then 18.4 percent of these frames
reach their destination successfully.
• This is an expected results because the vulnerable time is 2
times the frame transmission time.
• Therefore, if a station generates only one frame in this
vulnerable time, the frame will reach its destination
successfully.
Pure ALOHA

Fig. Throughput versus offered traffic for ALOHA


systems
Slotted aloha
 Slotted ALOHA: Divide the time into discrete
intervals(slots) of Tfr s, and force the station to send only
at the beginning of the time slot..
 Obviously, there may be a special signal needed to
synchronize the clocks at all stations.
 Because a station is allowed to send only at the beginning
of synchronized time slot, if a station misses this, it must
wait until the beginning of next time slot.
 This means that the station which started at the beginning
of this slot has already finished sending its frame.
 Ofcourse, there is still the possibility of collision if two
stations try to send at the beginning of the same slot.
 However, the vulnerable time is now reduced to one-half,
equal to Tfr.
 It can be proved that the average number of successful
transmission for the slotted ALOHA is S=G * e-G
 Maximum throughput occurs at G=1, S=1/e or 0.368. This is
twice that of pure ALOHA protocol.
 In other words, if a frame is generated during one frame
transmission time, then 36.8 % of these frames reach their
destination successfully. This result is expected because
vulnerable time is equal to the frame transmission time.
 Therefore, if a station generates only one frame in this
vulnerable time(and no other station generates a frame duing
this time), the frame will be reach its destination successfully.
Slotted ALOHA

Divides the time into discrete intervals

A B C D E

Disadvantage: collisions
Throughput for slotted ALOHA increases.
Differences Between Pure ALOHA and Slotted
ALOHA

• Transmission
• In Pure ALOHA when a frame first arrives, the node
immediately transmits the frame in its entirely into the
Broadcast Channel.
• In Slotted ALOHA when a node has a fresh frame to
send, it waits until the beginning of the next slot and
transmits the entire frame in the slot.
• Timing
• In Pure ALOHA Nodes can transmit frames at Random
Times.
• In Slotted ALOHA Nodes can transmit frames in their
respective slot boundaries only at the beginning of the
Slot.
Differences Between Pure ALOHA and Slotted
ALOHA

 Synchronization
 Pure ALOHA does not require Synchronization of
slots of any nodes.
 Slotted ALOHA requires synchronization between
slots of nodes.
 Mode of Transfer
 In Pure ALOHA the Mode of Transfer is
Continuous.
 In Slotted ALOHA the mode of transfer is Discrete
Differences Between Pure ALOHA and Slotted
ALOHA
 Collission
 In Pure ALOHA If a Collision Occurs the nodes will then

immediately retransmit the frame with probability P or the


frame transmission time for retransmitting the frame.
 In Slotted ALOHA, if a collision occurs, the node detects

the collision before the end of the slot the node retransmits
its frame in each subsequent slot with probability P until
the frame transmitted without a collision.
 Efficiency
 In Pure ALOHA Efficiency is Half of Slotted ALOHA.

 In Slotted ALOHA efficiency is more than that of Pure

ALOHA.
CSMA: Carrier Sense Multiple Access

 Protocols in which stations listen for a carrier (i.e.,


transmission) and act accordingly are called carrier sense
protocols.
Adv:
 To minimize the chance of collision
 Increases the performance.

 CSMA principle is “sense before transmit” or “listen before


talk”.
CSMA Methods

 1-persistent CSMA- constant length packets.


 non-persistent CSMA- to sense the channel.
 p-persistent CSMA
1-persistent
 When a station has data to send, it first listens to channel to see if
any one else is transmitting at that moment.
 If the channel is busy, the station continuously senses the channel
until it becomes idle.
 When the station detects an idle channel, it transmits a frame.
 If a collision occurs, the station waits a random amount of time
and starts all over again.
 The station transmits with a probability of 1 whenever if finds the
channel idle.
 This method has highest chance of collision because two or more
stations may find the line idle and send their frames immediately.
Non-persistent CSMA
 A station that has a frame to send it senses the line.
 If the line is idle, it sends immediately.
 If the line is not idle, it waits a random amount of time and then
senses the line again.
 This approach reduces the chance of collision because it is
unlikely that two or more stations will wait the same amount of
time and retry to send simultaneously.
 This algorithm should lead to better channel utilization and
longer delays than 1-persistant CSMA.
P-persistent CSMA

 This method is used if the channel has time slots with a slot
duration equal to or greater than the maximum propogation
time.
 It combines advantages of the other two strategies.
 It reduces the chance of collision and improves efficiency.
P-persistent CSMA

 In this method, after station finds the line idle it follows these
steps:
1.With probability ‘p’, the station sends its frame.
2.With probability q=p-1, the station waits for the beginning of the
next time slot and checks the line again.
a. If the line is idle, it goes to step 1.
b. If the line is busy, it acts as though a collision has occurred
and uses the back-off procedure(which discussed earlier).
Persistent and Nonpersistent CSMA

Comparison of the channel utilization versus


load for various random access protocols.
Carrier Sense Multiple Access with
Collision Detection(CSMA/CD)
• In this method, a station monitors the medium after it sends a
frame to see if the transmission was successful. If so, the
station is finished. If, however, there is a collision, the frame is
sent again.
Minimum Frame Size
For CSMA/CD to work, we need restriction on the
frame size.
Therefore, the frame transmission time Tfr must be at
least two times the maximum propagation time Tp.
To understand the reason, let us think about worst-case
scenario. If two stations involved in a collision are
the maximum distance apart, the signal from the first
takes Tp to reach the second, and the effect of the
collision takes another Tp to reach the first.
So the requirement is that the first station must still be
transmitting after 2Tp
Wired LANs: Ethernet

1. IEEE Standards
2. Standard Ethernet
3. Changes in the Standard
4. Fast Ethernet
5. Gigabit Ethernet

Data Communications, Kwangwoon 13-50


University
IEEE Standards
• In 1985, the Computer Society of the IEEE started a project, called
Project 802, to set standards to enable intercommunication among
equipment from a variety of manufacturers. Project 802 is a way of
specifying functions of the physical layer and the data link layer of
major LAN protocols.

Data Communications, Kwangwoon 13-51


University
IEEE 802 Working Group
Active working groups Inactive or disbanded working groups
802.1 Higher Layer LAN Protocols Working 802.2 Logical Link Control Working Group
Group 802.4 Token Bus Working Group
802.3 Ethernet Working Group 802.5 Token Ring Working Group
802.11 Wireless LAN Working Group 802.7 Broadband Area Network Working
802.15 Wireless Personal Area Network Group
(WPAN) Working Group 802.8 Fiber Optic TAG
802.16 Broadband Wireless Access Working 802.9 Integrated Service LAN Working
Group Group
802.17 Resilient Packet Ring Working Group 802.10 Security Working Group
802.18 Radio Regulatory TAG 802.12 Demand Priority Working Group
802.19 Coexistence TAG 802.14 Cable Modem Working Group
802.20 Mobile Broadband Wireless Access
(MBWA) Working Group
802.21 Media Independent Handoff Working
Group
802.22 Wireless Regional Area Networks

Data Communications, Kwangwoon 13-52


University
Logical Link Control (LLC)
• Framing: LLC defines a protocol data unit (PDU) that is similar to
that of HDLC
• To provide flow and error control for the upper-layer protocols that
actually demand these services.
• It provides one single data link control protocol for all IEEE LANs.

Data Communications, Kwangwoon 13-53


University
Medium Access Control(MAC)
• IEEE Project 802 has created a sub-layer called MAC that
defines specific access methods for each LAN.
• In contrast to LLC sub-layer, the MAC sub layer contains a
number of distinct modules; each defines the access method
and the framing format specific to the LAN protocol.

Physical layer
• The physical layer is dependent on the implementation and the
type of physical media used.

Data Communications, Kwangwoon 13-54


University
Standard Ethernet
• The original Ethernet was created in 1976 at Xerox’s Palo Alto
Research Center (PARC). Since then, it has gone through four
generations

Data Communications, Kwangwoon 13-55


University
MAC Sublayer
• Preamble: Alternate 0’s and 1’s that alerts the receiving system to
the coming frame and enables it to synchronize its input timing.

Data Communications, Kwangwoon 13-56


University
Addressing

• Ethernet address in hexadecimal notation

• The least significant bit of the first byte defines the type of address.
If the bit is 0, the address is unicast; otherwise, it is multicast
• The broadcast destination address is a special case of the multicast
address in which all bits are 1s

Data Communications, Kwangwoon 13-57


University
Ethernet
Slot time:
• Access method: 1-persistent CSMA/CD
• Slot time = round-trip time + time required to send the jam sequence.
• The slot in Ethernet is defined in bits. It is time required for a station
to send 512 bits. This means that the actual slot time depends on the
data rate: for traditional 10-Mbps Ethernet it is 51.2 μs

Slot time and collision:


• The choice of a 512-bit slot time was not accidental.
• It was chosen for the proper functioning of CSMA/CD.
• To understand it, let us consider two cases.
Case-1:
• We assume that the sender sends a minimum-size packet of 512 bits.
• Before the sender can send the entire packet out, the signal travels
through the network and reaches the end of the network.

Data Communications, Kwangwoon 13-58


University
Minimum frame length: 64 bytes
• If there is another signal at the end of the network, a collision occurs. The
sender has opportunity to abort the sending of the frame and to send a jam
sequence to inform other stations of the collision.
• (The round-trip time + the time required to send the jam sequence ) < the
time needed to send the minimum frame, 512 bits.(the sender need to be
aware of the collision before it is too late, that is, before it has sent the
entire frame).
Case-2:
Assume that the sender sends a frame larger than the minimum size.
• In this case, if station has sent out the first 512 bits and has not heard a
collision, it is guaranteed that the collision will never occur during the
transmission of this frame. The reason is that the signal will reach the end
of the network in less than one-half the slot time.
• If they sent a signal before one-half of the slot time expired, a collision can
occur during the first half of the slot time, and if it does, it can be sensed by
sender during the slot time.
Collisions
Collisions are caused when two adaptors transmit at the same
time (adaptors sense collision based on voltage differences)
• Both found line to be idle
• Both had been waiting to for a busy line to become idle

A starts at A B
time 0
Message almost
A B
there at time T when
B starts – collision!

How can we be sure A knows about the collision?


Collision Detection
 How can A know that a collision has taken place?
• There must be a mechanism to insure retransmission on collision

• A’s message reaches B at time T

• B’s message reaches A at time 2T

• So, A must still be transmitting at 2T

 IEEE 802.3 specifies max value of 2T to be 51.2us


• This relates to maximum distance of 2500m between hosts

• At 10Mbps it takes 0.1us to transmit one bit so 512 bits (64B) take
51.2us to send
• So, Ethernet frames must be at least 64B long

 14B header, 46B data, 4B CRC


 Padding is used if data is less than 46B
 Send jamming signal after collision is detected to insure all hosts
see collision
• 48 bit signal
Collision Detection contd.
A B
time = 0

A B

time = T

A B

time = 2T
• Slot time and maximum network length
• MaxLength = PropagationSpeed x SlotTime/2
• MaxLength = (2 x 108) x (51.2 x 10-6/2) = 5120 m
• MaxLength = 2500 m 48 % of the theoretical calculation by
considering delay times in repeaters and interfaces, and the time
required to send the jam sequence
Physical Layer: Ethernet

Data Communications, Kwangwoon 13-65


University
10Base5: Thick Ethernet

10Base2: Thin Ethernet

Data Communications, Kwangwoon 13-66


University
10BaseT: Twisted-Pair Ethernet

10Base-F: Fiber Ethernet

Data Communications, Kwangwoon 13-67


University
Summary of Standard Ethernet

Data Communications, Kwangwoon 13-68


University
Changes in the Standard
• Bridged Ethernet: Raising bandwidth and separating collision
domains

Data Communications, Kwangwoon 13-69


University
Changes in the Standard
• Switched Ethernet: N-port bridge

Data Communications, Kwangwoon 13-70


University
Changes in the Standard
• Full-duplex (switched) Ethernet: no need for CSMA/CD

Data Communications, Kwangwoon 13-71


University
Fast Ethernet
• Under the name of IEEE 802.3u
• Upgrade the data rate to 100 Mbps
• Make it compatible with Standard Ethernet
• Keep the same 48-bit address and the same frame format
• Keep the same min. and max. frame length

• MAC Sublayer
• CSMA/CD for the half-duplex approach
• No need for CSMA/CD for full-duplex Fast Ethernet

• Autonegotiation: allow two devices to negotiate the mode or data rate


of operation

Data Communications, Kwangwoon 13-72


University
Fast Ethernet: Physical Layer
• Topology

• Implementation

Data Communications, Kwangwoon 13-73


University
Summary of Fast Ethernet

Data Communications, Kwangwoon 13-74


University
Gigabit Ethernet
• Under the name of IEEE 802.3z
• Upgrade the data rate to 1 Gbps
• Make it compatible with Standard or Fast Ethernet
• Keep the same 48-bit address and the same frame format
• Keep the same min. and max. frame length
• Support autonegotiation as defined in Fast Ethernet
• MAC Sublayer
• Most of all implmentations follows full-duplex approach
• In the full-duplex mode of Gigabit Ethernet, there is no collision;
the maximum length of the cable is determined by the signal
attenuation in the cable.
• Half-duplex mode (very rare)
• Traditional: 0.512 μs (25m)
• Carrier Extension: 512 bytes (4096 bits) min. length
• Frame bursting to improve the inefficiency of carrier extension
Data Communications, Kwangwoon 13-75
University
Gigabit Ethernet: Physical Layer
• Topology

Data Communications, Kwangwoon 13-76


University
Gigabit Ethernet: Physical Layer
• Implementation

Data Communications, Kwangwoon 13-77


University
Gigabit Ethernet: Summary

Data Communications, Kwangwoon 13-78


University
Ten-Gigabit Ethernet
• Under the name of IEEE 802.3ae
• Upgrade the data rate to 10 Gbps
• Make it compatible with Standard, Fast, and Giga Ethernet
• Keep the same 48-bit address and the same frame format
• Keep the same min. and max. frame length
• Allow the interconnection of existing LANs into a MAN or WAN
• Make Ethernet compatible with Frame Relay and ATM

• MAC Sublayer: Only in full-duplex mode  no CSMA/CD

Data Communications, Kwangwoon 13-79


University
Wireless
Local Area Networks
Wireless Local Area Networks

• The proliferation of laptop computers and


other mobile devices (PDAs and cell phones)
created an obvious application level demand
for wireless local area networking.
• Companies jumped in, quickly developing
incompatible wireless products in the 1990’s.
• Industry decided to entrust standardization to
IEEE committee that dealt with wired LANS –
namely, the IEEE 802 committee!!
IEEE 802 Standards Working Groups

Figure 1-38. The important ones are marked with *. The ones marked with 
are hibernating. The one marked with † gave up.
Categories of Wireless Networks

• Base Station :: all communication through


an access point {note hub topology}. Other
nodes can be fixed or mobile.
• Infrastructure Wireless :: base station
network is connected to the wired Internet.
• Ad hoc Wireless :: wireless nodes
communicate directly with one another.
• MANETs (Mobile Ad Hoc Networks) :: ad
hoc nodes are mobile.
Wireless LANs

Figure 1-36.(a) Wireless networking with a base station. (b) Ad hoc


networking.
The 802.11 Protocol Stack

Figure 4-25. Part of the 802.11 protocol stack.


Wireless Physical Layer
• Physical layer conforms to OSI (five options)
– 1997: 802.11 infrared, FHSS, DHSS
– 1999: 802.11a OFDM and 802.11b HR-DSSS
– 2001: 802.11g OFDM
• 802.11 Infrared
– Two capacities 1 Mbps or 2 Mbps.
– Range is 10 to 20 meters and cannot penetrate walls.
– Does not work outdoors.
• 802.11 FHSS (Frequence Hopping Spread Spectrum)
– The main issue is multipath fading.
– 79 non-overlapping channels, each 1 Mhz wide at low end of 2.4
GHz ISM band.
– Same pseudo-random number generator used by all stations.
– Dwell time: min. time on channel before hopping (400msec).
Wireless Physical Layer
• 802.11 DSSS (Direct Sequence Spread Spectrum)
– Spreads signal over entire spectrum using pseudo-random
sequence (similar to CDMA see Tanenbaum sec. 2.6.2).
– Each bit transmitted using an 11 chips Barker sequence, PSK at
1Mbaud.
– 1 or 2 Mbps.
• 802.11a OFDM (Orthogonal Frequency Divisional
Multiplexing)
– Compatible with European HiperLan2.
– 54Mbps in wider 5.5 GHz band  transmission range is limited.
– Uses 52 FDM channels (48 for data; 4 for synchronization).
– Encoding is complex ( PSM up to 18 Mbps and QAM above this
capacity).
– E.g., at 54Mbps 216 data bits encoded into into 288-bit symbols.
– More difficulty penetrating walls.
Wireless Physical Layer

• 802.11b HR-DSSS (High Rate Direct


Sequence Spread Spectrum)
– 11a and 11b shows a split in the standards
committee.
– 11b approved and hit the market before 11a.
– Up to 11 Mbps in 2.4 GHz band using 11 million
chips/sec.
– Note in this bandwidth all these protocols have to deal
with interference from microwave ovens, cordless
phones and garage door openers.
– Range is 7 times greater than 11a.
Wireless Physical Layer

• 802.11g OFDM(Orthogonal Frequency


Division Multiplexing)
– An attempt to combine the best of both 802.11a
and 802.11b.
– Supports bandwidths up to 54 MBps.
– Uses 2.4 GHz frequency for greater range.
– Is backward compatible with 802.11b.
802.11 MAC Sublayer Protocol

• In 802.11 wireless LANs, “seizing channel” does


not exist as in 802.3 wired Ethernet.
• Two additional problems:
– Hidden Terminal Problem
– Exposed Station Problem
• To deal with these two problems 802.11
supports two modes of operation DCF
(Distributed Coordination Function) and PCF
(Point Coordination Function).
• All implementations must support DCF, but
PCF is optional.
Figure 4-26.(a)The hidden station problem. (b) The exposed station problem.
The Hidden Terminal Problem

• Wireless stations have transmission ranges


and not all stations are within radio range of
each other.
• Simple CSMA will not work!
• C transmits to B.
• If A “senses” the channel, it will not hear C’s
transmission and falsely conclude that A can
begin a transmission to B.
The Exposed Station Problem

• This is the inverse problem.


• B wants to send to C and listens to the
channel.
• When B hears A’s transmission, B falsely
assumes that it cannot send to C.
Distribute Coordination Function (DCF)

• Uses CSMA/ CA (CSMA with Collision


Avoidance).
– Uses both physical and virtual carrier sensing.
– Two methods are supported:
1. based on MACAW(Multiple Access with
Collision Avoidance for Wireless) with
virtual carrier sensing.
2. 1-persistent physical carrier sensing.
Wireless LAN Protocols

• MACA protocol solved hidden, exposed terminal:


– Send Ready-to-Send (RTS) and Clear-to-Send (CTS)
first
– RTS, CTS helps determine who else is in range or
busy (Collision avoidance).
– Can a collision still occur?
Wireless LAN Protocols

• MACAW added ACKs and CSMA (no RTS at same


time)

(a) A sending an RTS to B.(b) B responding with a CTS to A.


Virtual Channel Sensing in CSMA/CA

Figure 4-27. The use of virtual channel sensing using CSMA/CA.


• C (in range of A) receives the RTS and based on information in
RTS creates a virtual channel busy NAV(Network Allocation
Vector).
• D (in range of B) receives the CTS and creates a shorter NAV.
Virtual Channel Sensing in CSMA/CA

What is the advantage of RTS/CTS?


RTS is 20 bytes, and CTS is 14 bytes.
MPDU can be 2300 bytes.
• “virtual” implies source station sets duration
field in data frame or in RTS and CTS
frames.
• Stations then adjust their NAV accordingly!
Figure 4-28.Fragmentation in 802.11

• High wireless error rates  long packets have


less probability of being successfully transmitted.
• Solution: MAC layer fragmentation with stop-and-
wait protocol on the fragments.
1-Persistent Physical Carrier Sensing

• Station senses the channel when it wants to


send.
• If idle, station transmits.
– Station does not sense channel while transmitting.
• If the channel is busy, station defers until idle
and then transmits.
• Upon collision, wait a random time using binary
exponential backoff.
Point Coordinated Function (PCF)

• PCF uses a base station to poll other stations


to see if they have frames to send.
• No collisions occur.
• Base station sends beacon frame
periodically.
• Base station can tell another station to sleep
to save on batteries and base stations holds
frames for sleeping station.
DCF and PCF Co-Existence

• Distributed and centralized control can co-exist


using InterFrame Spacing.
• SIFS (Short IFS) :: is the time waited between
packets in an ongoing dialog (RTS,CTS,data,
ACK, next frame)
• PIFS (PCF IFS) :: when no SIFS response, base
station can issue beacon or poll.
• DIFS (DCF IFS) :: when no PIFS, any station
can attempt to acquire the channel.
• EIFS (Extended IFS) :: lowest priority interval
used to report bad or unknown frame.
Figure 4-29. Inter-frame Spacing in 802.11.
802.11 Frame Structure
• Frame Control: It contains 11 sub fields.
1. Version: which allows two version of protocol to
operate at same time in a same cell
2. Type: It can be data , control or management.
3. Sub type: RTS or CTS.
4. To DS & From DS: These bits indicates the
frame is going to or coming from the inter cell
distribution system(e.g Ethernet)
5. MF: more fragments will follow
6. Retry: marks a retransmission of a frame sent
earlier
8.Power management: It is used by station to
put ‘r’ into sleep & take it out of sleep.
9.More: ‘s’ has additional frames for ‘r’
10. W: Frame body has encrypted using
WEP(Wired Equivalent Privacy)
11.O: It tells ‘r’ that sequence of frames with
this bit “on” must be processed strictly in
order.
• Duration:
It tells how long the frame & its ack will occupy
the channel.
Address1 to 4:
Source & destination are obviously needed, the
other 2 addresses are used for source &
destination base stations for intercell
traffic(i.e frames may enter or leave a cell via
BS)
Sequence: allows fragments to be numbered.
Out of 16 bits,12 identify frame, 4 identify
fragment
• Data field contains payload upto 2312 bytes
followed by checksum.
• Management frames have same format as
that of data frames, except without one of BS
addresses because management frames are
restricted to single cell.
• Control fields will have only one or two
addresses, no data field, no sequence field.
The key information is in sub-type field,
usually RTS, CTS, or ACK.
Services of 802.11
• The five distribution services are provided by the Base station
and deals with station mobility as ther enter and leave cells.
• They are:
1.Association:
• This is used by MS to connect themselves to BS.
 When MS moves within the radio range of BS, it announces
it’s identity and capabilities(data rates supported, need for
PCF service, power management requirements).
 The BS may accept or reject the MS. If the MS is accepted, it
must then authenticate itself.
2. Disassociation:
 Either the station or BS may disassociate, thus breaking the
relationship.
 A station should use this service before shutting down or
leaving, but the BS may also use it before going down for
maintenance.
3. Reassociation:
A station may change its preferred BS using this service.
This facility is useful for MSs moving from one cell to another
• The remaining four services are intracell.

Authentication
Deauthentication
Privacy
Data Delivery
Bridges
 Means to interconnect individual LANs
 Operate at the data link layer

 Reasons for bridges:

(1)autonomous divisions (2) different buildings


(3) logical grouping (4) physical distance (5)
Reliability (6) Security( due to Promiscuous
mode)
 Issues in bridging different LANs:

(i) Different frame format (ii) different data


rates (iii) Timers at higher layers (iv) different
maximum frame lengths
Bridges

 Multiple LANS can be connected by devices called


bridges.
 If a bridge is added or detected from the system,
reconfiguration of the stations is unnecessary(It
means that bridges should be fully transparent).
Bridges

Bridge
A
C
LANs can be connected by devices called bridges, which operate
in the data link layer. Bridges do not examine the network layer
header.
Bridges

Router
A
C

Router
In contrast, a router examines network layer headers.
Why a single organization may end up with multiple LANs? (to
need bridges)

1. Autonomy of departments to choose their own types of LANs


2. Cheaper to have separate LANs than to run a single large LANs
3. Load splitting
4. Physical distance is too great. (For example, >2.5km in 802.3)
5. More reliable
6. More secure
Fig. Multiple LANs connected by a backbone to handle a total load
higher than the capacity of a single LAN.
Bridges
 802.x802.3: Destination LAN heavily
loaded
 802.4802.3: Priority vs no priority; ACK bit;
 Similar problems for others
Operation of a LAN bridge from 802.11 to 802.3.
Bridges from 802.x to 802.y

You might naively think that a bridge from 802 LAN to


another one would be completely trivial. Such is not the case.
Each of the nine combinations of 802.x to 802.y has its own
unique set of problems.
General problems:
1. Different frame format
2. Different data rate
3. Different maximum frame length
Bridges from 802.x to 802.y
TRANSPARENT BRIDGES

 When a frame arrives, a bridge must decide whether to discard or forward


it.
 Each bridge contains hash tables specifying that destination address.
 The table can list each possible destination and tell which output line it
belongs on.
 When the bridges are first plugged in. all the hash tables are empty.
 Few days back they are using flooding algorithm for bridges.
 Every incoming frame for an unknown destination is output on all the LANs
to which the bridge is connected except the one it arrived on.
 The algorithm used by the transparent bridges is Backward-learning ,based
on source address bridges can tell which machine is accessible on which
LAN.
 3 rules for forwarding the frame.
 If destination and source LANs are the same discard
the frame.
 If destination and source LANs are different , forward
the frame.
 If the destination LAN is unknown, use flooding.
Transparent Bridges

Plug and play bridge

When a frame arrives, a bridge must decide whether to discard


or forward it, and if the latter, on which LAN to put the frame.
The decision is made by looking up the destination address in a
big (hash) table inside the bridge.
Two parallel transparent bridges
SPANNING TREE BRIDGES

 (a) Interconnected LANs. (b) A spanning tree covering the


LANs. The dotted lines are not part of the spanning tree.
Spanning Tree Bridges

To build the spanning tree, first the bridges have to choose one
bridge to be the root of the tree. They make this choice by
having each one broadcast its serial number, installed by the
manufacturer, and guaranteed to be unique worldwide. The
bridge with the lowest serial number becomes the root. Next, a
tree of shortest paths from the root to every bridge and LAN is
constructed.
Source Routing Bridges
 CSMA/CD and token bus accepted transparent
bridges
 The token ring community went for source routing
bridges
 Here, the source determines the path that a
message should take
 When a destination is unknown, the source
issues a discovery frame which is forwarded to
every LAN on the internetwork. When the reply
comes back, the bridges record their identity in it,
so the original sender can know the path.
 Comparison bridges: See pages 316-317
A source routing bridge is only interested in those frames with
the high-order bit of the destination set to 1.

For each such frame, it scans the route looking for the number
of the LAN on which the frame arrived.

If this LAN number is followed by its own bridge number, the


bridge forwards the frame onto the LAN whose number
follows its bridge number in the route.
Source routing assumes that the sender of each frame knows
whether or not the destination is on its own LAN. When
sending a frame to a different LAN, the source machine sets
the high-order bit of the source address to 1, to mark it.
Furthermore, it includes in the frame header the exact path
that the frame will follow.
Three possible implementations:
1. Software: the bridge runs in promiscuous mode, copying all
frames to its memory to see if they have the high-order
destination bit set to 1. If so, the frame is inspected further.

2. Hybrid: the bridge’s LAN interface inspects the high-order


destination bit and only accepts frame with the bit set. This
interface is easy to build into hardware and greatly reduces the
number of frames the bridge must inspect.
3. Hardware: the bridge’s LAN interface not only checks the
high-order destination bit, but it also scans the route to see if this
bridge must do forwarding. Only frames that must actually be
forwarded are given to the bridge. This implementation requires
the most complex hardware but wastes no bridge CPU cycles
because all irrelevant frames are screened out.
Implicit in the design of source routing bridge is that every
machine in the internetwork knows, or can find, the best path to
every other machine. How these routes are discovered is an
important part of the source routing bridge.

The basic idea is that if a destination is unknown, the source


issues a broadcast frame asking where it is. This discovery frame
is forwarded by every bridge so that it reaches every LAN on the
internetwork. When the reply comes back, the bridges record
their identity in it, so that the original sender can see the exact
route taken and ultimately choose the best route.
4.4.4 Comparison of 802 Bridges
Remote Bridges
 Used when individual LANs are far apart
 In this case bridges on each LAN are
connected via point-to-point links
Remote Bridges

Point to point protocol used between bridges:


1. Choose some standard point-to-point protocol, putting complete
MAC frames in the payload field (best if all LANs are identical)
2. Strip off the MAC header at source bridge, put back at destination
(can not catch errors caused by bad bridge memory)

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy