0% found this document useful (0 votes)
57 views39 pages

Access Control Update in Networking

The document discusses different types of communication links and access control methods in computer networking. It describes point-to-point links which connect two stations directly and broadcast links which are shared among multiple connected stations. Access control is needed for broadcast links to prevent packet collisions. Common access control methods described are time division multiplexing, polling, CSMA/CD, token passing, and Aloha. Time division multiplexing divides time into slots allocated to stations to transmit without collisions. Polling involves a polling algorithm choosing one station at a time to transmit. CSMA/CD uses carrier sensing and collision detection to reduce collisions on shared links.

Uploaded by

The Matrix
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)
57 views39 pages

Access Control Update in Networking

The document discusses different types of communication links and access control methods in computer networking. It describes point-to-point links which connect two stations directly and broadcast links which are shared among multiple connected stations. Access control is needed for broadcast links to prevent packet collisions. Common access control methods described are time division multiplexing, polling, CSMA/CD, token passing, and Aloha. Time division multiplexing divides time into slots allocated to stations to transmit without collisions. Polling involves a polling algorithm choosing one station at a time to transmit. CSMA/CD uses carrier sensing and collision detection to reduce collisions on shared links.

Uploaded by

The Matrix
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/ 39

Access Control in Networking | Methods

Types of Communication Links-

In computer networking,

• Communication links enable the stations to communicate with each other.


• Stations may communicate using the following types of links-

1. Point to Point Link


2. Broadcast Link

1. Point to Point Link-

• Point to Point link is a dedicated link that exists between the two stations.
• The entire capacity of the link is used for transmission between the two connected stations only.
• Depending upon the Type Of Channel, the data flow takes place between the stations.

Example-
2. Broadcast Link-

• Broadcast link is a common link to which multiple stations are connected.


• The capacity of the link is shared among the connected stations for transmission.

Example-

Access Control-
Access Control is a mechanism that controls the access of stations to the transmission link.

• Broadcast links require the access control.


• This is because the link is shared among several stations.

Need of Access Control-


To prevent the occurrence of collision or if the collision occurs, to deal with it.

Consider a situation where-

• Multiple stations place their data packets on the link and starts transmitting simultaneously.
• Such a situation gives rise to a collision among the data packets.
• Collision of data packets causes the data to get corrupt.
Example-

Consider the following scenario-

Access Control Methods-


Access control methods are the methods used for providing access control.

• They prevent the collision or deal with it and ensures smooth flow of traffic on the network.
• They are implemented at the data link layer of the OSI reference model.

Various access control methods used are-


1. Time Division Multiplexing
2. Polling
3. CSMA / CD
4. Token Passing
5. Aloha

Time Division Multiplexing-

In Time Division Multiplexing (TDM),

• Time of the link is divided into fixed size intervals called as time slots or time slices.
• Time slots are allocated to the stations in Round Robin manner.
• Each station transmit its data during the time slot allocated to it.
• In case, station does not have any data to send, its time slot goes waste.

Example-
Size Of Time Slots-

The size of each time slot is kept such that each station gets sufficient time for the following
tasks-

• To put its data packet on to the transmission link


• Last bit of the packet is able to get out of the transmission link

Thus,

Size of each time slot = Tt + Tp

where-

• Tt = Transmission delay
• Tp = Propagation delay

NOTE-

To keep the size of time slots constant,

• We have assumed that all the stations want to send the packets of same size.
• This keeps Tt constant for all the stations.
• We have considered the worst case when both the stations are present at the two extreme ends.
• This ensures Tp will be maximum and all the stations will get sufficient time to propagate their
data.

Efficiency-

Efficiency (η) = Useful Time / Total Time

• Useful time = Transmission delay of data packet = Tt


• Useless time = Propagation delay of data packet = Tp
Thus,

Important Formulas-

• Size of each time slot in Time Division Multiplexing = Tt + Tp


