Message Passing Systems A Formal Model. The System Topology – network (connected undirected graph) Processors (nodes) Communication channels (edges) Algorithm.

Slides:



Advertisements
Similar presentations
Chapter 5: Tree Constructions
Advertisements

Global States.
Lecture 8: Asynchronous Network Algorithms
Distributed Computing 1. Lower bound for leader election on a complete graph Shmuel Zaks ©
Chapter 15 Basic Asynchronous Network Algorithms
Distributed Computing 8. Impossibility of consensus Shmuel Zaks ©
Self Stabilizing Algorithms for Topology Management Presentation: Deniz Çokuslu.
Outline. Theorem For the two processor network, Bit C(Leader) = Bit C(MaxF) = 2[log 2 ((M + 2)/3.5)] and Bit C t (Leader) = Bit C t (MaxF) = 2[log 2 ((M.
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS Fall 2011 Prof. Jennifer Welch CSCE 668 Self Stabilization 1.
Distributed Computing 8. Impossibility of consensus Shmuel Zaks ©
Global State Collection. Global state collection Some applications - computing network topology - termination detection - deadlock detection Chandy-Lamport.
CPSC 668Set 14: Simulations1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
Università degli Studi dell’Aquila Academic Year 2009/2010 Course: Algorithms for Distributed Systems Instructor: Prof. Guido Proietti Time: Monday:
1 Complexity of Network Synchronization Raeda Naamnieh.
CPSC 668Set 1: Introduction1 CPSC 668 Distributed Algorithms and Systems Fall 2006 Prof. Jennifer Welch.
Ordering and Consistent Cuts Presented By Biswanath Panda.
Distributed systems Module 2 -Distributed algorithms Teaching unit 1 – Basic techniques Ernesto Damiani University of Bozen Lesson 3 – Distributed Systems.
CPSC 668Set 2: Basic Graph Algorithms1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
CPSC 668Set 3: Leader Election in Rings1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
CPSC 668Set 9: Fault Tolerant Consensus1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
CPSC 668Set 16: Distributed Shared Memory1 CPSC 668 Distributed Algorithms and Systems Fall 2006 Prof. Jennifer Welch.
LSRP: Local Stabilization in Shortest Path Routing Hongwei Zhang and Anish Arora Presented by Aviv Zohar.
CPSC 668Self Stabilization1 CPSC 668 Distributed Algorithms and Systems Spring 2008 Prof. Jennifer Welch.
Impossibility of Distributed Consensus with One Faulty Process Michael J. Fischer Nancy A. Lynch Michael S. Paterson Presented by: Oren D. Rubin.
Distributed Algorithms (22903) Lecturer: Danny Hendler Leader election in rings This presentation is based on the book “Distributed Computing” by Hagit.
Distributed systems Module 2 -Distributed algorithms Teaching unit 1 – Basic techniques Ernesto Damiani University of Bozen Lesson 4 – Consensus and reliable.
 Idit Keidar, Principles of Reliable Distributed Systems, Technion EE, Spring Principles of Reliable Distributed Systems Lecture 6: Impossibility.
 Idit Keidar, Principles of Reliable Distributed Systems, Technion EE, Spring Principles of Reliable Distributed Systems Lecture 12: Impossibility.
Tirgul 7 Review of graphs Graph algorithms: – BFS (next tirgul) – DFS – Properties of DFS – Topological sort.
Composition Model and its code. bound:=bound+1.
Message Passing Systems A Formal Model. The System Topology – network (connected undirected graph) Processors (nodes) Communication channels (edges) Algorithm.
Distributed Algorithms 2014 Igor Zarivach A Distributed Algorithm for Minimum Weight Spanning Trees By Gallager, Humblet,Spira (GHS)
Selected topics in distributed computing Shmuel Zaks
Introduction Distributed Algorithms for Multi-Agent Networks Instructor: K. Sinan YILDIRIM.
Formal Model for Simulations Instructor: DR. Lê Anh Ngọc Presented by – Group 6: 1. Nguyễn Sơn Hùng 2. Lê Văn Hùng 3. Nguyễn Xuân Hậu 4. Nguyễn Xuân Tùng.
Università degli Studi dell’Aquila Academic Year 2012/2013 Course: Algorithms for Distributed Systems Instructor: Prof. Guido Proietti Schedule: Monday:
CS4231 Parallel and Distributed Algorithms AY 2006/2007 Semester 2 Lecture 10 Instructor: Haifeng YU.
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS Spring 2014 Prof. Jennifer Welch CSCE 668 Set 1: Introduction 1.
Computer Science and Engineering Parallel and Distributed Processing CSE 8380 February 10, 2005 Session 9.
SEMINAR OPEN PROBLEMS IN DISTRIBUTED COMPUTING Winter Hagit Attiya & Faith Ellen Introduction1.
DISTRIBUTED ALGORITHMS AND SYSTEMS Spring 2014 Prof. Jennifer Welch Set 11: Asynchronous Consensus 1.
DISTRIBUTED SYSTEMS II A POLYNOMIAL LOCAL SOLUTION TO MUTUAL EXCLUSION Prof Philippas Tsigas Distributed Computing and Systems Research Group.
DISTRIBUTED ALGORITHMS AND SYSTEMS Spring 2014 Prof. Jennifer Welch CSCE
Leader Election. Leader Election: the idea We study Leader Election in rings.
CS294, Yelick Consensus revisited, p1 CS Consensus Revisited
Chap 15. Agreement. Problem Processes need to agree on a single bit No link failures A process can fail by crashing (no malicious behavior) Messages take.
Several sets of slides by Prof. Jennifer Welch will be used in this course. The slides are mostly identical to her slides, with some minor changes. Set.
DISTRIBUTED ALGORITHMS Spring 2014 Prof. Jennifer Welch Set 2: Basic Graph Algorithms 1.
Vertex Coloring Distributed Algorithms for Multi-Agent Networks
Global State Collection
Impossibility of Distributed Consensus with One Faulty Process By, Michael J.Fischer Nancy A. Lynch Michael S.Paterson.
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS Spring 2014 Prof. Jennifer Welch CSCE 668 Set 3: Leader Election in Rings 1.
Fault tolerance and related issues in distributed computing Shmuel Zaks GSSI - Feb
DISTRIBUTED ALGORITHMS Spring 2014 Prof. Jennifer Welch Set 9: Fault Tolerant Consensus 1.
Fault tolerance and related issues in distributed computing Shmuel Zaks GSSI - Feb
Hwajung Lee. Some applications - computing network topology - termination detection - deadlock detection Chandy Lamport algorithm does a partial job.
1 Chapter 11 Global Properties (Distributed Termination)
Distributed Algorithms (22903) Lecturer: Danny Hendler Leader election in rings This presentation is based on the book “Distributed Computing” by Hagit.
Introduction to distributed systems description relation to practice variables and communication primitives instructions states, actions and programs synchrony.
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS
Distributed Algorithms (22903)
ITEC452 Distributed Computing Lecture 9 Global State Collection
Formal Models of Distributed Systems
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS
Parallel and Distributed Algorithms
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS
Global State Collection
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS
Distributed Algorithms (22903)
CSCE 668 DISTRIBUTED ALGORITHMS AND SYSTEMS
Presentation transcript:

Message Passing Systems A Formal Model

The System Topology – network (connected undirected graph) Processors (nodes) Communication channels (edges) Algorithm : A local program for each processor

Notation n processors: p 0, p 1, …, p n-1. Q i : the state set for p i. Orientation: A numbering of the edges incident to p i, from 1 to r. outbuf i [l], inbuf i [l].

Initialization Qi has a subset of initial states. inbuf i [l] is empty. outbuf i [l] not necessarily empty.

More Definitions The accessible state of p i : Q i together with inbuf i [l] for all l. Transition function (relation) of p i : From: The accessible states of p i. To : Qi. inbufi[l] empty for all l. At most one message added to each outbuf i [l].

Configuration A vector [q 0,q 1,…,q n-1 ] where q i is a state of p i outbuf i [l] inbuf i [l] An initial configuration

Events Computation : comp(i) Delivery : del(i,j,m)

Execution C 0  1 C 1  2 C 2  3 … C i : A configuration  i : An event C 0 : An initial configuration

Conditions Safety Conditions (Nothing bad happens) Liveness Conditions (Something good happens) – Termination ?

Asynchronous Systems No Upper bound on times Delivery Consecutive steps of processors Why Asynchronous algorithms ? Schedule :  =  1  2  3 … Not every sequence is a schedule: del (1,2,m)

Asynchronous Systems (Contd.) exec (C 0,  ) Admissible executions Infinitely many comp(i) events for each i. Each message sent is eventually delivered.

Synchronous Systems Rounds. A round: comp(i) events for each i. del events for each message sent in the round. Admissible execution: infinite.

Message Complexity The total number of messages sent during any admissible execution of the algorithm. In other words, the number of delivery events.

Time Complexity Synchronous: The number of rounds until termination. Asynchronous : A time t i is associated with every event  i : t i+1 >= t i. t i grow w/o bound in any infinite execution. t i = t i+1 only if they occur in the same processor.

Time Complexity (Contd.) Delay(m) = t j -t i where  i and  j are comp events m is sent in  i m is processed in  j Given any execution, normalize time s.t. the maximum delay is 1 (Execution is infinite, but the number of messages is finite). Time Complexity: The time at termination.

Time Complexity We prove by induction on d that: A processor at distance d from r receives the message M by time d. For the synchronous case we prove that it is received exactly at time t.

Pseudo Code Conventions We may describe the effect of any subset of messages in inbuf in separate code fragments for clarity, but.. The processor will execute the codes corresponding to all the messages in inbuf. The subscript i is omitted. Terminate brings the processor to a termination state.

Pseudo Code for PI (Flooding) Upon receiving no message:

Pseudo Code for PI (Flooding) Upon receiving M from neighbor p j :

Pseudo Code for PI (Flooding) Upon receiving PARENT from neighbor p j : Upon receiving REJECT from neighbor p j :

Correctness By code inspection, at each processor: Once parent is set, it is never changed. If parent set then. If i=r, parent=i. Otherwise, parent != i. The set children never decreases. The set other never decreases.

Correctness (cont’d) Eventually: At processor p r,parent=r. (immediate) At other processors, parent != nil Assume a processor with parent=nil, Consider a path from p r to to this processor. Let p the first processor on this path with parent = nil, and q the processor before it. (Both exist). Consider what happened when q set its parent variable…

Correctness (cont’d) The graph defined by the parent variables: (without the self loop). Has n-1 edges Has no cycles: Assume a cycle of length l < n. p r is not in the cycle. Consider the computation events in any admissible schedule which caused to parent = ? There are l such events. Consider the first event. Contradiction.

Distributed Computing Fundamentals, Simulations and Advanced Topics H. Attiya and J. Welch Section 2.1