Preview

Scheduling

Satisfactory Essays
Open Document
Open Document
1111 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
Scheduling
Operating Systems

User OS Kernel & Device Drivers Interface Programs

Deadlock

Brian Mitchell (bmitchel@mcs.drexel.edu) Operating Systems

1

Deadlocks
• Computer resources are full of resources that can only be used by one process at a time • Unpredictable results can occur if two or more processes use the same resource at the same time • OS control this problem by arbitrating resource requests • OS grant exclusive access and manage access to system resources • By allowing processes to have exclusive access to resources problems may occur:
– Starvation – Deadlock

Brian Mitchell (bmitchel@mcs.drexel.edu) Operating Systems

2

Deadlocks
• Deadlock can occur if two or more processes are competing for two or more common resources • Deadlock causes all processes involved in the deadlock to become permanently blocked
– Each process is waiting on resources owned by other processes that are also deadlocked

• Deadlock may be difficult to detect
– Often timing sensitive

• What to do about deadlocks:
– – – – Understand them Model them Develop ways to detect them Develop ways to avoid them
Brian Mitchell (bmitchel@mcs.drexel.edu) Operating Systems 3

Resources
• Deadlocks occur when processes have been granted exclusive access to resources
– Resources include semaphores, devices, files, …

• Resources come in two types:
– Preemptive resource: A resources that can be taken away from a process without any ill effects.
• Example: memory

– Non-preemptive resource: A resource that can not be taken safely away from a process
• Example: printer

• Deadlocks generally involve non-preemptive resources • Deadlocks can be easily fixed with preemptive resources
– Take resources away from one or more deadlocked processes
Brian Mitchell (bmitchel@mcs.drexel.edu) Operating Systems 4

Using Resources
• Access to resources should follow the model presented when we discussed critical sections
– Request the resource – Use the resource –

You May Also Find These Documents Helpful

  • Powerful Essays

    to over-utilization in some processes and superfluous capacity in others and several non-value add segments of…

    • 2472 Words
    • 23 Pages
    Powerful Essays
  • Good Essays

    2. Fail-Stop: is a halting failure with a notification to the system that something with in the network or program or components is not working right or is about to go down.…

    • 726 Words
    • 3 Pages
    Good Essays
  • Powerful Essays

    10. How can you eliminate the possibility that an application error is caused by another application or service running in the background…

    • 850 Words
    • 4 Pages
    Powerful Essays
  • Good Essays

    Nt1310 Unit 3 Os

    • 1341 Words
    • 6 Pages

    +• Synchronization: With multiple active processes having potential access to shared address spaces or shared I/O resources, care must be taken to provide effective synchronization. Synchronization is a facility that enforces mutual exclusion and event…

    • 1341 Words
    • 6 Pages
    Good Essays
  • Good Essays

    Is the ability to forestall, avoid or stop something from happening. To manage factors that may lead to diseases, illnesses or injuries.…

    • 1076 Words
    • 4 Pages
    Good Essays
  • Satisfactory Essays

    BUAD 304 final study guide

    • 2175 Words
    • 9 Pages

    c. Process Conflict – Conflict over how work gets done. Low levels of this type are FUNCTIONAL.…

    • 2175 Words
    • 9 Pages
    Satisfactory Essays
  • Powerful Essays

    Module 8 Review Questions

    • 1981 Words
    • 7 Pages

    1. Provide some examples in business or daily life in which a controlled process is erroneously adjusted and an out-of-control process is ignored. What implications do these errors have?…

    • 1981 Words
    • 7 Pages
    Powerful Essays
  • Satisfactory Essays

    Sometimes, some resources are a vital part of maintaining…

    • 252 Words
    • 2 Pages
    Satisfactory Essays
  • Good Essays

    Torts Study Guide

    • 4740 Words
    • 19 Pages

    Preparation- amount of preparation involved in an activity (longer preparation, more likely to foresee possible damages/injuries that could occur…

    • 4740 Words
    • 19 Pages
    Good Essays
  • Powerful Essays

    Ap Human Geography

    • 3578 Words
    • 15 Pages

    1. A resource is a substance in the environment that is useful to people, is economically and technologically feasible to access, and is socially acceptable to use.…

    • 3578 Words
    • 15 Pages
    Powerful Essays
  • Better Essays

    Block Scheduling

    • 835 Words
    • 4 Pages

    A small debate has always been discussed when talking about block scheduling and traditional class periods. Some people like the longer classes while others prefer the traditional six shorter class periods. Everyone has their own opinions about block scheduling. Block scheduling can be really helpful to high school students in many ways. Although, block scheduling is a longer time spent in one class, it should be mandatory in all high schools rather than traditional class periods.…

    • 835 Words
    • 4 Pages
    Better Essays
  • Satisfactory Essays

    Job Scheduling

    • 1099 Words
    • 5 Pages

    i JOB SCHEDULING IN NON-MULTIPROGRAMMING ENVIRONMENT Average turn around time computation T=n=0nTix 1n Where: Ti= Fi-…

    • 1099 Words
    • 5 Pages
    Satisfactory Essays
  • Powerful Essays

    Timetable Management

    • 1538 Words
    • 7 Pages

    SPS GROUP ONLINE LIBRARY MANAGEMENT SYSTEM SOFTWARE REQUIREMENTS SPECIFICATION VERSION: 1.0 Team Name : SPS GROUP College Name : Meenakshi Academy of Higher Education & Research Faculty of Engineering & Technology Team Guide : Mr. M.NARAYANAN Team Members : PRIYADARSINI P.P. PAIBARTY SUJATA KUMARI SREELOKA ROY Department : Department of Computer Science and Engineering State : Tamil Nadu Revision History |Date |Version |Description |Author | |25. 11. 2010 |1.0 |Synopsis |SPS Group | TABLE OF CONTENTS DESCRIPTION PAGE…

    • 1538 Words
    • 7 Pages
    Powerful Essays
  • Good Essays

    Deadlock

    • 1203 Words
    • 5 Pages

    Deadlock occurs when each process in a set is waiting for an event that can only be caused by some other process in that set. Basically, deadlock is an operating system issue that reared its head with the advent of multiprogramming environments. First and foremost, a deadlock cannot occur unless there are at least two processes trying to run concurrently. There are actually four distinct circumstances that must be met for deadlock to occur, which will be discussed shortly, but it is worth noting that it is fundamentally a multiprocessing problem. Mono-processing systems do not have to worry about deadlock. The reason is that deadlock involves resource allocation, and if there is only one process, it has uncontested access to all resources. Only certain types of resources are associated with deadlock, and they are of the exclusive-use, non-preemptible type. That is to say, only one process can use the resource at any given time, and once allocated the resource cannot be unallocated by the operating system, but rather the process has control over the resource until it completes its task. Excellent examples of such resources are printers, plotters, tape drives, etc.. Resources that do not fit the criteria are memory and the CPU. While it is convenient to discuss deadlock in terms of hardware resources, there are software resources that are equally good candidates for deadlock, such as records in a data base system, slots in a process table, or spooling space. Hardware or software, all that matters is that the resources are non-preemptible and serially reusable.…

    • 1203 Words
    • 5 Pages
    Good Essays
  • Good Essays

    v) Lastly, all processes had received the resources needed, the graph is reducible. Thus, no deadlock.…

    • 935 Words
    • 4 Pages
    Good Essays