What are 2 techniques for the recovery of deadlock
2. Resource preemption
How deadlock detection works
Allow system to enter a deadlock state. There is detection algorithm to detect deadlock. If deadlock found then recovery of system.
What algorithm used for deadlock detection in single instance resource type
Wait-for graph
What are types of nodes in resource allocation graph
Processes and resource
What is available data structure in bankers algorithm
It tells available instances of resources
What are 3 possibilities of invoking deadlock detection algorithm
What are 2 ways in Process termination
2. kill processes one by one and check if system came out of deadlock or not
What is resource preemption
Take resources from process so deadlock break
What is rollback in resource preemption
Process return to some safe state, restart process from that state.
What are 3 main issues in resource preemption