SlideShare une entreprise Scribd logo
1  sur  22
Group members:
Aqsa Imtiaz
Zainab Tariq
Shaheer Ali
Huda Naseer
1
TOPIC:
LEAKY BUCKET ALGORITHM
2
Outlines:
 Congestion
 Traffic Shaping
 Introduction
 Algorithm Example
 Uses
 Advantages & Disadvantages
3
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
packets at a higher rate than receiving nodes are removing
them.
This degrades the performance, and such a situation is termed
as Congestion.
4
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
5
Introduction:
Conceptually, each host connected to the network has an
interface containing a "leaky bucket” (a queue)
To send a packet into the 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.
6
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
Cont’d:
7
Figure:
(a) A leaky bucket with water. (b) a leaky bucket with packets.
8
Algorithm
Step - 1 : Initialize the counter to ‘n’ at every tick of clock.
Step - 2 : If n is greater than the size of packet in the
front of queue send the packet into the network and
decrement the counter by size of packet. Repeat the
step until n is less than the size of packet.
Step - 3 : Reset the counter and go to Step - 1.
9
10
Example
Let n = 1000
Packet =.
Since n > front of Queue i.e. n>200
Therefore, n= 1000-200 = 800
Packet size of 200 is sent to the network
200 700 500 450 400 200
11
Packet =
Now Again n > front of queue i.e. n > 400
Therefore, n= 800-400 = 400
Packet size of 400 is sent to the network
12
Packet =
Since n < front of queue .
There fore, the procedure is stop.
And we initialize n = 1000 on another tick of clock.
This procedure is repeated until all the packets is sent to the network.
Explanation
 When the packets are all the same size (e.g., ATM
cells), this algorithm can be used as described.
 when variable-sized packets are being used, it is
often better to allow a fixed number of bytes per
tick, rather than just one packet.
 if the rule is 1024 bytes per tick, a single 1024-
byte packet can be admitted on a tick, two 512-
byte packets, four 256-byte packets, and so on.
13
Leaky bucket model
To understand the leaky bucket model, consider a
bucket with a small hole at the bottom. Three
parameters define the bucket:
The capacity (B)
The rate at which water flows out of the bucket (R)
The initial fullness of the bucket (F)
14
15
Leaky bucket model
If water is poured into the bucket at exactly rate R,
the bucket will remain at F, because the input rate
equals the output rate.
If the input rate increases while R remains constant,
the bucket accumulates water.
If the input rate is larger than R for a sustained
period, eventually the bucket overflows.
16
Leaky bucket model
However, the input rate can vary around R without
overflowing the bucket, as long as the average input rate does
not exceed the capacity of the bucket.
The larger the capacity, the more the input rate can vary within
a given window of time.
Real life applications are Digital Media.
17
Parameters
The leaky bucket algorithm uses two parameters to control
traffic flow:
Burst rate: The rate at which cells are allowed to accumulate
in the bucket, expressed in cells per second.
Average rate: The average number of cells per second that
"leak" from the hole in the bottom of the bucket and enter the
network.
For example, if the average burst rate is 10 cells per second, a
burst of 10 seconds allows 100 cells to accumulate in the
bucket.
18
Uses:
The leaky bucket algorithm is used in packet switched computer networks
and telecommunications networks.
The leaky bucket as a queue can only be used in shaping traffic with no
delay in the output.
It may be used within the network, as part of bandwidth management, but
is more appropriate to traffic shaping in the network.
A technique used in ATM networks that applies a sustained cell flow rate
to bursty traffic.
Leaky bucket algorithm is used as the mechanism of the UPC(Usage
Parameter Control) in the network.
19
Advantages:
Token independent
Packets are transmitted continuously.
It sends the packet at constant rate
Input rate can differ but output rate will be constant.
20
Disadvantages
It does not save token.
If bucket is full packet or data is discarded.
LB sends packets at an average rate.
21
Thank You
22

Contenu connexe

Tendances

Multiple Access Protocal
Multiple Access ProtocalMultiple Access Protocal
Multiple Access Protocaltes31
 
Types of Load distributing algorithm in Distributed System
Types of Load distributing algorithm in Distributed SystemTypes of Load distributing algorithm in Distributed System
Types of Load distributing algorithm in Distributed SystemDHIVYADEVAKI
 
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSComputer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSDr. SELVAGANESAN S
 
