Multicast Odeed Multicast 8 assume: evey ocess belongs to at most one gou 8 oeties FIFO odeing: if a coect ocess issues a multicast(g, m) and then multicast(g, m ), then evey coect ocess that delives m will delive m befoe m causal odeing: if multicast(g, m) multicast(g, m ), whee is induced by message assing only, then evey coect ocess that delives m will delive m befoe m total odeing: if a coect ocess delives m befoe it delives m, then any othe coect ocess that delives m will delive m befoe m 8 notes causal odeing imlies FIFO odeing FIFO odeing and causal odeing ae atial (e-)odes total ode allows abitay odeing of delive events elative to multicast events, as long as this ode is identical in all coect ocesses atomic multicast: eliable, totally odeed multicast Distibuted Systems - Fall 2001 IV - 44 Stefan Leue 2001
Multicast Odeed Multicast 8 imlementing causal odeing (afte Biman et al.) algoithm shown hee ensues comliance with HB-elation only in so fa as it is established by multicast messages, not by individual one-to-one communication each ocess i maintains a vecto clock V ig counting the multicast events that have haened befoe a local multicast event CO-multicast(m, g) iadd one to own timestam V ig [i] ib-multicast message when i attemts to B-delive message fom m (afte eceive) ilace message in hold-back ueue until it is assued that all causally eceding messages have been deliveed, then it may CO-delive the message ito achieve this, conside vecto timestam of eceived message: * wait until i has deliveed any ealie message sent by m, and * i has deliveed any message that m had deliveed at the time it multicast the cuent message iudate own vecto timestam in the m-th osition Distibuted Systems - Fall 2001 IV - 52 Stefan Leue 2001
Multicast Odeed Multicast 8 imlementing causal odeing (afte Biman et al.) Addison-Wesley Publishes 2000 Distibuted Systems - Fall 2001 IV - 53 Stefan Leue 2001
Multicast Odeed Multicast 8 imlementing causal odeing (afte Biman et al.) outline of oof of coectness iassume * mutlicast(g, m) multicast(g, m ) * V and V ae vecto timestams of m and m istaightfowad to ove fom algoithm that V<V * in aticula, if k multicasts m, then V[k] V [k] ican it haen that some coect ocess i B-delives m without fist CO-deliveing m? * by algoithm, V i [k] can incease only when i delives message fom k, * when V i [k] inceases, then it does so by one * howeve, i has not eceived m, and theefoe V i [k] cannot incease beyond V[k]-1 * theefoe not ossible fo i to CO-delive m, since this would euie that V i [k] V [k], and hence that V i [k] V[k] Distibuted Systems - Fall 2001 IV - 54 Stefan Leue 2001
Multicast Odeed Multicast 8 note: combinations ae ossible CO-multicast + TO-multicast (seuence) yields total and causal message delivey iidea: if all ocesses in the same ode, i.e., in the seuences ode, and this ode is causal, then we get total and causal ode 8 extensions to ovelaing gous naive extension: imlement odeings on all ocesses at hand, those that ae not in a aticula gou will discad messages not adessed to them inefficient solution, suggestions to moe efficient solutions exist Distibuted Systems - Fall 2001 IV - 55 Stefan Leue 2001
Gou Communication Multicast communication to gous with dynamic membeshi Gou addess exansion Gou send Multicast communication Leave Fail Gou membeshi management Join Pocess gou Addison-Wesley Publishes 2000 Distibuted Systems - Fall 2001 IV - 56 Stefan Leue 2001
Gou Communication Gou membeshi sevice 8 inteface fo gou membeshi changes ceate, destoy gous add, withdaw ocesses fom gous 8 failue detecto 8 notification of membeshi changes to gou membes 8 gou addess exansion exand gou name into list of delivey addesses since membeshi constantly changes, manage delivey of messages so that consistency euiements ae met Distibuted Systems - Fall 2001 IV - 57 Stefan Leue 2001
Gou Communication Gou views 8 lists of cuent gou membes 8 ocess susected exclusion fom gou view if ocess not failed, o ecoveed, it needs to e-join gou false susicion educes effectiveness of gou Netwok atitions 8 occu when outes o links fail such that two subnets emege that ae no longe connected to each othe 8 gou management in the esence of atitions imay-atition: at most one sub-gou suvives, emaining ocesses told to susend atitionable: subgous suvive as indeendent multicast gous Distibuted Systems - Fall 2001 IV - 58 Stefan Leue 2001
Gou Communication View delivey 8 teat each membe of a gou in a consistent way when gou membeshi changes 8 necessay to elieve ogamme fom ueying state of all othe gou membes befoe making a send decision 8 gou management sevice delives seuence of views to membes, e.g. v 0 (g) = {}, v 1 (g) = {, }, v 2 (g) = {},... 8 system imoses an odeing on the ossibly concuent view changes 8 eceiving/deliveing a view ueue in hold-back ueue as fo multicast until all membes agee to delive the view 8 oeties of view delivey ode: if some ocess delives two views in some ode, then all ocesses in the gou will do so integity: if some delives view of gou g, then g non-tiviality iif joins gou and becomes indefinitely eachable, then will eventually be included in all views iif the gou atitions, then eventually views deliveed in one atition will exclude views deliveed in othe atitions Distibuted Systems - Fall 2001 IV - 59 Stefan Leue 2001
Gou Communication View synchonous gou communication 8 extends eliable multicast semantics to view delivey guaantees not only the above oeties fo view delivey, but also includes guaantees on the delivey of multicast messages 8 guaantees ovided ageement: coect ocesses delive the same set of messages in any given view integity: iif delives m, * then it will not delive m again, and * gou(m), and * m was sulied to gou g by sende(m) validity: coect ocesses always delive the messages that they send iif system fails to delive a message to any ocess * immediately notifies suviving ocesses by deliveing view that excludes * hence, if fo the next view view'(g), then knows that has failed Distibuted Systems - Fall 2001 IV - 60 Stefan Leue 2001
Gou Communication View synchonous gou communication 8 examle: sends m while in view {,, }, cashes soon afte sending. a) If cashes befoe m eaches any of and, then and each delive new view {, } and neithe delives m b) m has eached at least one of and befoe cashes, then and delive fist m, and then view {, } a (allowed). b (allowed). c (disallowed). d (disallowed). Addison-Wesley Publishes 2000 Distibuted Systems - Fall 2001 IV - 61 Stefan Leue 2001
Gou Communication View synchonous gou communication 8 examle: sends m while in view {,, }, cashes soon afte sending. a) If cashes befoe m eaches any of and, then and each delive new view {, } and neithe delives m b) m has eached at least one of and befoe cashes, then and delive fist m, and then view {, } a (allowed). cashes b (allowed). cashes view (,, ) view (, ) view (,, ) view (, ) c (disallowed). d (disallowed). Addison-Wesley Publishes 2000 Distibuted Systems - Fall 2001 IV - 62 Stefan Leue 2001
Gou Communication View synchonous gou communication 8 examle: sends m while in view {,, }, cashes soon afte sending. c) not allowed fo and to fist delive fist view {, } and then m, since this would mean deliveing a message fom a failed ocess d) not allowed to delive the message and then the view in oosite ode, fo the same eason a (allowed). cashes b (allowed). cashes view (,, ) view (, ) view (,, ) view (, ) c (disallowed). d (disallowed). Addison-Wesley Publishes 2000 Distibuted Systems - Fall 2001 IV - 63 Stefan Leue 2001
Gou Communication View synchonous gou communication 8 examle: sends m while in view {,, }, cashes soon afte sending. c) not allowed fo and to fist delive fist view {, } and then m, since this would mean deliveing a message fom a failed ocess d) not allowed to delive the message and then the view in oosite ode, fo the same eason a (allowed). cashes b (allowed). cashes view (,, ) view (, ) view (,, ) view (, ) c (disallowed). cashes d (disallowed). cashes view (,, ) view (, ) Addison-Wesley Publishes 2000 view (,, ) view (, ) Distibuted Systems - Fall 2001 IV - 64 Stefan Leue 2001
Consensus Consensus oblems 8 all coect comutes contolling a saceshi should decide to oceed with landing, o all of them should decide to abot (afte each has oosed one action o the othe) 8 in an electonic money tansfe tansaction, all involved ocesses must consistently agee on whethe to efom the tansaction (debit and cedit), o not 8 in mutual exclusion, ocesses need to agee on which ocess entes citical section 8 in election, ocesses need to agee on elected ocess 8 in totally odeed multicast, ocesses need to agee on a consistent message delivey ode Distibuted Systems - Fall 2001 IV - 65 Stefan Leue 2001