Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

how many commercial operating systems like w Consider the following snapshot of a system Max A BCD Available A A BCD BCD P: 1 3

how many commercial operating systems like w
image text in transcribed
image text in transcribed
Consider the following snapshot of a system Max A BCD Available A A BCD BCD P: 1 3 54 23 5 6 Ps 0 6 320 6 53 Answer the following questions using the banker's algorithm. Here is the "safety" and "resource-request" algorithm for process i: 1. Let Work and Finish be vectors of length m and n, respectively. Initialize Work Available Finish [i] = false for i = 0, 1, , n-1. 2. Find and i such that both: (a) Finish false (b) Needi s Work If no such i exists, go to step 4. 3. Work = Work + Allocation Finish[] true go to step 2 4. If Finish Itrue for all i. then the svstem is in a safe state Request - request vector for process P If Request 1 k then process P, wants k instances of resource type R 1. If Request s Need go to step 2 Otherwise, raise error condition, since process has exceeded its maximum claim 2. If Request s Available, go to step 3 Otherwise P, must wait, since resources are not available 3. Pretend to allocate requested resources to P by modifying the state Available - Available - Request AllocationAllocationi + Request Need Need,- Request If safe the resources are allocated to Pi O If unsafePi must wait, and the old resource-allocation state is restored 7. What is the content of the matrix Need? (5 points) (5 Explain whether the system is in a safe state or not using the banker's algorithm. points) 8, 9. If a request from process Pi arrives for (1, 3, 1, 0), can the request be granted immediately? Justify your answer. 5 points)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Databases Illuminated

Authors: Catherine M Ricardo, Susan D Urban

3rd Edition

1284056945, 9781284056945

More Books

Students also viewed these Databases questions