You are on page 1of 68

Network Management

and Application
Notes By : Bijay Mishra
Static Channel Allocation
Problem
The history of broadcast networks includes satellite
and packet radio networks.

Let us view a satellite as a repeater amplifying and
rebroadcasting everything that comes in.

To generalize this problem, consider networks
where every frame sent is automatically received
by every site (node).
Satellite Channel
= f
in

= f
out

Static Channel Allocation Problem
We model this situation as n independent
users (one per node), each wanting to
communicate with another user and they
have no other form of communication.
Channel Allocation Problem

To manage a single broadcast channel which must be shared
efficiently and fairly among n uncoordinated users.

Possible Model Assumptions for
Channel Allocation Problem

0. Listen property :: (applies to satellites)
The sender is able to listen to sent frame one
round-trip after sending it.
no need for explicit ACKs
1. Model consists of n independent stations.
2. A single channel is available for communications.
Possible Model Assumptions for
Channel Allocation Problem
3. Collision Assumption :: If two frames are transmitted
simultaneously, they overlap in time and the
resulting signal is garbled. This event is a collision.
4a. Continuous Time Assumption :: frame transmissions
can begin at any time instant.
4b. Slotted Time Assumption :: time is divided into
discrete intervals (slots). Frame transmissions
always begin at the start of a time slot.

Possible Model Assumptions for
Channel Allocation Problem
5a. Carrier Sense Assumption ::
Stations can tell if the channel is busy (in use) before trying
to use it. If the channel is busy, no station will attempt to
use the channel until it is idle.

5b. No Carrier Sense Assumption ::
Stations are unable to sense channel before
attempting to send a frame. They just go ahead and
transmit a frame.
ALOHA
Abramson solved the channel allocation problem for
ground radio at University of Hawaii in 1970s.
Aloha Transmission Strategy

Stations transmit whenever they have data to send.
Collisions will occur and colliding frames are
destroyed.
Aloha Retransmission Strategy

Station waits a random amount of time before sending again.
Pure ALOHA
Figure: Vulnerable period for the shaded frame.
t
t
0
t
0
-X t
0
+X
t
0
+X+2t
prop

t
0
+X+2t
prop
+B
Vulnerable
period
Time-out
Backoff
period
Retransmission
if necessary
First transmission Retransmission
random backoff period B
ALOHA
ALOHA
S = G e
-2 (1+a) G

Vulnerable period :: t
0
X to t
0
+ X two frame transmission times
Assume: Poisson Arrivals with average number of arrivals of 2G arrivals/ 2 X
Slotted ALOHA (Roberts 1972)
uses discrete time intervals as slots (i.e., slot = one
packet transmission time) and synchronize send
time (e.g., use pip from a satellite).
Slotted Aloha Strategy

Station transmits ONLY at the beginning of a time slot.
Collisions will occur and colliding frames are
destroyed.
Slotted Aloha Retransmission Strategy

Station waits a random amount of time before sending again.
t
(k+1)X
kX
t
0
+X+2t
prop
+B
t
0
+X+2t
prop

Vulnerable
period
Time-out
Backoff
period
Retransmission
if necessary
Slotted ALOHA
random backoff period B slots
Slotted ALOHA
S = G e
- (1+a) G

Vulnerable period :: t
0
X to t
0
one frame transmission time
Assume: Poisson Arrivals with average number of arrivals of
G arrivals/ X
P
0
= P[k=0, t=1] = e
G
S = G P
0
S = G e
G
and an adjustment for a yields
0
0.05
0.1
0.15
0.2
0.25
0.3
0.35
0.4
0
.
0
1
5
6
3
0
.
0
3
1
2
5
0
.
0
6
2
5
0
.
1
2
5
0
.
2
5
0
.
5 1 2 4 8
Ge
-G
Ge
-2G
G
S
0.184
0.368
ALOHA and Slotted ALOHA
Throughput versus Load
Aloha
Slotted Aloha

CSMA
(Carrier Sense with Multiple Access)

nonpersistent CSMA {less greedy}

1. Sense the channel.
2. IF the channel is idle, THEN transmit.

3. IF the channel is busy, THEN wait a
random amount of time and start over.
1 - Persistent CSMA
1 - persistent CSMA {selfish}
1. Sense the channel.
2. IF the channel is idle, THEN transmit.

3. IF the channel is busy, THEN continue to
listen until channel is idle and transmit
immediately.
P - Persistent CSMA
p - persistent CSMA {a slotted approximation}

