Define and explain Deadlock and its conditions

March 28, 2016
Deadlock Condition - Vehicle on Deadlock
Deadlock Situation
In Operating System, Deadlock is a non-resolving condition in which two or more competing actions are each waiting for the other to finish and thus neither ever does. However, deadlock condition must be prevented before it falls.

Basically, computer system make of resources; the resources of computer system can be categorized into different two types - Software Resources and Hardware Resources. Hardware Resources are external memory, printer, scanner etc. Software Resources are some applications, such as microsoft words, excel, adobe Photoshop etc. In the real time operation, each and every process needs resources that is why process shares the resource to complete the job mostly in multiprogramming system.

In conclusion, deadlock is only then arise if there are 2 process sharing the same resources, in which one process waits to use a resource which is using by another process whereas it itself does not release its own resource.

According to Coffman, deadlock has 4 conditions. They are:
  1. Mutual exclusion condition
  2. Hold and Wait Process
  3. No-preemption condition
  4. Circular wait condition
Conditions are the facts that must be available to occur a particular action. In the first point of above list of deadlock condition, there is a point "Mutual exclusion condition". It is a situation in which a resource is either using by a process. "Hold and Wait Condition" refers that a process is holding a process and waiting for another process. "No-preemption condition" means a process that can not be halted without damaging any task. And the last condition is "Circular Wait Condition". In circular wait condition, the process resources must be circulated from one process to another. 
Previous
Next Post »