Deadlocks

0.0(0)
studied byStudied by 0 people
learnLearn
examPractice Test
spaced repetitionSpaced Repetition
heart puzzleMatch
flashcardsFlashcards
Card Sorting

1/3

flashcard set

Earn XP

Description and Tags

flashcards made from Deadlocks slides from week 9

Study Analytics
Name
Mastery
Learn
Test
Matching
Spaced

No study sessions yet.

4 Terms

1
New cards

Resources and Deadlocks

Many resources in a computer system can only be used by one process at a time

Printers, some backup media, system tables, database records, etc

Operating systems need to grant exclusive access for these cases

Some applications need to access several of these resources:

E.g. Two different processes (A and B) need to save scanned documents to a DVD:

However, A can request access to the scanner at the same as B requests access to the DVD, hence none can get their missing resource next: Deadlock!

Deadlocks can also occur across machines or with more than just two processes/devices

2
New cards

Preemptable and Nonpreemptable Resources

Preemptable resource:

Can be taken away from the process that is using it without causing issues

e.g. a process can be temporarily removed from memory

Non-preemptable resource:

Cannot be taken away from the process that is using it without potentially causing failure

e.g. interrupting a record (burn) operation on a DVD will usually cause it to fail

Normally the resources which are susceptible to be involved in deadlocks are non-preemptable

In this context, the sequence of events required to use a resource is:

1. Request the resource

2. Use the resource

3. Release the resource

3
New cards

Resource Acquisition (1)

knowt flashcard image
4
New cards

Resource Acquisition (2)

knowt flashcard image