160 likes | 260 Vues
This document explores essential concepts of queueing theory as applied to communication networks. It covers scheduling disciplines, such as Generalized Processor Sharing (GPS) and Weighted Fair Queueing (WFQ), alongside drop policies that determine packet handling upon overflow. Key methodologies include serving packets in order of finish times and using Virtual Time to manage active connections. The advantages of Random Early Detection (RED) and Explicit Congestion Notification (ECN) are also discussed, highlighting their role in mitigating congestion and improving fairness among flows.
E N D
Communication Networks Recitation 4 Scheduling & Drop Policies Comnet 2006
Queueing Basics • A queue consists of a scheduling discipline and a drop policy input scheduling discipline: what packet gets sent next drop policy: what is dropped upon overflow queued packets Comnet 2006
Generalized Processor Sharing • The ideal max-min fair scheduling scheme • Visit each non-empty queue in turn • Serve infinitesimal from each • GPS is not implementable; we can serve only packets Comnet 2006
Weighted Fair Queueing Problem: We need to serve a whole packet at a time. Solution: • Determine what time a packet, p, would complete if we served flows by GPS. Call this the packet’s finish time, F(p). • Serve packets in the order of increasing finish time. Comnet 2006
WFQ Round -- Virtual Time • Round number is a real-valued variable that increases at a rate inversely proportional to the number/weight of active connections • Updating the number of connections: • A connection becomes active when a packet arrives to an empty queue • A connection becomes inactive when R(t) > F(p), where p is the last packet served Comnet 2006
A F1=1 L=1 F2=3.5 L=2 B F1=2 L=2 C F1=2 L=2 Virtual time Example 1 1/3 1/2 1/3 Comnet 2006
6 5 4 3 2 1 0 Time A1 = 4 1 1 1 1 1 1 1 1 1 1 1 1 B1 = 3 C2 = 1 C1 = 1 D1 = 1 D2 = 2 Weights : 1:1:1:1 6 5 4 3 2 1 0 D1, C1 Depart at R=1 Time A2, C3 arrive A2 = 2 A1 = 4 D1 C1 B1 A1 B1 = 3 C3 = 2 C2 = 1 C1 = 1 Round 1 D1 = 1 D2 = 2 Weights : 1:1:1:1 6 5 4 3 2 1 0 Time C2 Departs at R=2 A2 = 2 A1 = 4 D2 C2 B1 A1 D1 C1 B1 A1 B1 = 3 C3 = 2 C2 = 1 C1 = 1 Round 2 Round 1 D1 = 1 D2 = 2 Weights : 1:1:1:1 Understanding bit by bit WFQ 4 queues, sharing 4 bits/sec of bandwidth Comnet 2006
Time 6 5 4 3 2 1 0 D2, B1 Depart at R=3 A2 = 2 A1 = 4 1 1 1 1 1 1 1 1 1 1 1 1 D2 C2 B1 A1 D2 C3 B1 A1 D1 C1 B1 A1 B1 = 3 C3 = 2 C2 = 1 C1 = 1 D1 = 1 D2 = 2 6 5 4 3 2 1 0 Weights : 1:1:1:1 A2 Departs at R=6 C3, A1 Depart at R=4 Time A2 = 2 A1 = 4 D2 C2 B1 A1 A2 A2 C3 A1 D2 C3 B1 A1 D1 C1 B1 A1 B1 = 3 C3 = 2 C2 = 1 C1 = 1 6 5 Round 4 Round 3 D1 = 1 D2 = 2 Sort packets Weights : 1:1:1:1 Time 6 5 4 3 2 1 0 Departure order for packet by packet WFQ: Sort by finish round of packets A2 = 2 A1 = 4 A2 A2 C3 C3 A 1 A 1 A1 A 1 D2 D2 B1 B1 B1 C2 D1 C1 B1 = 3 Round 2 Round 1 Round 2 Round 1 C3 = 2 C2 = 1 C1 = 1 D1 = 1 D2 = 2 Weights : 1:1:1:1 Understanding bit by bit WFQ 4 queues, sharing 4 bits/sec of bandwidth Round 3 Comnet 2006
WF²Q • Packet approximation algorithm of GPS. • Choosing the packet with the smallest finish time among all the packets that have already started service in the corresponding GPS emulation. • Almost identical to that of GPS, differing by no more than one maximum size packet. Comnet 2006
Drop-tail • Signals congestion only when the queue is already saturated • Likely to drop more packets from the same flow • Unfair with bursty flows Comnet 2006
Random Early Detection (RED) Comnet 2006
The Advantages of RED • No bias against bursty traffic • No global synchronization • Packet marking probability proportional to connection’s share of bandwidth • Scalable: no per-connection state Comnet 2006
Packet Drops 7 6 5 4 3 2 1 Sender Receiver 1 2 4 5 6 7 ECN 7 6 5 4 3 2 1 Sender Receiver 1 2 3 4 5 6 7 Explicit Congestion Notification (ECN) Comnet 2006
ECN Details • Packets have a special Early Congestion Notification (ECN) bit • The ECN bit is set to 1 • Receivers forward ECN bit state back to sender in acknowledgments • Sender can adjust rate accordingly Comnet 2006