Explain about deadlock prevention, Operating System

Assignment Help:

Explain about deadlock prevention?

In order for the occurrence of deadlock, the four conditions like mutual exclusion, hold and wait, no pre-emption and  circular wait must happen. By ensuring that one of these conditions cannot hold, we can stop the occurrence of deadlock.

Mutual exclusion

It must hold for non-sharable resources. For example a printer cannot be simultaneously shared by several processes. Sharable resources do not need mutually exclusive access, and therefore cannot be include in deadlock. Read-only files are a good example of a sharable resource.

Hold and wait

To ensure that hold and wait condition never happens in the system, we must guarantee that, whenever a process requests a resource, it does not hold any other resources. The protocols used are

1. Every process is to be request and be allocated all its resources before it begins execution.

2. Permits a process to request some resources only when the process has none (no other resources).

 


Related Discussions:- Explain about deadlock prevention

Calculate the maximum file size , A UNIX file system has 1-KB blocks and 4-...

A UNIX file system has 1-KB blocks and 4-byte disk addresses. What is the maximum file size if i-nodes contains 10 direct entries, and one single, double, and triple indirect entry

Ubuntu shell script - linux, Task 1 description: Design and implement the ...

Task 1 description: Design and implement the disableuser.sh script. Required script functionality: disableuser.sh -v : prints the script version number and exits dis

Define request edge and assignment edge, Define request edge and assignment...

Define request edge and assignment edge. Answer:  A directed edge from process Pi to resource type R j is denoted by Pi->j; it signifies that process Pi requested an instance

Explain the resource ownership and control, Explain the Resource Ownership ...

Explain the Resource Ownership and Control Operating systems are required to handle many different types of resources. CPU , memory, and I/O devices  are some of the varied sys

Unsafe state, discuss unsafe state in operating system

discuss unsafe state in operating system

Find the parent process and the child process, Q. When a process creates a...

Q. When a process creates a fresh process using the fork() operation which of the following state is shared among the parent process and the child process? 1 Stack 2 Heap

Define shell in unix system, A Unix shell is a shell or command-line inte...

A Unix shell is a shell or command-line interpreter that gives a traditional user interface for the Unix-likesystems and for Unix operating system. Users operates the operation of

Which algorithm makes the most efficient use of memory, Question : (a) ...

Question : (a) The dynamic allocation problem is how to satisfy a request of size n from a list of free holes into memory. The best-fit, first-fit and worst-fit strategies are

What is the main advantage of multiprogramming, What is the main advantage ...

What is the main advantage of multiprogramming? Multiprogramming makes efficient use of the CPU by overlapping the demands for the CPU and its I/O devices from various users. I

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd