Cs 525 advanced distributed systems spring 09 l.jpg
This presentation is the property of its rightful owner.
Sponsored Links
1 / 40

CS 525 Advanced Distributed Systems Spring 09 PowerPoint PPT Presentation


  • 213 Views
  • Uploaded on
  • Presentation posted in: General

CS 525 Advanced Distributed Systems Spring 09. (gatorlog.com). (epath.org). Indranil Gupta Lecture 7 More on Epidemics (or “Tipping Point Protocols”) February 12, 2009. Question…. What fraction of main roads need to be randomly knocked out before

Download Presentation

CS 525 Advanced Distributed Systems Spring 09

An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -

Presentation Transcript


Cs 525 advanced distributed systems spring 09 l.jpg

CS 525 Advanced Distributed SystemsSpring 09

(gatorlog.com)

(epath.org)

Indranil Gupta

Lecture 7

More on Epidemics (or “Tipping Point Protocols”)

February 12, 2009


Question l.jpg

Question…

What fraction of main roads need to be randomly knocked out before

source and destination are completely cut off?

Source

Destination


Critical value answer 0 5 l.jpg

Tipping Point!

Critical Value? Answer = 0.5

Source

Destination

(Comes from Percolation Theory)


Tipping point l.jpg

“Tipping Point”

[Malcolm Gladwell, The Tipping Point, Little Brown and Company, ISBN: 0316346624]

Tipping is that (magic) moment when an idea, trend or social behavior crosses a threshold, and spreads like wildfire.


Epidemic protocols l.jpg

Epidemic Protocols

  • A specific class of tipping point protocols

  • Local behavior at each node – probabilistic

  • Determines global, emergent behavior at the scale of the distributed system

  • As one tunes up the local probabilities, the global behavior may undergo a threshold behavior (or, a phase change)

  • Three papers:

    • Epidemic algorithms

    • Bimodal multicast

    • PBBF (sensor networks)


Epidemic algorithms for replicated database maintenance l.jpg

Epidemic Algorithms for Replicated Database Maintenance

Alan Demers et. al.

Xerox Palo Alto Research Center

PODC 1987

[Some slides borrowed from presentation by: R. Ganti and P. Jayachandran]


Introduction l.jpg

Introduction

  • Maintain mutual consistency of updates in a distributed and replicated database

  • Used in Clearinghouse database – developed in Xerox PARC and used for many years

  • First cut approaches

    • Direct mail: send updates to all nodes

      • Timely and efficient, but unreliable

    • Anti-entropy: exchange database content with random site

      • Reliable, but slower than direct mail and uses more resources

    • Rumor mongering: exchange only ‘hot rumor’ updates

      • Less reliable than anti-entropy, but uses fewer resources


Epidemic multicast l.jpg

(from Lecture 1)

Epidemic Multicast

Infected

Protocol rounds (local clock)

b random targets per round

Gossip Message (UDP)

Uninfected


Epidemic multicast push l.jpg

Epidemic Multicast (Push)

Infected

Protocol rounds (local clock)

b random targets per round

Gossip Message (UDP)

Uninfected


Epidemic multicast pull l.jpg

Epidemic Multicast (Pull)

Infected

Gossip Message (UDP)

Uninfected

Protocol rounds (local clock)

b random targets per round


Pull push l.jpg

Pull > Push

pi – Probability that a node is susceptible after the ith round

  • Pull converges faster than push, thus providing better delay

  • Push-pull hybrid variant possible (see Karp and Shenker’s “Randomized Rumor Spreading”)

Pull

Push


Anti entropy optimizations l.jpg

Anti-entropy: Optimizations

  • Maintain checksum, compare databases if checksums unequal

  • Maintain recent update lists for time T, exchange lists first

  • Maintain inverted index of database by timestamp; exchange information in reverse timestamp order, incrementally re-compute checksums


Epidemic flavors l.jpg

