Deadlock detection

Definition

No deadlock-prevention or deadlock-avoidance is used.

  • So, deadlock situations may occur.

The state of the system should be examined to determine whether a deadlock has occurred.

A recover from deadlock procedure should exist and be applied.

What to do?

  • In a quite naive approach, the problem can simply be ignored.

  • Otherwise, the circular chain of processes and resources need to be broken.

Recover procedure

How?

  • release resources from a process – if it is possible

    • The process is suspended until the resource can be returned back.

    • Efficient but requires the possibility of saving the process state.

  • rollback – if the states of execution of the different processes is periodically saved.

    • A resource is released from a process, whose state of execution is rolled back to the time the resource was assigned to it.

  • kill processes

    • Radical but an easy to implement method.

Last updated