Security services and mechanisms
Security services and mechanismsSecurity services and mechanisms
Security services and mechanismsRajapriya82
 
Network Layer design Issues.pptx
Network Layer design Issues.pptxNetwork Layer design Issues.pptx
Network Layer design Issues.pptxAcad
 
Go back-n protocol
Go back-n protocolGo back-n protocol
Go back-n protocolSTEFFY D
 
QOS (Quality of Services) - Computer Networks
 QOS (Quality of Services) - Computer Networks QOS (Quality of Services) - Computer Networks
QOS (Quality of Services) - Computer NetworksIIIT Manipur
 
AES-Advanced Encryption Standard
AES-Advanced Encryption StandardAES-Advanced Encryption Standard
AES-Advanced Encryption StandardPrince Rachit
 
Message Authentication Code & HMAC
Message Authentication Code & HMACMessage Authentication Code & HMAC
Message Authentication Code & HMACKrishna Gehlot
 
Secure Hash Algorithm (SHA-512)
Secure Hash Algorithm (SHA-512)Secure Hash Algorithm (SHA-512)
Secure Hash Algorithm (SHA-512)DUET
 
Network layer - design Issues
Network layer - design IssuesNetwork layer - design Issues
Network layer - design Issuesقصي نسور
 
block ciphers
block ciphersblock ciphers
block ciphersAsad Ali
 
Issues in knowledge representation
Issues in knowledge representationIssues in knowledge representation
Issues in knowledge representationSravanthi Emani
 

Tendances (20)

Error control
Error controlError control
Error control
 
Multiple Access Protocal
Multiple Access ProtocalMultiple Access Protocal
Multiple Access Protocal
 
Transport layer
Transport layerTransport layer
Transport layer
 
Network layer tanenbaum
Network layer tanenbaumNetwork layer tanenbaum
Network layer tanenbaum
 
Types of Load distributing algorithm in Distributed System
Types of Load distributing algorithm in Distributed SystemTypes of Load distributing algorithm in Distributed System
Types of Load distributing algorithm in Distributed System
 
Congestion Control
Congestion ControlCongestion Control
Congestion Control
 
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESSComputer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
Computer Networks Unit 2 UNIT II DATA-LINK LAYER & MEDIA ACCESS
 
Security services and mechanisms
Security services and mechanismsSecurity services and mechanisms
Security services and mechanisms
 
Network Layer design Issues.pptx
Network Layer design Issues.pptxNetwork Layer design Issues.pptx
Network Layer design Issues.pptx
 
Go back-n protocol
Go back-n protocolGo back-n protocol
Go back-n protocol
 
QOS (Quality of Services) - Computer Networks
 QOS (Quality of Services) - Computer Networks QOS (Quality of Services) - Computer Networks
QOS (Quality of Services) - Computer Networks
 
AES-Advanced Encryption Standard
AES-Advanced Encryption StandardAES-Advanced Encryption Standard
AES-Advanced Encryption Standard
 
Message Authentication Code & HMAC
Message Authentication Code & HMACMessage Authentication Code & HMAC
Message Authentication Code & HMAC
 
Secure Hash Algorithm (SHA-512)
Secure Hash Algorithm (SHA-512)Secure Hash Algorithm (SHA-512)
Secure Hash Algorithm (SHA-512)
 
Congestion control
Congestion controlCongestion control
Congestion control
 
Admission control
Admission controlAdmission control
Admission control
 
Network layer - design Issues
Network layer - design IssuesNetwork layer - design Issues
Network layer - design Issues
 
block ciphers
block ciphersblock ciphers
block ciphers
 
Sliding window protocol
Sliding window protocolSliding window protocol
Sliding window protocol
 
Issues in knowledge representation
Issues in knowledge representationIssues in knowledge representation
Issues in knowledge representation
 

En vedette

Congetion Control.pptx
Congetion Control.pptxCongetion Control.pptx
Congetion Control.pptxNaveen Dubey
 
Dijkstra & flooding ppt(Routing algorithm)
Dijkstra & flooding ppt(Routing algorithm)Dijkstra & flooding ppt(Routing algorithm)
Dijkstra & flooding ppt(Routing algorithm)Anshul gour
 
Congestion avoidance in TCP
Congestion avoidance in TCPCongestion avoidance in TCP
Congestion avoidance in TCPselvakumar_b1985
 
Tcp Congestion Avoidance
Tcp Congestion AvoidanceTcp Congestion Avoidance
Tcp Congestion AvoidanceRam Dutt Shukla
 