Epidemic Flavors

  • Blind vs. Feedback

    • Blind: lose interest to gossip with probability 1/k every time you gossip

    • Feedback: Loss of interest with probability 1/k only when recipient already knows the rumor

  • Counter vs. Coin

    • Coin: above variants

    • Counter: Lose interest completely after k unnecessary contacts. Can be combined with blind.

  • Push vs. Pull


Deletion and death certificates l.jpg

Deletion and Death Certificates

  • Absence of item does not spread; On the contrary, it can get resurrected!

  • Use of death certificates (DCs) – when a node receives a DC, old copy of data is deleted

  • How long to maintain a DC?

    • Typically twice (or some multiple of) the time to spread the information

    • Alternately, use Chandy and Lamport snapshot algorithm to ensure all nodes have received

    • Certain sites maintain dormantDCs for a longer duration; re-awakened if item seen again


Performance metrics l.jpg

Performance Metrics

  • Residue: Fraction of susceptibles left when epidemic finishes

  • Traffic: (Total update traffic) / (No. of sites)

  • Delay: Average time for receiving update and maximum time for receiving update

  • Some results:

    • Counters and feedback improve delay

    • Pull provides lower delay than push


Performance evaluation l.jpg

Performance Evaluation

Tipping Point Behavior


Discussion l.jpg

Discussion

Pick your favorite:

  • Push vs. pull vs. push-pull

    • Name one disadvantage of each

  • Direct mail vs. anti-entropy vs. rumor mongering

    • Name one disadvantage of each

  • Random neigbhor picking

    • Disadvantage in wired networks?

    • In Sensor network?


Bimodal multicast l.jpg

Bimodal Multicast

Kenneth P. Birman et. al.

ACM TOCS 1999

[Some slides borrowed from presentation by: W. Fagen and L. Cook]


Traditional multicast protocols l.jpg

“Traditional” Multicast Protocols


Vs pbcast l.jpg

Atomicity: All or none delivery

Multicast stability: Reliable immediately delivery of messages

Scalability: Bad. Costs >= quadratic with group size.

Ordering

Atomicity: Bimodal delivery guarantee, almost all or almost none (immediately)

Multicast stability: Reliable eventual delivery of messages

Scalability: Costs logarithmic w.r.t. network size. Throughput stability.

Ordering

Vs. Pbcast

Traditional Multicast

Pbcast


Pbcast probabilistic broadcast protocol l.jpg

Pbcast: Probabilistic Broadcast Protocol

  • Pbcast has two stages:

    • Unreliable, hierarchical, best-effort broadcast. Eg. IP Multicast

    • Two-phase anti-entropy protocol: runs simultaneously with the broadcast messages

      • First phase detects message loss

      • Second phase corrects such losses


The second stage l.jpg

The second stage

  • Anti-entropy round:

    • Gossip Messages:

      • Each process chooses another random process and sends a summary of its recent messages

    • Solicitation Messages:

      • Messages sent back to the sender of the gossip message requesting a resend of a given set of messages (not necessarily the original source)

    • Message Resend:

      • Upon reception of a solicitation message, the sender resends that message

  • Protocol parameters at each node

    • # of rounds and # of processes contacted in each round

    • Product of above two parameters called fanout


Optimizations l.jpg

Optimizations

  • Soft-Failure Detection: Retransmission requests served only if received recently; protects against congestion caused due to redundant retransmissions

  • Round Retransmission Limit: Limit the no. of retransmissions in a round; spread overhead in space and time

  • Most-Recent-First Retransmission: prefer recent messages

  • Independent Numbering of Rounds: Allows delivery and garbage collection to be entirely a local decision

  • Multicast for Some Retransmissions


Bimodality of pbcast l.jpg

Bimodality of Pbcast

Logarithmic

Y-axis

Almost none

Almost all


Latency for delivery l.jpg

Latency for Delivery

Logarithmic growth


Throughput comparison l.jpg

Throughput Comparison


Discussion27 l.jpg