• Efficiency (η) = 1 / (1+a) where a = Tp / Tt
• Effective Bandwidth / Bandwidth Utilization / Throughput = Efficiency(η) x Bandwidth
• Maximum Available Effective Bandwidth = Total number of stations x Bandwidth requirement
of 1 station

Disadvantage-

• If any station does not have the data to send during its time slot, then its time slot goes waste.
• This reduces the efficiency.
• This time slot could have been allotted to some other station willing to send data.
PRACTICE PROBLEM BASED ON TIME DIVISION MULTIPLEXING (TDM)-

Problem-

If transmission delay and propagation delay of a packet in Time Division Multiplexing is 1 msec
each at 4 Mbps bandwidth, then-

1. Find the efficiency.


2. Find the effective bandwidth.
3. How many maximum stations can be connected to the network if each station requires 2 Kbps
bandwidth?

Solution-

Given-

• Transmission delay (Tt) = 1msec


• Propagation delay (Tp) = 1msec
• Bandwidth = 4 Mbps

Part-01:

For a TDM Network,

Efficiency (η) = 1 / 1+a where a = Tp / Tt

Calculating Value Of ‘a’-


a = Tp / Tt

a = 1 msec / 1 msec

a=1

Calculating Efficiency-

Efficiency (η)

= 1 / (1+a)

= 1 / (1 + 1)

=1/2

= 0.5

= 50%

Part-02:

We know-

Effective Bandwidth = Efficiency (η) x Bandwidth

Thus,

Effective Bandwidth

= 0.5 x 4 Mbps

= 2 Mbps

Part-03:

We know-

Maximum Effective Bandwidth

= Total number of stations x Bandwidth requirement of 1 station

Let the total number of stations that can be connected be N.


Then, we have-

2 Mbps = N x 2 Kbps

N = 1000

Thus, maximum 1000 stations can be connected.

Polling-

In this access control method,

• A polling is conducted in which all the stations willing to send data participates.
• The polling algorithm chooses one of the stations to send the data.
• The chosen station sends the data to the destination.
• After the chosen station has sent the data, the cycle repeats.

Example-
Here-

• Tpoll = Time taken for polling


• Tsend = Time taken for sending the data = Transmission delay + Propagation delay = Tt + Tp

Efficiency-
Efficiency (η) = Useful Time / Total Time

• Useful time = Transmission delay of data packet = Tt


• Useless time = Time wasted during polling + Propagation delay of data packet = Tpoll + Tp

Thus,

Advantages-

• Unlike in Time Division Multiplexing, no slot is ever wasted.


• It leads to maximum efficiency and bandwidth utilization.

Disadvantages-

• Time is wasted during polling.


• Link sharing is not fair since each station has the equal probability of winning in each round.
• Few stations might starve for sending the data.
Important Formulas-

• Efficiency (η) = Tt / (Tpoll + Tt + Tp)


• Effective Bandwidth / Bandwidth Utilization / Throughput = Efficiency(η) x Bandwidth
• Maximum Available Effective Bandwidth = Total number of stations x Bandwidth requirement
of 1 station

CSMA / CD-
CSMA / CD stands for Carrier Sense Multiple Access / Collision Detection.

Carrier Sense Multiple Access ensures fewer collisions as the station is required to first sense the
medium (for idle or busy) before transmitting data. If it is idle then it sends data, otherwise it
waits till the channel becomes idle. However there is still chance of collision in CSMA due to
propagation delay. For example, if station A wants to send data, it will first sense the medium. If
it finds the channel idle, it will start sending data. However, by the time the first bit of data is
transmitted (delayed due to propagation delay) from station A, if station B requests to send data
and senses the medium it will also find it idle and will also send data. This will result in collision
of data from station A and B.

This access control method works as follows-

Step-01: Sensing the Carrier-

• Any station willing to transmit the data senses the carrier.