Congestion on computer network
Congestion on computer networkCongestion on computer network
Congestion on computer networkDisi Dc
 
Cs105 l15-bucket radix
Cs105 l15-bucket radixCs105 l15-bucket radix
Cs105 l15-bucket radixGopi Saiteja
 
Tcp congestion control
Tcp congestion controlTcp congestion control
Tcp congestion controlAbdo sayed
 
Congestion control
Congestion controlCongestion control
Congestion controlNithin Raj
 
Requirement Analysis & Specification sharbani bhattacharya
Requirement Analysis & Specification sharbani bhattacharyaRequirement Analysis & Specification sharbani bhattacharya
Requirement Analysis & Specification sharbani bhattacharyaSharbani Bhattacharya
 
Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...
Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...
Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...Vishal Sharma, Ph.D.
 
Congestion Control in Computer Networks - ATM and TCP
Congestion Control in Computer Networks - ATM and TCPCongestion Control in Computer Networks - ATM and TCP
Congestion Control in Computer Networks - ATM and TCPAttila Balazs
 
Congestion Control in Networks
Congestion Control in NetworksCongestion Control in Networks
Congestion Control in Networksrapatil
 
Selective repeat protocol
Selective repeat protocolSelective repeat protocol
Selective repeat protocolManusha Dilan
 
Ethernet OAM evolution
Ethernet OAM evolutionEthernet OAM evolution
Ethernet OAM evolutionNir Cohen
 
Hash Techniques in Cryptography
Hash Techniques in CryptographyHash Techniques in Cryptography
Hash Techniques in CryptographyBasudev Saha
 

En vedette (20)

Congetion Control.pptx
Congetion Control.pptxCongetion Control.pptx
Congetion Control.pptx
 
Congestion Control
Congestion ControlCongestion Control
Congestion Control
 
Dijkstra & flooding ppt(Routing algorithm)
Dijkstra & flooding ppt(Routing algorithm)Dijkstra & flooding ppt(Routing algorithm)
Dijkstra & flooding ppt(Routing algorithm)
 
Congestion avoidance in TCP
Congestion avoidance in TCPCongestion avoidance in TCP
Congestion avoidance in TCP
 
Tcp Congestion Avoidance
Tcp Congestion AvoidanceTcp Congestion Avoidance
Tcp Congestion Avoidance
 
Congestion on computer network
Congestion on computer networkCongestion on computer network
Congestion on computer network
 
Leakybucketalgorithm
LeakybucketalgorithmLeakybucketalgorithm
Leakybucketalgorithm
 
Cs105 l15-bucket radix
Cs105 l15-bucket radixCs105 l15-bucket radix
Cs105 l15-bucket radix
 
Tcp congestion control
Tcp congestion controlTcp congestion control
Tcp congestion control
 
Congestion control
Congestion controlCongestion control
Congestion control
 
Requirement Analysis & Specification sharbani bhattacharya
Requirement Analysis & Specification sharbani bhattacharyaRequirement Analysis & Specification sharbani bhattacharya
Requirement Analysis & Specification sharbani bhattacharya
 
Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...
Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...
Internet Routing Protocols: Fundamental Concepts of Distance-Vector and Link-...
 
Congestion Control in Computer Networks - ATM and TCP
Congestion Control in Computer Networks - ATM and TCPCongestion Control in Computer Networks - ATM and TCP
Congestion Control in Computer Networks - ATM and TCP
 
Congestion Control in Networks
Congestion Control in NetworksCongestion Control in Networks
Congestion Control in Networks
 
Stop And Wait ARQ
Stop And Wait ARQStop And Wait ARQ
Stop And Wait ARQ
 
Selective repeat protocol
Selective repeat protocolSelective repeat protocol
Selective repeat protocol
 
Ethernet OAM evolution
Ethernet OAM evolutionEthernet OAM evolution
Ethernet OAM evolution
 
Radix Sort
Radix SortRadix Sort
Radix Sort
 
Hash Techniques in Cryptography
Hash Techniques in CryptographyHash Techniques in Cryptography
Hash Techniques in Cryptography
 
Go Back N ARQ
Go  Back N ARQGo  Back N ARQ
Go Back N ARQ
 

Similaire à Leaky bucket A

Congestion control algorithms.pptx
Congestion control algorithms.pptxCongestion control algorithms.pptx
Congestion control algorithms.pptxujjwalmatoliya
 
