Leaky Bucket Algorithm: 171FA04014 171FA04042 171FA04276
Leaky Bucket Algorithm: 171FA04014 171FA04042 171FA04276
Leaky Bucket Algorithm: 171FA04014 171FA04042 171FA04276
ALGORITHM
171FA04014
171FA04042
171FA04276
CONTENTS:
Congestion
Traffic Shopping
Introduction
Algorithm Example
Uses
Advantages & Disadvantages
Congestion
Internet can be considered as a Queue of packets, where
transmitting nodes are constantly adding packets and some of
them (receiving nodes) are removing packets from the queue.
Consider a situation where too many packets are present in this
queue , such that constantly transmitting nodes are pouring
packet at a higher rate than receiving nodes are removing them.
This degrades the performance , and such a situation is termed as
Congestion.
Traffic Shaping
It is about regulating average rate of data flow.
It is a method of congestion control by providing shape to
data flow before entering the packet into the network.
At connection set-up time , the sender and carrier
negotiate a traffic pattern(shape)
There are two types of Traffic shaping algorithm
1.Leaky Bucket Algorithm.
2.Token Bucket Algorithm.
Introduction
Conceptually , each host connected to the network has an
interface containing a “Leaky Bucket”(a queue)
To send a packet into a network , it must be possible to
put more water into the bucket.
If a packet arrives when the bucket is full , the packet
must either be queued until enough water leaks out to hold
it or be discarded.
This technique was proposed by Turner(1986) and is
called the leaky bucket algorithm.
Continued…..
Allow one packet per clock tick.
It is implemented as a single-server queue with constant
service time.
If the bucket(buffer) overflows then packets are
discarded.
In this algorithm the input rate can vary but the output
rate remains constant.
This algorithm converts bursty traffic into fixed rate
traffic by averaging the data rate.
Algorithm
Step-1:Initialize the counter to ‘n’ at every tick of clock.
The capacity(B)
The larger the capacity , the more the input rate can vary
within a given window of time.