Modern Operating Systems by Herbert Bos ...
Modern_Operating_Systems_by_Herbert_Bos_and_Andrew_S._Tanenbaum_4th_Ed.pdf-M ODERN O PERATING S YSTEMS
Showing 497 out of 1137
Modern Operating Systems by Herbert Bos and Andrew...
Modern_Operating_Systems_by_Herbert_Bos_and_Andrew_S._Tanenbaum_4th_Ed.pdf-M ODERN O PERATING S YSTEMS
Modern Operating Systems by Herbert...
Modern_Operating_Systems_by_Herbert_Bos_and_Andrew_S._Tanenbaum_4th_Ed.pdf-M ODERN O PERATING S YSTEMS
Page 497
466
DEADLOCKS
CHAP. 6
Gridlock is a resource deadlock and a problem in competition synchronization.
New
York City’s prevention algorithm, called "don’t block the box," prohibits cars from
entering an intersection unless the space following the intersection is also available.
Which prevention algorithm is this? Can you provide any other prevention algorithms
for gridlock?
7.
Suppose four cars each approach an intersection from four different directions simul-
taneously.
Each corner of the intersection has a stop sign.
Assume that traffic regula-
tions require that when two cars approach adjacent stop signs at the same time, the car
on the left must yield to the car on the right.
Thus, as four cars each drive up to their
individual stop signs, each waits (indefinitely) for the car on the left to proceed.
Is this
anomaly a communication deadlock?
Is it a resource deadlock?
8.
Is it possible that a resource deadlock involves multiple units of one type and a single
unit of another? If so, give an example.
9.
Fig. 6-3 shows the concept of a resource graph.
Do illegal graphs exist, that is, graphs
that structurally violate the model we have used of resource usage?
If so, give an ex-
ample of one.
10.
Consider Fig. 6-4. Suppose that in step (o)
C
requested
S
instead of requesting
R
.
Would this lead to deadlock?
Suppose that it requested both
S
and
R
.
11.
Suppose that there is a resource deadlock in a system. Give an example to show that
the set of processes deadlocked can include processes that are not in the circular chain
in the corresponding resource allocation graph.
12.
In order to control traffic, a network router,
A
periodically sends a message to its
neighbor,
B
, telling it to increase or decrease the number of packets that it can handle.
At some point in time, Router
A
is flooded with traffic and sends
B
a message telling it
to cease sending traffic. It does this by specifying that the number of bytes
B
may send
(
A
’s window size) is 0.
As traffic surges decrease,
A
sends a new message, telling
B
to
restart transmission.
It does this by increasing the window size from 0 to a positive
number.
That message is lost. As described, neither side will ever transmit. What type
of deadlock is this?
13.
The discussion of the ostrich algorithm mentions the possibility of process-table slots
or other system tables filling up. Can you suggest a way to enable a system administra-
tor to recover from such a situation?
14.
Consider the following state of a system with four processes,
P1
,
P2
,
P3
, and
P4
, and
five types of resources,
RS1
,
RS2
,
RS3
,
RS4
, and
RS5
:
0
0
0
2
1
0
0
0
1
1
0
0
E = (24144)
A = (01021)
C =
R =
1
2
1
0
0
1
1
0
1
1
0
2
1
0
1
0
2
1
0
2
0
3
1
0
2
1
1
0
Using the deadlock detection algorithm described in Section 6.4.2, show that there is a
deadlock in the system. Identify the processes that are deadlocked.


Ace your assessments! Get Better Grades
Browse thousands of Study Materials & Solutions from your Favorite Schools
Concordia University
Concordia_University
School:
Operating_Systems
Course:
Great resource for chem class. Had all the past labs and assignments
Leland P.
Santa Clara University
Introducing Study Plan
Using AI Tools to Help you understand and remember your course concepts better and faster than any other resource.
Find the best videos to learn every concept in that course from Youtube and Tiktok without searching.
Save All Relavent Videos & Materials and access anytime and anywhere
Prepare Smart and Guarantee better grades

Students also viewed documents