congestion ujjwal matoliya.pptx
congestion ujjwal matoliya.pptxcongestion ujjwal matoliya.pptx
congestion ujjwal matoliya.pptxujjwalmatoliya
 
Congestion control 1
Congestion control 1Congestion control 1
Congestion control 1Aman Jaiswal
 
Wormhole switching : Notes
Wormhole switching : NotesWormhole switching : Notes
Wormhole switching : NotesSubhajit Sahu
 
ENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKS
ENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKSENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKS
ENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKScscpconf
 
CN Module 5 part 2 2022.pdf
CN Module 5 part 2 2022.pdfCN Module 5 part 2 2022.pdf
CN Module 5 part 2 2022.pdfMayankRaj687571
 
Unit 2 data link control
Unit 2 data link controlUnit 2 data link control
Unit 2 data link controlVishal kakade
 
2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...
2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...
2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...IEEEFINALSEMSTUDENTSPROJECTS
 
IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...
IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...
IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...IEEEGLOBALSOFTSTUDENTPROJECTS
 
Computer Networks Module 2.pdf
Computer Networks Module 2.pdfComputer Networks Module 2.pdf
Computer Networks Module 2.pdfShanthalaKV
 
tcp-wireless-tutorial.ppt
tcp-wireless-tutorial.ppttcp-wireless-tutorial.ppt
tcp-wireless-tutorial.pptRadwan Mahmoud
 
Multihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor NetworksMultihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor NetworksChuka Okoye
 
Multihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor NetworksMultihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor NetworksChuka Okoye
 
Transport layer issues and challenges - Guide
Transport layer issues and challenges - GuideTransport layer issues and challenges - Guide
Transport layer issues and challenges - GuideGOPINATHS437943
 

Similaire à Leaky bucket A (20)

Conjestion control
Conjestion controlConjestion control
Conjestion control
 
Congestion control algorithms.pptx
Congestion control algorithms.pptxCongestion control algorithms.pptx
Congestion control algorithms.pptx
 
congestion ujjwal matoliya.pptx
congestion ujjwal matoliya.pptxcongestion ujjwal matoliya.pptx
congestion ujjwal matoliya.pptx
 
Congestion control 1
Congestion control 1Congestion control 1
Congestion control 1
 
Wormhole switching : Notes
Wormhole switching : NotesWormhole switching : Notes
Wormhole switching : Notes
 
ENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKS
ENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKSENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKS
ENHANCEMENT OF TCP FAIRNESS IN IEEE 802.11 NETWORKS
 
CN Module 5 part 2 2022.pdf
CN Module 5 part 2 2022.pdfCN Module 5 part 2 2022.pdf
CN Module 5 part 2 2022.pdf
 
Nigga.pdf
Nigga.pdfNigga.pdf
Nigga.pdf
 
Unit 2 data link control
Unit 2 data link controlUnit 2 data link control
Unit 2 data link control
 
2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...
2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...
2014 IEEE JAVA NETWORKING PROJECT Receiver based flow control for networks in...
 
IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...
IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...
IEEE 2014 JAVA NETWORKING PROJECTS Receiver based flow control for networks i...
 
A018120105
A018120105A018120105
A018120105
 
Computer Networks Module 2.pdf
Computer Networks Module 2.pdfComputer Networks Module 2.pdf
Computer Networks Module 2.pdf
 
G028033037
G028033037G028033037
G028033037
 
8 Packet Switching
8 Packet Switching8 Packet Switching
8 Packet Switching
 
tcp-wireless-tutorial.ppt
tcp-wireless-tutorial.ppttcp-wireless-tutorial.ppt
tcp-wireless-tutorial.ppt
 
Multihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor NetworksMultihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor Networks
 
Multihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor NetworksMultihop Routing In Camera Sensor Networks
Multihop Routing In Camera Sensor Networks
 
9_Network.ppt
9_Network.ppt9_Network.ppt
9_Network.ppt
 
Transport layer issues and challenges - Guide
Transport layer issues and challenges - GuideTransport layer issues and challenges - Guide
Transport layer issues and challenges - Guide
 

Dernier

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
9548086042 for call girls in Indira Nagar with room service
9548086042  for call girls in Indira Nagar  with room service9548086042  for call girls in Indira Nagar  with room service
9548086042 for call girls in Indira Nagar with room servicediscovermytutordmt
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdfQucHHunhnh
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxShobhayan Kirtania
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajanpragatimahajan3
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactPECB
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsTechSoup
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 