1. Sense the channel.

2. IF the channel is idle, THEN with probability p
transmit and with probability (1-p) delay one
time slot and start over.

3. IF the channel is busy, THEN delay one time slot
and start over.
P Persistent CSMA details
the time slot is usually set to the maximum
propagation delay.
as p decreases, stations wait longer to
transmit but the number of collisions
decreases.
Considerations for the choice of p :
(n x p) must be < 1 for stability, where n is
maximum number of stations, i.e.,
p < 1/n
CSMA Collisions
In all three cases a collision is possible.

CSMA determines collisions by the lack of
an ACK which results in a TIMEOUT. {This is
extremely expensive with respect to
performance.}
If a collision occurs, THEN wait a random
amount of time and start over.
CSMA/CD
CSMA with Collision Detection
If a collision is detected during transmission,
THEN immediately cease transmitting the frame.
The first station to detect a collision sends a jam
signal to all stations to indicate that there has
been a collision.
After receiving a jam signal, a station that was
attempting to transmit waits a random amount of
time before attempting to retransmit.
The maximum time needed to detect a collision =
2 x propagation delay.
CSMA vs CSMA/CD
CSMA is essentially a historical technology until we
include Wireless LANs.
If propagation time is short compared to
transmission time, station can be listening before
sending with CSMA.
Collision detection (CD) accomplished by detecting
voltage levels outside acceptable range. Thus
attenuation limits distance without a repeater.
If the collision time is short compared to packet time
(i.e., small a), performance will increase due to CD.
Probability of 1 successful transmission:
frame contention frame

P
s uc ce s s
= np(1 p)
n 1
P
success
is maximized at p=1/n:

P
s uc ce s s
max
= n(1
1
n
)
n 1

1
e
0
0.1
0.2
0.3
0.4
0.5
0.6
2 4 6 8 10 12 14 16
n
P
max
0
0.1
0.2
0.3
0.4
0.5
0.6
0
.
0
2
0
.
0
3
0
.
0
6
0
.
1
3
0
.
2
5
0
.
5 1 2 4 8
1
6
3
2
6
4
1-Persistent
CSMA
0.53
0.45
0.16
S
G
Throughput vs Load
with varying a
a = 1
a = 0.01
a = 0.1
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
0
.
0
2
0
.
0
3
0
.
0
6
0
.
1
3
0
.
2
5
0
.
5 1 2 4 8
1
6
3
2
6
4
Non-Persistent
CSMA
0.81
0.51
0.14
S
G
Throughput vs Load
With varying a
a = 0.01
a = 0.1
a = 1
0
0.2
0.4
0.6
0.8
1
0.01 0.1 1
Aloha
Slotted Aloha
1-P CSMA
Non-P CSMA
CSMA/CD
a

max
Maximum Achievable Throughputs
CSMA-CD
0
5
10
15
20
25
30
0
0
.
0
6
0
.
1
2
0
.
1
8
0
.
2
4
0
.
3
0
.
3
6
0
.
4
2
0
.
4
8
0
.
5
4
0
.
6
0
.
6
6
0
.
7
2
0
.
7
8
0
.
8
4
0
.
9
0
.
9
6
Load
A
v
g
.

T
r
a
n
s
f
e
r

D
e
l
a
y
a = 0.01
a = 0.1
a = 0.2
Frame Delay varying a
Dynamic Channel Allocation Parameters
Station Model.
N independent stations, each acting as a Poisson Process for the purpose
protocol analysis
Single Channel Assumption.
A single channel is available for all communication.
Collision Assumption.
If transmitted frames overlap in time, the resulting signal is garbled.
Transmission Discipline:
Continuous time
Frames can be transmitted at any time
Slotted time
Frames can be transmitted at particular time points
Sensing capability:
Station cannot sense the channel before trying to use it.
Stations can tell if the channel is in use before trying to use it
Pure ALOHA Protocol
While there is a new frame A to send DO
1. Send frame A and wait for ACK
2. If after some time ACK is not received
(timer times out), wait a random amount
of time and go to 1.
End
Pure ALOHA
In pure ALOHA, frames are transmitted at
completely arbitrary times.
Analysis of Pure ALOHA
Notation:
T
f
= frame time (processing, transmission, propagation)
S: Average number of successful transmissions per T
f
; that is,
the throughput or efficiency.
G: Average number of total frames transmitted per T
f

