Prerequisite: Deadlock detection in Distributed systems
In hierarchical deadlock detection algorithm, sites are arranged in a hierarchical fashion and a site detects deadlocks involving only its descendant sites. Distributed deadlock algorithms delegate the responsibility of deadlock detection to individual sites while in hierarchical there are local detectors at each site which communicate their local wait for graphs(WFG) with one another.
Deadlocks that are local to a single site are detected at that site using their local WFG. Each site also sends its local WFG to deadlock detector at the next level. Thus, distributed deadlocks involving 2 or more sites would be detected by a deadlock detector in lowest level that has control over these sites.
In this approach, there are 2 methods to detect:
1. Ho-Ramamoorthy algorithm:
- Uses only two levels i.e. Master control nodes and Cluster control nodes.
- Cluster control nodes are used for detecting deadlock among their members and reporting dependencies outside their cluster to Master control node.
- The master control node is responsible for detecting inter-cluster deadlocks.
2. Menasce-Muntz algorithm:
- Leaf controllers are responsible for allocating resources whereas branch controllers find deadlock among the resources that their children span in the tree.
- Network congestion can be managed and node failure is less critical than in fully centralized.
- Detection can be done ways such as Continuous allocation reporting or periodically allocation reporting.
- If the hierarchy coincides with resource access pattern local to cluster of sites, this approach can provide efficient deadlock detection as compared to both centralized and distributed methods.
- It reduces the dependence on central sites thus, reducing the communication cost.
- If deadlocks are span over several clusters, this approach will be inefficient.
- It is more complicated to implement and would involve nontrivial modification to lock and transaction manager algorithms.
Attention reader! Don’t stop learning now. Get hold of all the important CS Theory concepts for SDE interviews with the CS Theory Course at a student-friendly price and become industry ready.
- Deadlock detection in Distributed systems
- Chandy-Misra-Haas's Distributed Deadlock Detection Algorithm
- Mutual exclusion in distributed system
- Maekawa’s Algorithm for Mutual Exclusion in Distributed System
- Ricart–Agrawala Algorithm in Mutual Exclusion in Distributed System
- Lamport's Algorithm for Mutual Exclusion in Distributed System
- Suzuki–Kasami Algorithm for Mutual Exclusion in Distributed System
- Difference between Token based and Non-Token based Algorithms in Distributed System
- Limitation of Distributed System
- Features of Distributed Operating System
- Various Failures in Distributed System
- Logical Clock in Distributed System
- Hashing in Distributed Systems
- Advantages of Distributed database
- Comparison - Centralized, Decentralized and Distributed Systems
- Algorithm for implementing Distributed Shared Memory
- Difference between Network OS and Distributed OS
- Interprocess Communication in Distributed Systems
- Implementation of Access Matrix in Distributed OS
- Synchronization in Distributed Systems
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.