Dernier (20)

Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
9548086042 for call girls in Indira Nagar with room service
9548086042  for call girls in Indira Nagar  with room service9548086042  for call girls in Indira Nagar  with room service
9548086042 for call girls in Indira Nagar with room service
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
 
social pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajansocial pharmacy d-pharm 1st year by Pragati K. Mahajan
social pharmacy d-pharm 1st year by Pragati K. Mahajan
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 

Leaky bucket A

  • 1. Group members: Aqsa Imtiaz Zainab Tariq Shaheer Ali Huda Naseer 1
  • 3. Outlines:  Congestion  Traffic Shaping  Introduction  Algorithm Example  Uses  Advantages & Disadvantages 3
  • 4. 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 packets at a higher rate than receiving nodes are removing them. This degrades the performance, and such a situation is termed as Congestion. 4
  • 5. 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 5
  • 6. Introduction: Conceptually, each host connected to the network has an interface containing a "leaky bucket” (a queue) To send a packet into the 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. 6
  • 7. 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 Cont’d: 7
  • 8. Figure: (a) A leaky bucket with water. (b) a leaky bucket with packets. 8
  • 9. Algorithm Step - 1 : Initialize the counter to ‘n’ at every tick of clock. Step - 2 : If n is greater than the size of packet in the front of queue send the packet into the network and decrement the counter by size of packet. Repeat the step until n is less than the size of packet. Step - 3 : Reset the counter and go to Step - 1. 9
  • 10. 10 Example Let n = 1000 Packet =. Since n > front of Queue i.e. n>200 Therefore, n= 1000-200 = 800 Packet size of 200 is sent to the network 200 700 500 450 400 200
  • 11. 11 Packet = Now Again n > front of queue i.e. n > 400 Therefore, n= 800-400 = 400 Packet size of 400 is sent to the network
  • 12. 12 Packet = Since n < front of queue . There fore, the procedure is stop. And we initialize n = 1000 on another tick of clock. This procedure is repeated until all the packets is sent to the network.
  • 13. Explanation  When the packets are all the same size (e.g., ATM cells), this algorithm can be used as described.  when variable-sized packets are being used, it is often better to allow a fixed number of bytes per tick, rather than just one packet.  if the rule is 1024 bytes per tick, a single 1024- byte packet can be admitted on a tick, two 512- byte packets, four 256-byte packets, and so on. 13
  • 14. Leaky bucket model To understand the leaky bucket model, consider a bucket with a small hole at the bottom. Three parameters define the bucket: The capacity (B) The rate at which water flows out of the bucket (R) The initial fullness of the bucket (F) 14
  • 15. 15
  • 16. Leaky bucket model If water is poured into the bucket at exactly rate R, the bucket will remain at F, because the input rate equals the output rate. If the input rate increases while R remains constant, the bucket accumulates water. If the input rate is larger than R for a sustained period, eventually the bucket overflows. 16
  • 17. Leaky bucket model However, the input rate can vary around R without overflowing the bucket, as long as the average input rate does not exceed the capacity of the bucket. The larger the capacity, the more the input rate can vary within a given window of time. Real life applications are Digital Media. 17
  • 18. Parameters The leaky bucket algorithm uses two parameters to control traffic flow: Burst rate: The rate at which cells are allowed to accumulate in the bucket, expressed in cells per second. Average rate: The average number of cells per second that "leak" from the hole in the bottom of the bucket and enter the network. For example, if the average burst rate is 10 cells per second, a burst of 10 seconds allows 100 cells to accumulate in the bucket. 18
  • 19. Uses: The leaky bucket algorithm is used in packet switched computer networks and telecommunications networks. The leaky bucket as a queue can only be used in shaping traffic with no delay in the output. It may be used within the network, as part of bandwidth management, but is more appropriate to traffic shaping in the network. A technique used in ATM networks that applies a sustained cell flow rate to bursty traffic. Leaky bucket algorithm is used as the mechanism of the UPC(Usage Parameter Control) in the network. 19
  • 20. Advantages: Token independent Packets are transmitted continuously. It sends the packet at constant rate Input rate can differ but output rate will be constant. 20
  • 21. Disadvantages It does not save token. If bucket is full packet or data is discarded. LB sends packets at an average rate. 21