D: Average delay between the time a packet is ready for
transmission and the completion of successful transmission.
We will make the following assumptions
All frames are of constant length
The channel is noise-free; the errors are only due to
collisions.
Frames do not queue at individual stations
The channel acts as a Poisson process.

Analysis of Pure ALOHA
Since S represents the number of good
transmissions per frame time, and G represents
the total number of attempted transmissions
per frame time, then we have:
S = G (Probability of good transmission)
The vulnerable time for a successful
transmission is 2T
f
So, the probability of good transmission is not to
have an arrival during the vulnerable time .
Analysis of Pure ALOHA
t
0
t
0
+ t t
0
+ 2t t
0
+ 3t
Collides with
the start of
the shaded
frame
Collides with
the end of
the shaded
frame
Vulnerable
Time
Vulnerable period for the shaded frame
t
Analysis of Pure ALOHA
Using:

!
) (
) (
k
e t
t P
t k
k

=
And setting t = 2T
f
and k = 0, we get

2
0
2
0
2
( 2 )
(2 )
0!
becasue . Thus,
f
T
f G
f
G
f
T e
P T e
G
S G e
T

= =
= =
Analysis of Pure ALOHA
If we differentiate S = Ge
-2G
with respect to G and
set the result to 0 and solve for G, we find that
the maximum occurs when
G = 0.5,
and for that S = 1/2e = 0.18. So, the maximum
throughput is only 18% of capacity.

ALOHANET uses a data rate of 9600bps. This
means the maximum total throughput (sum of
data arriving from all user nodes) is only 0.18
9600 = 1728bps.
Pure ALOHA
Throughput versus offered traffic for ALOHA
systems.
Analysis of Pure ALOHA; another approach
There are N stations
Each station transmits with probability p
For a typical node i to have a successful transmission
means that there was no prior overlapping
transmissions before or after, each with probability (1-
p)
N-1

Thus the probability of node i having a successful
transmission is p (1-p)
2(N-1)

Therefore, the probability of a successful transmission
is Np (1 p)
2(N-1)

The maximum value for the above term when N is
large is 1/2e
Slotted ALOHA
Channel is organized into uniform slots whose size equals the
frame transmission time. Transmission is permitted only to begin
at a slot boundary.

Here is the procedure:

While there is a new frame A to send do
1. Send frame A at a slot boundary and wait for ACK
2. If after some time ACK is not received, wait a random
amount of time and go to 1.
End
Slotted ALOHA
Throughput versus offered traffic for ALOHA systems.
Non-persistent CSMA
While there is a new frame A to send DO
1. Check the medium
2. If the medium is busy, wait some time, and go to
1.
3. (medium idle) Send frame A and wait for ACK
4. If after some time ACK is not received (timer
times out), wait a random amount of time and
go to 1.
End
1-persistent CSMA
While there is a new frame A to send do
1. Check the medium
2. If the medium is busy, go to 1.
3. (medium idle) Send frame A and wait for
ACK
4. If after some time ACK is not received
(timer times out), wait a random amount
of time and go to 1.
End.
p-persistent CSMA
While there is a new frame A to send do
1. Check the medium
2. If the medium is busy, go to 1.
3. (medium idle) With probability p send frame A
and the go to 4, and probability (1- p) delay one
time slot and go to 1.
4. If after some time ACK is not received (timer
times out), wait a random amount of time and
go to 1.
End.
CSMA Summary
Non-persistent:
Transmit if idle
Otherwise, delay, try again
Constant or variable
Delay
Channel busy
Ready
1-persistent:
Transmit as soon as channel goes idle. If
collision, back off and try again
Time
p-persistent:
Transmit as soon as channel goes idle with
probability p. Otherwise, delay one slot,
repeat process
CSMA persistence and backoff
Nonpersistent
1-persistent
p-persistent
Persistent and Non-persistent CSMA
Comparison of throughput versus load for
various random access protocols.
CSMA with Collision Detection
Stations can sense the medium while
transmitting
A station aborts its transmission if it senses
another transmission is also happening (that is,
it detects collision)
Question: When can a station be sure that it
has seized the channel?
Minimum time to detect collision is the time it takes
for a signal to traverse between two farthest apart
stations.
CSMA with Collision Detection
CSMA/CD can be in one of three states:
contention, transmission, or idle.
CSMA/CD
A station is said to seize the channel if all
the other stations become aware of its
transmission.
There has to be a lower bound on the
length of each frame for the collision
detection feature to work out.
Ethernet uses CSMA/CD
CSMA/CA
Identical to CSMA/CD but used when listening
is not possible while transmitting
Idle channel reservation is done by sending a
short request message asking other nodes to
defer transmission
If collison is detected then, then random wait
is used
Wireless IEEE 802.11 uses CSMA/CA with an
RTS/CTS mechanism
OSI Reference Model
Data Transmission
The Open Systems Interconnect (OSI) reference model
outlines 7 layers for an ideal network architecture.

Physical Layer
The nuts and bolts layer, where the cable, connector
and signaling specifications are defined
Describes the electrical, mechanical, and functional
interface to the carrier
It includes:
Voltages and pulse coding of bits
Media and media interface
Line discipline (full or half duplex)
Pin Assignments
Data Link Layer
Gets data packets on and off the wire
Does error detection and correction and
retransmission
The primary purpose of the Data Link Layer is to
provide error-free transmission of information
between two end stations
The MAC (Medium Access Control) on the lower
half, deals with getting the data on and off the
wire
The LLC (Logical Link Control) on the upper half,
does the error checking
Network Layer
The Network Layer controls the operation of the
network or
sub-network
Routing and flow control are performed here
This is the lowest layer of the OSI model that can
remain
ignorant of the physical network
The general functions are:
Addressing messages
Routing messages
Controlling congestion
Translating addresses
Counting packets
Transport Layer
Ensures the performance of the lower 3
layers
It provides a transparent, logical data
stream between the end user and the
network service
This is the lower layer that provides local
user services
It provides the session layer with reliable
message transfer facilities
Session Layer
Control the communications between
applications across a network
Testing for out-of-sequence packets
and handling two-way communication
are handled here
Presentation Layer
The Presentation Layer formats the data to be presented
to the Application Layer
Differences in data representation are dealt with at this
level
For example, UNIX-style line endings (CR only) might be
converted to MS-DOS style (CRLF), or EBCIDIC to ASCII
character sets
It can be viewed as the translator for the network
It also does:
Encryption
Encoding
Compression of data
Applications Layer
Where the user applications software
lies
Handles issues such as:
File access and transfer
Virtual terminal emulation
Inter process communication
Electronic Mail
Network Management
TCP/IP Reference Model
TCP/IP = Transmission Control
Protocol/Internet Protocol
Is the basic communication language or
protocol of the Internet
It can also be used as a communications
protocol in the private networks ( intranets and
in extranets)
TCP/IP is a two-layered program
Transmission Control Protocol - Manages the
assembling of a message or file into smaller packets
Internet Protocol - Handles the address part of each
packet so that it gets to the right destination
Application Layer
It contains all the higher level protocols such as Telnet, File
Transfer (FTP), Simple Mail Transfer(SMTP), Domain Name
Service(DNS), Hypertext Transfer (HTTP)

Transport Layer
Designed to allow peer entities on the source and
destination hosts carry on a conversation
TCP and UDP(end-to-end Protocols)defined here
TCP (Transmission Control) - Manages the assembling of a
message or file into smaller packets that are transmitted over the
Internet
UDP (User Datagram) - Connectionless protocol for applications
that do not want TCPs sequencing or flow control( Speech or
Video)
Internet Layer
Defines an official packet format and protocol
called
IP(Internet Protocol) Internet Layer delivers IP packets
to where they are supposed to go(packet routing)

Host-to-Network Layer
Host connects to the network using relevant
protocols so it can send IP packets over it
Repeater: PHY device that restores data and
collision signals: a digital amplifier
Hub: Multi-port repeater + fault detection
Bridge: Data link layer device connecting two
or more collision domains. MAC multicasts are
propagated throughout extended LAN
Router: Network layer device. IP, IPX,
AppleTalk. Does not propagate MAC
multicasts
Switch: Multi-port bridge with parallel paths
IEEE 802.3
The IEEE 802 LAN/MAN Standards Committee
develops Local Area Network standards and
Metropolitan Area Network standards
The most widely used standards are for the
Ethernet family, Token Ring, Wireless LAN,
Bridging and Virtual Bridged LANs
The IEEE 802.3 Working Group develops
standards for CSMA/CD (Ethernet) based LANs
Gigabit Ethernet
Is an open forum with the purpose of
promoting industry cooperation in the
development of Gigabit Ethernet
http://www.gigabit-ethernet.org
Funded in 1996 by:
3COM, Bay Networks, Cisco, Compaq, Granit
System, Intel,LSI Logic, Packet Engine, SUN
Microsystem, UB Networks, VLSI

You might also like