انت هنا الان : شبكة جامعة بابل > موقع الكلية > نظام التعليم الالكتروني > مشاهدة المحاضرة

deadlock prevention

الكلية كلية العلوم للبنات     القسم قسم الحاسبات     المرحلة 4
أستاذ المادة سحر عادل كاظم عبود باوي       6/1/2011 5:55:46 AM

Deadlock Prevention

 

·        Each process must request and acquire all the needed resources at the same time

 

·        Deny one of the required conditions for a deadlock

 

 

_ Cannot be done for non-sharable resources (like printers)

 

_ Sharable resources (read-only _les) do not require mutually exclusive access ) cannot be involved in deadlock

 

_ Cannot deny mutual exclusion as some resources are inherently non-sharable

 

_ Hold and Wait

 

_ Processes can request and acquire all the resources at one time

 

_ Request resources only if the process is holding none

 

 

If the process is holding any resources, they must be released before requests can be granted

 

 

 Disadvantages

 

1. Low resource utilization { resources may get allocated but not used for a long time

 

2. Possibility of starvation { on popular resources

 

_ No Preemption

 

_ If a process holding resources requests for another resource that cannot be immediately allocated, all currently held resources are

 

   preempted

 

_ Process restarted only when it regains all the resources

 

_ Suitable for resources whose state can be easily saved { CPU registers, memory

 

_ Circular Wait

 

_ Impose a total ordering on all resource types

 

_ Each process requests resources in an increasing order of enumeration

 

_ If several instances of a resource required, a single request must be issued for all of them

 

_ Deadlock Prevention based on Maximum Claims

 


المادة المعروضة اعلاه هي مدخل الى المحاضرة المرفوعة بواسطة استاذ(ة) المادة . وقد تبدو لك غير متكاملة . حيث يضع استاذ المادة في بعض الاحيان فقط الجزء الاول من المحاضرة من اجل الاطلاع على ما ستقوم بتحميله لاحقا . في نظام التعليم الالكتروني نوفر هذه الخدمة لكي نبقيك على اطلاع حول محتوى الملف الذي ستقوم بتحميله .