computer networks unit-7
TRANSCRIPT
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 1/23
C o n f i d e n t i a l
Course : BCA
Semester : IV
Subject Code : BC 0048
Subject Name : Computer Networks
Unit number : 7
Unit Title : Medium Access Control Sub Layer
HOME NEXT
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 2/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Medium Access Control Sub Layer
Objectives
After going through the presentation, you should be able to:
Describe static and dynamic channel allocations.
Discuss Multiple access protocols
Describe IEEE standards
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 3/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Lecture outline
Introduction
The channel allocation problem
Multiple access protocols
IEEE standards
Summary
NEXTPREVIOUS
Medium Access Control Sub Layer
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 4/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Introduction
The data link layer is overloaded, it is split into MAC and LLC sub layers.
MAC sub-layer is the bottom part of the data link layer.
Medium access control is often used as a synonym to multiple access
protocol, since the MAC sub layer provides the protocol and control
mechanisms that are required for a certain channel access method.
The MAC layer is essentially important in local area networks (LAN¶s),
many of which use a multi-access channel as the basis for
communication. WAN¶s in contrast use a point to point networks.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 5/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
The channel allocation problem
We can classify the channels as static and dynamic.
The static channel is where the number of users are stable and the traffic
is not bursty.
When the number of users using the channel keeps on varying the
channel is considered as a dynamic channel. The traffic on these dynamic
channels also keeps on varying.
Static channels allocation :
The usual way of allocating a single channel among the multiple users is
frequency division multiplexing (FDM). If there are N users, the
bandwidth allocated is split into N equal sized portions.
FDM is simple and efficient technique for small number of users.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 6/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Dynamic channels allocation in LAN¶s and MAN¶s :
When the number of users using the channel keeps on varying the
channel is considered as a dynamic channel.
The traffic on these dynamic channels also keeps on varying. For
example:
In most computer systems, the data traffic is extremely bursty. We see
that in this system, the peak traffic to mean traffic ratios of 1000:1 are
common.
HOME NEXTPREVIOUS
The channel allocation problem
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 7/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
There are many protocolsfor allocating a multiple access channel.
They are
1. Pure or Unslotted Aloha
2. Slotted or Impure ALOHA
3. CSMA Protocol
4. CSMA/CD Protocol
1. Pure or Unslotted Aloha :
The ALOHA network was created at the University of Hawaii in 1970
under the leadership of Norman Abramson.
The Aloha protocol is an OSI layer 2 protocol for LAN networks with
broadcast topology.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 8/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
1. Pure or Unslotted Aloha : ( CONTINUED..)
Figure : Vulnerable period for the node: frame
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 9/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
1.Pure or Unslotted Aloha : ( CONTINUED..)
The Aloha protocol is an OSI layer 2 protocol used for LAN.
A user is assumed to be always in two states: typing or waiting. The
station transmits a frame and checks the channel to see f it was
successful.
If so the user sees the reply and continues to type. If the frame
transmission is not successful, the user waits and retransmits the frame
over and over until it has been successfully sent.
The throughput is
We get for G = 0.5 resulting in a maximum throughput of 0.184, i.e.
18.4%.
HOME NEXTPREVIOUS
GeG P GS
2
0..
!!
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 10/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
2. Slotted or Impure ALOHA :
An improvement to the original Aloha protocol was Slotted Aloha.
It is in 1972, Roberts published a method to double the throughput of an
pure ALOHA by uses discrete timeslots.
His proposal was to divide the time into discrete slots corresponding to
one frame time. This approach requires the users to agree to the frame
boundaries.
To achieve synchronization one special station emits a pip at the start of
each interval similar to a clock. Thus the capacity of slotted ALOHA
increased to the maximum throughput of 36.8%.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 11/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
2. Slotted or Impure ALOHA :( continued«)
In slotted aloha a station can send only at the beginning of a timeslot,
and thus collisions are reduced.
In this case, the average number of aggregate arrivals is G arrivals per
2X seconds. This leverages the lambda parameter to be G. The maximum
throughput is reached for G = 1.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 12/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
3. CSMA Protocol :
Carrier Sense Multiple Access (CSMA) is a probabilistic Media Access
Control(MAC) protocol in which a node verifies the absence of other
traffic before transmitting on a shared physical medium, such as an
electrical bus, or a band of electromagnetic spectrum.
Different CSMA protocols are
1. Non-Persistent CSMA :
Non-persistent CSMA is less greedy. The algorithm is given below:
Sense the channel.
IF the channel is idle, THEN transmit.
If the channel is busy, THEN wait a random amount of time and start
over.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 13/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
3. CSMA Protocol : ( continued..)
2. 1-Persistent CSMA :
1-Persistent CSMA is selfish. The algorithm is given below:
Sense the channel.
IF the channel is idle, THEN transmit.
IF the channel is busy, THEN continue to listen until channel is idle. Nowtransmit immediately.
3. P ± Persistent CSMA :
p ± persistent CSMA is a slotted approximation. The algorithm is given
below:
Sense the channel.
IF the channel is idle, THEN with probability p transmit and with
probability (1-p) delay for one time slot and start over.
IF the channel is busy, THEN delay one time-slot and start over.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 14/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
4. CSMA/CD Protocol :
In computer networking, Carrier Sense Multiple Access with Collision
Detection (CSMA/CD) is a network control protocol in which a carrier
sensing scheme is used.
A transmitting data station that detects another signal while transmitting
a frame, stops transmitting that frame, transmits a jam signal, and then
waits for a random time interval.
The random time interval also known as "backoff delay" is determined
using the truncated binary exponential backoff algorithm. This delay is
used before trying to send that frame again. CSMA/CD is a modification
of pure Carrier Sense Multiple Access (CSMA).
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 15/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Multiple access protocols
4. CSMA/CD Protocol : ( continued..)
Collision detection is used to improve CSMA performance by terminating
transmission as soon as a collision is detected, and reducing the
probability of a second collision on retry.
CSMA/CD can be in anyone of the following three states as shown in
figure.1. Contention period 2. transmission period 3. Idle period
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 16/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
IEEE standards
IEEE has standardized a number of LAN¶s and MAN¶s under the name of
IEEE 802.
Few of the standards are given below
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 17/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
IEEE standards
Ethernets :
Ethernet was originally based on the idea of computers communicatingover a shared coaxial cable acting as a broadcast transmission medium.The methods used show some similarities to radio systems, althoughthere are major differences, such as the fact that it is much easier todetect collisions in a cable broadcast system than a radio broadcast.The common cable providing the communication channel was likened tothe ether and it was from this reference that the name "Ethernet" was
derived.The most kinds of Ethernets used were with the data rate of 10Mbps.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 18/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
IEEE standards
Fast Ethernet :
Fast Ethernet was introduced in 1995 and remained the fastest version of
Ethernet for three years before being superseded by gigabit Ethernet.
Fast Ethernet is a collective term for a number of Ethernet standards that
carry traffic at the nominal rate of 100 Mbit/s, against the original
Ethernet speed of 10 Mbit/s.
Ex :
100BASE-T is any of several Fast Ethernet standards for twisted pair
cables.
100BASE-TX (100 Mbit/s over two-pair Cat5 or better cable),
100BASE-T4 (100 Mbit/s over four-pair Cat3 or better cable, defunct),
100BASE-T2 (100 Mbit/s over two-pair Cat3 or better cable, also
defunct).
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 19/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
IEEE standards
Gigabit Ethernet :Gigabit Ethernet (GbE or 1 GigE) is a term describing various
technologies for transmitting Ethernet packets at a rate of a gigabit per
second, as defined by the IEEE 802.3-2005 standard.
Gigabit Ethernet was the next iteration, increasing the speed to 1000
Mbit/s.
Different gigabits Ethernet are
HOME NEXTPREVIOUS
Name medium
1000BASE-T unshielded twisted pair
1000BASE-SX multi-mode fiber
1000BASE-LX single-mode fiber
1000BASE-CX balanced copper cabling
1000BASE-ZX single-mode fiber
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 20/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
IEEE standards
IEEE 802.3 Frame format :The frame format of IEEE 802.3 is shown below
Preamble field :
Each frame starts with a preamble of 8 bytes. Each containing bit
patterns ³10101010´.
Address field
The frame contains two addresses, one for the destination and for
the sender. The length of address field is 6 bytes.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 21/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
IEEE standards
IEEE 802.3 Frame format : ( continued«)
SOF:
This field is 1 byte long and is used to indicate the start of the frame.
Length:
This field is of 2 bytes long. It is used to specify the length of the data
in terms of bytes that is present in the frame. Data :
The length of this field ranges from zero to a maximum of 1500 bytes.
This is the place where the actual message bits are to be placed.
Pad:
If the data field is less than 46 bytes then the pad field comes into
picture. Such that total data and pad field must be equal to 46bytes
minimum. If the data field is greater than 46 bytes then pad field is not
used.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 22/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
IEEE standards
IEEE 802.3 Frame format : ( continued«)
Checksum:
It is 4 byte long. It uses a 32-bit hash code of the data. If some data
bits are in error, then the checksum will be wrong and the error willbe detected. It uses CRC method and it is used only for error
detection and not forward error correction.
HOME NEXTPREVIOUS
8/7/2019 Computer Networks UNIT-7
http://slidepdf.com/reader/full/computer-networks-unit-7 23/23
C o n f i d e n t i a l
Unit-7 Medium Access Control Sub Layer
Summary
The data link layer split into MAC and LLC sub layers. MAC sub-layer is
the bottom part of the data link layer.
MAC sub layer provides the protocol and control mechanisms that are
required for a certain channel access method.
There are many algorithms for allocating a multiple access channelwhich are Pure or Unslotted Aloha , Slotted or Impure ALOHA ,
CSMA Protocol , CSMA/CD Protocol
There are standards defined for the LAN and MAN called as IEEE 802
standards.
The most important standards are Ethernet, token bus, token ring
Wireless local are network, wireless personal area network, wireless
sensor networks etc.
HOMEPREVIOUS