• If it finds the carrier free, it starts transmitting its data packet otherwise not.

How?

• Each station can sense the carrier only at its point of contact with the carrier.
• It is not possible for any station to sense the entire carrier.
• Thus, there is a huge possibility that a station might sense the carrier free even when it is actually
not.
Example-

Consider the following scenario-

At the current instance,

• If station A senses the carrier at its point of contact, then it will find the carrier free.
• But the carrier is actually not free because station D is already transmitting its data.
• If station A starts transmitting its data now, then it might lead to a collision with the data
transmitted by station D.

Step-02: Detecting the Collision-

In CSMA / CD,

• It is the responsibility of the transmitting station to detect the collision.


• For detecting the collision, CSMA / CD implements the following condition.
• This condition is followed by each station-
Transmission delay >= 2 x Propagation delay

Meaning-

According to this condition,

• Each station must transmit the data packet of size whose transmission delay is at least twice its
propagation delay.
• If the size of data packet is smaller, then collision detection would not be possible.

Length Of Data Packet-

We know-

• Transmission delay = Length of data packet (L) / Bandwidth (B)


• Propagation delay = Distance between the two stations (D) / Propagation speed (V)

Substituting values in the above condition, we get-

L / B >= 2 x D / V

Thus,

L >= 2 x B x D / V
Understanding the Condition To Detect Collision With Example

• Consider at time 10:00 am, station A senses the carrier.


• It finds the carrier free and starts transmitting its data packet to station D.
• Let the propagation delay be 1 hour.

(We are considering station D for the worst case)

• Let us consider the scenario at time 10:59:59:59 when the packet is about to reach the
station D.
• At this time, station D senses the carrier.
• It finds the carrier free and starts transmitting its data packet.
• Now, as soon as station D starts transmitting its data packet, a collision occurs with the data
packet of station A at time 11:00 am.
• After collision occurs, the collided signal starts travelling in the backward direction.
• The collided signal takes 1 hour to reach the station A after the collision has occurred.
• For station A to detect the collided signal, it must be still transmitting the data.
• So, transmission delay of station A must be >= 1 hour + 1 hour >= 2 hours to detect the
collision.
• That is why, for detecting the collision, condition is Tt >= 2Tp.

Two cases are possible-

Case-01:

If no collided signal comes back during the transmission,

• It indicates that no collision has occurred.


• The data packet is transmitted successfully.

Case-02:

If the collided signal comes back during the transmission,

• It indicates that the collision has occurred.


• The data packet is not transmitted successfully.
• Step-03 is followed.

Step-03: Releasing Jam Signal-

• Jam signal is a 48 bit signal.


• It is released by the transmitting stations as soon as they detect a collision.
• It alerts the other stations not to transmit their data immediately after the collision.
• Otherwise, there is a possibility of collision again with the same data packet.
• Ethernet sends the jam signal at a frequency other than the frequency of data signals.
• This ensures that jam signal does not collide with the data signals undergone collision.

Step-04: Waiting For Back Off Time-

• After the collision, the transmitting station waits for some random amount of time called as back
off time.
• After back off time, it tries transmitting the data packet again.
• If again the collision occurs, then station again waits for some random back off time and then
tries again.
• The station keeps trying until the back off time reaches its limit.
• After the limit is reached, station aborts the transmission.
• Back off time is calculated using Back Off Algorithm.
CSMA / CD Flowchart-

The following CSMA / CD flowchart represents the CSMA / CD procedure-

Efficiency (η) = Useful Time / Total Time

Before a successful transmission,

• There may occur many number of collisions.


• 2 x Tp time is wasted during each collision.

Thus,

• Useful time = Transmission delay of data packet = Tt


• Useless time = Time wasted during collisions + Propagation delay of data packet = c x 2 x Tp +
Tp
• Here, c = Number of contention slots / collision slots.

Thus,
Efficiency-

Efficiency (η) = Useful Time / Total Time

