Q1. What are the Method for Handling Deadlock?
Ans. Deadlock problem can be handled in one of three ways:
- We can use a protocol to prevent or avoid deadlock, ensuring that the system will never enter a deadlock state.
- We can allow the system to enter a deadlock state, detect it, and recover.
- We can ignore the problem altogether and pretend that deadlocks never occur in the system
To ensure that deadlocks never occur, the system can use either a deadlock prevention or deadlock avoidance scheme.