Outline Distributed Mutual Exclusion Tokenbased algorithms Distributed Deadlock
Outline • Distributed Mutual Exclusion – Token-based algorithms • Distributed Deadlock Detection – Review and overview • Agreement Protocols – Introduction – Lamport-Shostak-Pease algorithm – Dolev et al’s algorithm – Applications of agreement protocols 9/9/2020 COP 5611 1
Announcements • There will be a quiz next Tuesday – It will be an open book quiz – It covers the things we have covered so far – It will be at the end of the class • You can turn in your homework #2 next Tuesday – However, no submission after that date will be accepted • Please do not run your programs on diablo 9/9/2020 COP 5611 2
Distributed Deadlock Detection • In distributed systems, the system state can be represented by a wait-for graph (WFG) – In WFG, nodes are processes and there is a directed edge from node P 1 to node P 2 if P 1 is blocked and is waiting for P 2 to release some resource – The system is deadlocked if there is a directed cycle or knot in its WFG – The problem is how to maintain the WFG and detect cycle/knot in the graph 9/9/2020 COP 5611 3
Distributed Deadlock Detection – cont. • Centralized detection algorithms • Distributed deadlock algorithms – Path-pushing – Edge-chasing – Diffusion computation – Global state detection – You need to know the basic ideas but not the details about those algorithms 9/9/2020 COP 5611 4
Agreement Protocols • In distributed systems, sites are often required to reach mutual agreement – In distributed database systems, data managers must agree on whether to commit or to abort a transaction – Reaching an agreement requires the sites have knowledge about values at other sites • Agreement when the system is free from failures • Agreement when the system is prone to failure 9/9/2020 COP 5611 5
The System Model • There are n sites in the distributed system and at most m can be faulty • Each site can communicate with all other sites through message passing • A receiver always knows the identity of the sender of a message • The communication is reliable 9/9/2020 COP 5611 6
The System Model – cont. • Synchronous vs. asynchronous computations – In a synchronous computation, processes in the distributed system run in lock step manner – In each step, a process receives messages from other sites sent in the previous step, performs a computation, and sends messages to other processes 9/9/2020 COP 5611 7
The System Model – cont. • Processor Failures – Crash fault – Omission fault – Malicious fault • Authenticated vs. non-authenticated messages 9/9/2020 COP 5611 8
The System Model – cont. • Performance Analysis – Time to reach an agreement under a given protocol – Message traffic measured by the number of messages exchanged to reach an agreement – Storage overhead 9/9/2020 COP 5611 9
Agreement Problems • There are three well known agreement problems – Byzantine agreement problem – Consensus problem – Interactive consistency problem 9/9/2020 COP 5611 10
Byzantine Agreement Problem • A chosen process, called source process, broadcasts initial value to all other processes • A solution should 9/9/2020 COP 5611 11
The Consensus Problem • In this problem, every process broadcasts initial value to all other processes, where the initial values of different processes can be different 9/9/2020 COP 5611 12
The Interactive Consistency Problem • In this problem, every process broadcasts initial value to all other processes, where the initial values of different processes can be different 9/9/2020 COP 5611 13
Lamport-Shostak-Pease Algorithm 9/9/2020 COP 5611 14
Lamport-Shostak-Pease Algorithm – cont. 9/9/2020 COP 5611 15
Lamport-Shostak-Pease Algorithm – cont. • Performance analysis – Time – Message traffic – Storage overhead 9/9/2020 COP 5611 16
Fault-Tolerant Clock Synchronization • The interactive convergence algorithm 9/9/2020 COP 5611 17
Fault-Tolerant Clock Synchronization – cont. • The interactive consistency algorithm 9/9/2020 COP 5611 18
- Slides: 18