Before a successful transmission,

• There may occur many number of collisions.


• 2 x Tp time is wasted during each collision.

Thus,

• Useful time = Transmission delay of data packet = Tt


• Useless time = Time wasted during collisions + Propagation delay of data packet = c x 2 x Tp + Tp
• Here, c = Number of contention slots / collision slots.

Thus,

Here,

• c is a variable.
• This is because number of collisions that might occur before a successful transmission are
variable.

Probabilistic Analysis shows-


Average number of collisions before a successful transmission = e

Substituting c = e in the above relation, we get-

Important Notes-

Note-01:

• CSMA / CD is used in wired LANs.


• CSMA / CD is standardized in IEEE 802.3
Note-02:

• CSMA / CD only minimizes the recovery time.


• It does not take any steps to prevent the collision until it has taken place.

Important Formulas-

• Condition to detect collision: Transmission delay >= 2 x Propagation delay


• Minimum length of data packets in CSMA / CD = 2 x Bandwidth x Distance / Speed
• Efficiency of CSMA / CD = 1 / (1 + 6.44 x a) where a = Tp / Tt

Token Passing

Time Conversions-

In token passing,

• Time may be expressed in seconds, bits or meters.


• To convert the time from one unit to another, we use the following conversion chart-

Conversion Chart
Token Passing Terminology-

The following terms are frequently used-

1. Token
2. Ring Latency
3. Cycle Time

1. Token-

• A token is a small message composed of a special bit pattern.


• It represents the permission to send the data packet.
• A station is allowed to transmit a data packet if and only if it possess the token otherwise not.

2. Ring Latency-

Time taken by a bit to complete one revolution of the ring is called as ring latency.
Let us derive the expression for ring latency.

If-

• Length of the ring = d


• Speed of the bit = v
• Number of stations = N
• Bit delay at each station = b

(Bit delay is the time for which a station holds the bit before transmitting to the other side)

Then-

Notes-

• d / v is the propagation delay (Tp) expressed in seconds.


• Generally, bit delay is expressed in bits.
• So, both the terms (d / v and N x b) have different units.
• While calculating the ring latency, both the terms are brought into the same unit.
• The above conversion chart is used for conversion.

After conversion, we have-


3. Cycle Time-

Time taken by the token to complete one revolution of the ring is called as cycle time.

If-

• Length of the ring = d


• Speed of the bit = v
• Number of stations = N
• Token Holding Time = THT

(Token Holding Time is the time for which a station holds the token before transmitting to the
other side)
Then-

Now, we start discussing about Token Passing Access Control Method.

Token Passing-

In this access control method,

• All the stations are logically connected to each other in the form of a ring.
• The access of stations to the transmission link is governed by a token.
• A station is allowed to transmit a data packet if and only if it possess the token otherwise not.
• Each station passes the token to its neighboring station either clockwise or anti-clockwise.
Assumptions-

Token passing method assumes-

• Each station in the ring has the data to send.


• Each station sends exactly one data packet after acquiring the token.

Efficiency-

Efficiency (η) = Useful Time / Total Time

In one cycle,

• Useful time = Sum of transmission delay of N stations since each station sends 1 data packet = N
x Tt
• Total Time = Cycle time = Tp + N x THT

Thus,

Token Holding Time depends on the strategy implemented.


Token Passing Strategies-

The following 2 strategies are used in token passing-

1. Delayed Token Reinsertion (DTR)


2. Early Token Reinsertion (ETR)

1. Delayed Token Reinsertion-

In this strategy,

• Station keeps holding the token until the last bit of the data packet transmitted by it takes the
complete revolution of the ring and comes back to it.

Working-

After a station acquires the token,

• It transmits its data packet.


• It holds the token until the data packet reaches back to it.
• After data packet reaches to it, it discards its data packet as its journey is completed.
• It releases the token.

