Necessary conditions for Deadlocks
A resource can only be shared in mutually exclusive manner. It implies, if two process cannot use the same resource at the same time.
A process waits for some resources while holding another resource at the same time.
The process which once scheduled will be executed till the completion. No other process can be scheduled by the scheduler meanwhile.
All the processes must be waiting for the resources in a cyclic manner so that the last process is waiting for the resource which is being held by the first process.
- Mutual Exclusion
- Hold and Wait
- No preemption
- Circular Wait