Discussion

  • Disadvantages of Bimodal Multicast?

    • When would wasteful messages be sent?

  • What happens when

    • Rate of injection of multicasts is very very low?

    • IP multicast is very very reliable?

    • IP multicast is very very unreliable?


Pbbf probability based broadcast forwarding l.jpg

PBBF: Probability-Based Broadcast Forwarding

Cigdem Sengul and Matt Miller

ICDCS 2005 and ACM TOSN 2008

(Originated from a 525 Project)


Broadcast in an ad hoc network l.jpg

Broadcast in an Ad-Hoc Network

  • Ad-hoc sensor network (Grid example below)

  • One node has a piece of information that it needs to broadcast: e.g., (1) code update, (2) query

  • Simple approach: each node floods received message to all its neighbors

    • Disadvantages?


Ieee 802 11 psm l.jpg

IEEE 802.11 PSM

A real, stable MAC protocol (similar results for S-MAC, T-MAC, etc.)

  • Nodes are assumed to be synchronized

  • Every beacon interval (BI), all nodes wake up for an ATIM window (AW)

  • During the AW, nodes advertise any traffic that they have queued

  • After the AW, nodes remain active if they expect to send or receive data based on advertisements; otherwise nodes return to sleep until the next BI


Protocol extreme 1 l.jpg

N2

N1

N3

A

D

A

D

A

D

A

Protocol Extreme #1

N1

N2

N3

= ATIM Pkt

= Data Pkt


Protocol extreme 2 l.jpg

N2

N1

N3

D

A

D

D

D

A

Protocol Extreme #2

N1

N2

N3

= ATIM Pkt

= Data Pkt


Probability based broadcast forwarding pbbf l.jpg

Probability-Based Broadcast Forwarding (PBBF)

  • Introduce two parameters to sleep scheduling protocols: p and q

  • When a node is scheduled to sleep, it will remain active with probability q

  • When a node receives a broadcast, it rebroadcasts immediately with probability p

    • With probability (1-p), the node will wait and advertise the packet during the next AW before rebroadcasting the packet


Analysis reliability l.jpg

Analysis: Reliability

Tipping Point!

  • Phase transition when:

    pq + (1-p) ≈ 0.8-0.85

  • Larger than traditional bond percolation threshold

    • Boundary effects

    • Different metric

  • Still shows phase transition

p=0.25

p=0.37

Fraction of Broadcasts

Received by 99% of Nodes

p=0.5

p=0.75

q


Application energy and latency l.jpg

Application: Energy and Latency

Energy

Joules/Broadcast

Latency

Average 5-Hop Latency

PBBF

Increasing p

q

q

≈ 1 + q * [(BI - AW)/AW]

  • Ns2 simulation: 50 nodes, uniform placement, 10 avg. neighbors


Adaptive pbbf l.jpg

Adaptive PBBF

Achievable

Region

Energy

Latency


Adaptive pbbf tosn paper l.jpg

Adaptive PBBF (TOSN paper)

1.0

  • Dynamically adjusting p and q to converge to user-specified QoS metrics

    • Code updates prefer reliability overl latency

    • Queries prefer latency over reliability

  • Can specify any 2 of energy, latency, and reliability

  • Subject to those constraints, p and q are adjusted to achieve the highest reliability possible

q

0.5

p

0.0

Time


Discussion38 l.jpg

Discussion

  • PBBF: bond percolation (remove roads from city)

  • Haas et al paper (Infocom): site percolation

    • Remove intersections/junctions (not roads) from city

  • Site percolation and bond percolation have different thresholds and behaviors

  • Hybrid possible? (like push-pull?)

  • What about over-hearing optimizations? (like feedback)


Question39 l.jpg

Question…

Are there other tipping point protocols…?

Source

Destination


Next week onwards l.jpg

Next Week Onwards

  • Student Presentations start (see instructions)

  • Reviews needed (see instructions)

  • Project Meetings start (see newsgroup)

    • Think about which testbed you need access to: PlanetLab, Emulab, Cirrus

  • Tomorrow: Yahoo! Training seminar


  • Login