Download presentation
Presentation is loading. Please wait.
1
1 Lecture 6: Multicast l Challenge: how do we efficiently send messages to a group of machines? n Need to revisit all aspects of networking n Last time –Routing n This time –Reliable delivery –Ordered delivery –Congestion control
2
2 Multicast Address Allocation l Unicast IP addresses n allocated statically to hosts n allocated hierarchically by hosts’ org l Multicast IP addresses n allocated per connection n groups cross admin boundaries
3
3 Address Allocation Solutions l Central server? n Blocks of addresses for internal groups n Leases for global addresses l Random allocation? n Send to group to ask if address is in use n Need conflict resolution protocol
4
4 Scope Control Motivation l Efficiency with reverse path multicast n sender prunes receivers l Administrative control over listeners n anyone can listen to multicast conversation! n snooping more difficult in unicast l Coordinate sub-group actions n elect a leader/suppress duplicate actions n locate nearest receiver
5
5 Scope Control Mechanism #1 l Administrative TTL boundaries n Sender uses TTL = max local diameter n At border router, forward pkts out iff > TTLmax Internet s TTL thresh = 8
6
6 Scope Control Mechanism #2 l Allocate block of “local” addresses n At border router, forward only global addresses Internet s Don’t forward addresses 0xffff0000-0xffff2000
7
7 Expanding Ring Multicast l Locate “nearest” receiver by sending to more and more of group s g g g g g TTL=1 TTL=3 TTL=5 TTL=2 g g
8
8 Reliable Multicast l How do we make sure each receiver gets a copy of each message? R R R Sender R R
9
9 Ack Implosion l If each receiver acks each packet, sender gets overwhelmed! R R R Sender R R
10
10 Negative Acks l Possible solution: only send back to source if missing data n missing sequence number (2, 3, 5, 6, 7, …) n ping if no data being sent, to detect if missing last packet l Fewer packets if losses are infrequent n note TCP uses acks for pacing new sends
11
11 Nack Implosion l If lose packet near sender, overwhelm sender with nacks! R R R Sender R R X
12
12 Hop by Hop Retransmission l Router keeps copy of all packets l Resends if negative ack or timeout R R R Sender R R X retransmission
13
13 Scalable Reliable Multicast l Use multicast services to recover from packet losses! n If missing packet, multicast NACK –anyone get the packet? –Tell others to suppress NACK n Receivers with packet will multicast reply –anyone else missing the packet? –Tell others to suppress reply l Assumes packets are signed by source
14
14 SRM Scalability? l If everyone multicasts NACK n NACK implosion everywhere! l If everyone multicasts reply n data implosion everywhere! l Goal: minimize simultaneous NACKs and replies
15
15 SRM Scalability l Use random delay before sending NACK/reply n less likely for more than one to send at once l Bias delay to reduce competition n NACK delay based on distance to source n Reply delay based on distance to NACK n distance est. using periodic session msgs l Doesn’t matter which host NACKs, replies
16
16 SRM Example l R3 detects loss, multicasts NACK l R1 sees NACK, multicasts reply R5 R2 R4 Sender R3 R1 X
17
17 SRM Timer Adaptation l Want system to be robust to topologies, group sizes, congestion n Adapt average delays to minimize redundant NACKs, replies n Analogous to RTT estimation in TCP l Examples n if too many NACKs, increase average delay n if NACK once, reduce delay so NACK again
18
18 What if multiple drops? l Can use TTL expanding ring search for local recovery R R R Sender R R R R X X X
19
19 SRM Evaluation l Scalability? n What happens as we increase # of hosts? n What about diversity of link bandwidths? l Stability? n What happens as load increases? l Security n reply with corrupted packet n denial of service => NACK everything!
20
20 Application Level Framing l Allow application to control how data is packetized on network n each RPC, object on packet boundaries n by contrast, TCP/IP transmits byte stream l Advantages? l Disadvantages?
21
21 Multicast Packet Ordering l Easy to order unicast packets => seq #s l Easy to order multicast packets from a single source => seq #s l What if multiple sources? n Packets can arrive in different order at different receivers n Is this bad? n If so, what can we do to fix it?
22
22 Multicast Ordering Example s s g g g g abc xyz axbycz abxcyz abcxyz xyzabc g g xaybzc
23
23 Example: Email Groups A C B D Meet for lunch? Need to hold design review Meet at noon? Noon for what? Confirmed! Oh, ok! Anytime other than noon!
24
24 Example: Deterministic Replicas l Replicate server for higher throughput, fault tolerance n Read from any replica n Write to all replicas l How do we keep replicas consistent? n Provide all replicas exactly same sequence of messages n Each replica behaves deterministically, reaches same state as all other replicas
25
25 Multicast Total Ordering l All packets are delivered in same order everywhere l Single seq # for all packets to group n every source sends packets to arbiter n arbiter assigns sequence # n if arbiter fails, elect new one n receivers don’t process packets out of order
26
26 Multicast Causal Ordering l Total ordering inefficient for subcasts l Instead, causal ordering n packets are never delivered before packets that could have “caused” them –receiver must have gotten all the packets source has seen n packets that originate concurrently can be delivered in any order
27
27 Implementing Causal Ordering l Packets carry per-host sequence # n increment on each send l Each host maintains a “version vector” n max seq #’s seen (in order) from each host n put version vector in each outgoing packet l At receiver, delay packet until host vector > packet vector, for all sources
28
28 Causal Ordering Example A C B D Meet for lunch? Need to hold design review Meet at noon? Defer packet Confirmed! 11 am? Anytime other than 11am! 0,0,0,0 0,1,0,0 0,0,0,1 0,1,1,0 How about noon?
29
29 Multicast Congestion Control l What if receivers have very different bandwidths? l Send at max? l Send at min? l Send at avg? R R R S 100Mb/s 1Mb/s 56Kb/s R
30
30 Layered Multimedia l Transmit signal at multiple granularities n 56Kb/s - voice only n 1Mb/s - choppy video n 100Mb/s - high quality video l Layers can be n independent (redundant) n dependent (progressive refinement)
31
31 Drop Policies for Layered Multicast l Priority n packets for low bandwidth layers are kept, drop queued packets for higher layers n requires router support (hard to deploy!) n wastes upstream resources l Uniform (e.g., drop tail, RED) n packets arriving at congested router are dropped regardless of their layer
32
32 Receiver-Driven Layered Multicast l Each layer a separate group n receiver subscribes to max group that will get through with minimal drops l Dynamically adapt to available capacity n use packet losses as congestion signal l Assume no special router support n packets dropped independently of layer
33
33 How does receiver know which layers to add? l User decides based on observed quality? n Won’t add layer if no benefit l System dynamically adapts to available capacity n Use packet drops as congestion signal n No drops => try subscribing to higher layer n Drops => unsubscribe to layer
34
34 RLM Join Experiment l Receivers periodically try subscribing to higher layer l If enough capacity, no congestion, no drops => keep layer (& try next layer) l If not enough capacity, congestion, drops => drop layer (& increase time to next retry) n what about impact on other receivers?
35
35 RLM Join Example R4 R1 R3 S 100Mb/s 1Mb/s 56Kb/s R2 R4 joins layer 1, fails at layer 2 R2,R3 join layer 1, join layer 2 fails at layer 3 R1 joins layer 1, joins layer 2 joins layer 3
36
36 RLM Scalability? l What happens with more receivers? l Increased frequency of experiments? n more likely to conflict (false signals) n network spends more time congested l Reduce # of experiments per host? n Takes longer to converge
37
37 RLM Receiver Coordination l Receiver advertises intent to add layer l Other receivers n avoid conflicting experiments n if experiment fails, will see increased drops => don’t try adding layer! (shared learning) n OK to try adding lower layer during higher layer experiment –won’t cause drops at higher layer!
38
38 RLM Interactions l With other multicast groups? l With unicast TCP traffic? l With RED? l With fair queuing? l With priority for lower layers?
39
39 Drop Policies for Layered Multicast l Priority n packets for low bandwidth layers are kept, drop queued packets for higher layers l Uniform n packets arriving at congested router are dropped regardless of their layer l Which is better? n Intuition vs. reality!
40
40 RLM Intuition l Uniform offers better incentives to well- behaved users n if oversend, performance rapidly degrades l Uniform offers clearer congestion signal n allows shared learning l RLM approaches optimal operating point n uniform is already deployed
41
41 RLM Intuition
42
42 Bajaj et al. Intuition l Priority offers much better performance n particularly with bursty traffic l RLM will perform badly with bursty traffic n unable to adapt to congestion transients l Uniform offers better incentives n but socially optimal != individually optimal
43
43 Bajaj et al. Intuition
44
44 Model Details l Compare alternatives using total utility l Utility of low layers > utility of high layers l Utility of layer even if some drops n independent of drops on other layers l Drop tail router l Both simulation and analytical model
45
45 Model Results l Smooth traffic: RLM is close to optimal l Bursty traffic: RLM < uniform < priority n but not by much! n RLM worse if low layers not valuable l Incentive to oversubscribe with both uniform and priority l Slight disincentive to send/receive => individual = socially optimal
46
46 Multicast Summary l Multicast needed for efficiency, group coordination l Need to revisit all aspects of networking n Routing n Administration n Reliable delivery n Ordered delivery n Congestion control
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.