ALL > Computer and Education > courses > university courses > undergraduate courses > Operating System > ZSTU class(2019-2020-1) > student directories > 2017329621034 郭诚 >
Homework 5 Version 0
👤 Author: by 157128166qqcom 2019-11-24 10:09:05
P2 requests Request 2 (1, 2, 2, 2) to be checked according to the banker's algorithm

·Request2(1,2,2,2) ≤Need(2,3,5,6)
·Request2(1,2,2,2) ≤Available(1,6,2,2)

· Trial allocation and modification of the corresponding data structure, resource allocation as follows:

Allocation Need Available
P0 0 0 3 2 0 0 1 2 0 4 0 0
P1 1 0 0 0 1 7 5 0
P2 2 5 7 6 1 1 3 4
P3 0 3 3 2 0 6 5 2
P4 0 0 1 4 0 6 5 6

· Then the security algorithm is used to check whether the system is safe or not. Available (0, 4, 0, 0) can not meet the needs of any process, so the system is in an unsafe state. At this time, the system can not allocate resources to P2.

Please login to reply. Login

Reversion History

Loading...
No reversions found.