Question
Which of the following is a key challenge in handling
deadlocks in an operating system?Solution
Detailed Explanation: Deadlocks occur when a set of processes is blocked because each process is holding a resource and waiting for another resource held by another process. One of the primary methods for detecting deadlocks is using the resource allocation graph (RAG) . A cycle in this graph indicates a potential deadlock when resources are not reusable or preemptible. Detecting cycles involves examining the directed graph of resources and processes to find circular dependencies. Algorithms like Depth First Search (DFS) are commonly used for this purpose in deadlock detection. Deadlock detection is critical in systems where prevention or avoidance mechanisms are impractical, such as distributed systems. Once detected, the system must recover by terminating one or more processes or preempting resources, which can be complex and resource-intensive. Why Other Options Are Incorrect:
- Option A: Allocating resources fairly is more related to system performance and fairness policies rather than deadlock handling. Fairness does not directly address circular wait or hold-and-wait conditions.
- Option B: Preventing starvation is a separate issue. Starvation happens when low-priority processes wait indefinitely, often due to poor scheduling, not necessarily because of deadlocks.
- Option D: FCFS is a scheduling algorithm that manages the sequence of process execution but does not directly address or solve deadlocks.
- Option E: Managing shared memory involves synchronization and mutual exclusion issues but is not inherently about detecting cycles in deadlocks.
Recently Air India has introduced a new policy which will give an extension of service to its selected pilots for how many years?
According to the Census 2011, which of the following statement about the worker of Uttar Pradesh is correct?
Silent Valley National Park is located in which state?Â
Silent Valley National Park is located in which Indian state?
At the 53rd International Film Festival of India held in Panaji, Goa which of the following movies has won the Best Film Award?
Who was the first woman to travel into space from the state Haryana?
Who has been appointed as the new Chairman and Managing Director of Bharat Electronics Limited (BEL)?
Which of the following states is the first to create the role of Director-General of Audit?
In October 2020, what was the milestone achieved by Virat Kohli in T20 cricket, making him the first Indian batsman to reach a specific number of runs?
Which Indian company announced the development of 'JioBrain,' a comprehensive suite of AI tools?