The following diagram illustrates these steps for station-1. Same procedure is repeated at every
station.
Token Holding Time-

Token Holding Time (THT) = Transmission delay + Ring Latency

We know,

• Ring Latency = Tp + N x bit delay


• Assuming bit delay = 0 (in most cases), we get-

Token Holding Time = Tt + Tp


Efficiency-

Substituting THT = Tt + Tp in the efficiency expression, we get-


2. Early Token Reinsertion-

In this strategy,

• Station releases the token immediately after putting its data packet to be transmitted on the ring.

Working-

Step-01: At Station-1:

Station-1

• Acquires the token


• Transmits packet-1
• Releases the token
Step-02: At Station-2:

Station-2

• Receives packet-1
• Transmits packet-1
• Acquires the token
• Transmits packet-2
• Releases the token

Step-03: At Station-3:

Station-3

• Receives packet-1
• Transmits packet-1
• Receives packet-2
• Transmits packet-2
• Acquires the token
• Transmits packet-3
• Releases the token

Step-04: At Station-4:

Station-4

• Receives packet-1
• Transmits packet-1
• Receives packet-2
• Transmits packet-2
• Receives packet-3
• Transmits packet-3
• Acquires the token
• Transmits packet-4
• Releases the token

Step-05: At Station-1:

• Receives packet-1
• Discards packet-1 (as its journey is completed)
• Receives packet-2
• Transmits packet-2
• Receives packet-3
• Transmits packet-3
• Receives packet-4
• Transmits packet-4
• Acquires the token
• Transmits packet-1 (new)
• Releases the token
In this manner, the cycle continues.

Token Holding Time-

Token Holding Time (THT) = Transmission delay of data packet = Tt

Efficiency-

Substituting THT = Tt in the efficiency expression, we get-

Differences between DTR and ETR-

Delay Token Retransmission (DTR) Early Token Retransmission (ETR)


Each station holds the token until its data packet Each station releases the token immediately after
reaches back to it. putting its data packet on the ring.

There exists only one data packet on the ring at There exists more than one data packet on the
any given instance. ring at any given instance.

It is more reliable than ETR. It is less reliable than DTR.

It has low efficiency as compared to ETR. It has high efficiency as compared to DTR.

Important Notes-

Note-01:

In token passing,

• It is the responsibility of each transmitting station to remove its own data packet from the ring.

Note-02:

While solving questions,

• If the strategy used is not mentioned, then consider Early Token Retransmission strategy.

Problem-11:

Find the efficiency of the ring where data rate of the link is 4 Mbps, number of stations are 20,
separated by 100 meters and bit delay in each station is 2.5 bits. Assume early token reinsertion
with packet size of 1000 bits and transmission speed is 2 x 108 m/sec.

Solution-

Given-

• Data rate = Bandwidth = 4 Mbps


• Number of stations = 20
• Distance between two stations = 100 meters
• Bit delay = 25 bits
• Packet size = 1000 bits
• Strategy used is Early Token Reinsertion (ETR)

Calculating length of ring wire-

Total length of ring wire

= Number of stations x Distance between 2 stations

= 20 x 100 meters

= 2000 meters

= 2 km

Calculating Transmission delay-

Transmission delay (Tt)

= Packet size / Bandwidth

= 1000 bits / 4 Mbps

= 1000 bits / (4 x 106 bits per sec)

= 250 μsec

Calculating Propagation delay-

Propagation delay (Tt)


= Distance / Speed

= 2 km / (2 x 108 m/sec)

= (2 x 103 m) / (2 x 108 m/sec)

= 10-5 sec

= 10 μsec

Calculating Bit delay in seconds-

Bit delay

= 25 bits

= 2.5 bits / 4 Mbps

= 25 bits / (4 x 106 bits per sec)

= 0.625 μsec

Calculating Ring latency-

Ring latency

= Propagation delay + N x Bit delay

= 10 μsec + 20 x 0.625 μsec

