Deadlock Detection - Operating System Questions and Answers

  • 1. The wait-for graph is a deadlock detection algorithm that is applicable when :
   A.) all resources have a single instance
   B.) all resources have multiple instances
   C.) all resources have a single 7 multiple instance
   D.) all of the mentioned

Answer: Option 'A'

all resources have a single instance

  • 2. An edge from process Pi to Pj in a wait for graph indicates that :
   A.) Pi is waiting for Pj to release a resource that Pi needs
   B.) Pj is waiting for Pi to release a resource that Pj needs
   C.) Pi is waiting for Pj to leave the system
   D.) Pj is waiting for Pi to leave the system

Answer: Option 'A'

Pi is waiting for Pj to release a resource that Pi needs

  • 3. If the wait for graph contains a cycle :
   A.) then a deadlock does not exist
   B.) then a deadlock exists
   C.) then the system is in a safe state
   D.) either deadlock exists or system is in a safe state

Answer: Option 'B'

then a deadlock exists

  • 4. If deadlocks occur frequently, the detection algorithm must be invoked ________
   A.) rarely
   B.) frequently
   C.) rarely & frequently
   D.) none of the mentioned

Answer: Option 'B'

frequently

  • 5. The disadvantage of invoking the detection algorithm for every request is :
   A.) overhead of the detection algorithm due to consumption of memory
   B.) excessive time consumed in the request to be allocated memory
   C.) considerable overhead in computation time
   D.) all of the mentioned

Answer: Option 'C'

considerable overhead in computation time

  • 6. A deadlock eventually cripples system throughput and will cause the CPU utilization to ______
   A.) increase
   B.) drop
   C.) stay still
   D.) none of the mentioned

Answer: Option 'B'

drop

  • 7. Every time a request for allocation cannot be granted immediately, the detection algorithm is invoked. This will help identify :
   A.) the set of processes that have been deadlocked
   B.) the set of processes in the deadlock queue
   C.) the specific process that caused the deadlock
   D.) all of the mentioned

Answer: Option 'A'

the set of processes that have been deadlocked

  • 8. A computer system has 6 tape drives, with ‘n’ processes competing for them. Each process may need 3 tape drives. The maximum value of ‘n’ for which the system is guaranteed to be deadlock free is :
   A.) 1
   B.) 2
   C.) 3
   D.) 4

Answer: Option 'B'

2

  • 9. A system has 3 processes sharing 4 resources. If each process needs a maximum of 2 units then, deadlock :
   A.) can never occur
   B.) may occur
   C.) has to occur
   D.) none of the mentioned

Answer: Option 'A'

can never occur

  • 10. ‘m’ processes share ‘n’ resources of the same type. The maximum need of each process doesn’t exceed ‘n’ and the sum of all their maximum needs is always less than m+n. In this setup, deadlock :
   A.) can never occur
   B.) may occur
   C.) has to occur
   D.) none of the mentioned

Answer: Option 'A'

can never occur

Deadlock Detection - Operating System Questions and Answers Download Pdf