= 10 μsec + 12.5 μsec

= 22.5 μsec
Calculating value of ‘a’-

= Ring latency / Tt

= 22.5 μsec / 250 μsec

= 0.09

Calculating Efficiency-

Efficiency(η)

= 1 / (1 + a/N)

= 1 / (1 + 0.09 / 20)

= 1 / 1.0045

= 0.9955

= 99.55%

Problem-14:

A fibre optic token ring used as a MAN is 200 km long and runs at 100 Mbps. After sending a
frame, a station drains the frame from the ring before regenerating the token. The signal
propagation speed in the fibre is 200,000 km/sec and maximum frame size is 1 KB. What is the
maximum efficiency at N=1?

Solution-

Given-

• Distance = 200 km
• Bandwidth = 100 Mbps
• Propagation speed = 200,000 km/sec = 2 x 108 m/sec
• Frame size = 1 KB
• Number of stations = 1
• Strategy used is Delayed Token Reinsertion

Calculating Transmission delay-

Transmission delay

= Frame size / Bandwidth

= 1 KB / 100 Mbps

= (1 x 210 x 8 bits) / (100 x 106 bits per sec)

= 81.92 μsec

Calculating Propagation delay-

Propagation delay

= Distance / Speed

= 200 km / (2 x 108 m/sec)

= (200 x 103 m) / (2 x 108 m/sec)

= 10-3 sec

= 1 msec

Calculating value of ‘a’-

= Tp / Tt
= 1 msec / 81.92 μsec

= 0.0122 x 103

= 12.2

Calculating Efficiency-

Efficiency(η)

= 1 / [1 + a x (1+ 1/N)]

= 1 / [1 + 12.2 x (1+1)]

= 1 / 25.4

= 0.0394

= 3.94%

• The reason behind this much less efficiency is that the distance is too large here.
• Ethernet and Token Ring are meant for LANs.
• If used for MANs or WANs, the efficiency will fall drastically.

Problem-15:

At a propagation speed of 200 m/μsec, what is the effective length added to a ring by a bit delay
at each repeater or station for-

A. 1 Mbps line
B. 40 Mbps line

Solution-
Part-01:

Effective length added to a ring by a bit delay

= 1 bit / 1 Mbps

= 1 μsec

= 1 μsec x 200 m/μsec

= 200 m

Part-02:

Effective length added to a ring by a bit delay

= 1 bit / 40 Mbps

= 0.025 μsec

= 0.025 μsec x 200 m/μsec

=5m

Problem-16:

Consider a 10 Mbps token ring LAN with a ring latency of 400 μs. A host that needs to transmit
seizes the toke. Then it sends a frame of 1000 bytes, removes the frame after it has circulated all
around the ring and finally releases the token. This process is repeated for every frame.
Assuming that only a single host wishes to transmit, the effective data rate is _____ .

A. 1 Mbps
B. 2 Mbps
C. 5 Mbps
D. 6 Mbps
Solution-

Given-

• Bandwidth = 10 Mbps
• Ring latency = 400 μsec
• Frame size = 1000 bytes
• Number of stations = 1
• Strategy used is Delayed Toke Reinsertion

Calculating Transmission delay-

Transmission delay

= Frame size / Bandwidth

= 1000 bytes / 10 Mbps

= (1000 x 8 bits) / (10 x 106 bits per sec)

= 800 μsec

Calculating value of ‘a’-

= Ring latency / Tt

= 400 μsec / 800 μsec

= 0.5

Calculating Efficiency-

Efficiency(η)
= 1 / [1 + a x (1+ 1/N)]

= 1 / [1 + 0.5 x (1+1)]

=1/2

= 0.50

= 50%

Calculating Effective data rate-

Effective data rate

= Throughput

= Efficiency(η) x Bandwidth

= 0.5 x 10 Mbps

= 5 Mbps

Thus, Option (C) is correct

You might also like