os pdf ppt shanu.pptx presentation on slides

siddhantpandey2410 12 views 14 slides Jun 05, 2024
Slide 1
Slide 1 of 14
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14

About This Presentation

Presentation on ot


Slide Content

V aish n a vi k es h a r w a n i Sneha sharma Sweacha mishra Vedika yadav Shanu awasthi Int r o a bout g r oup members-

Topic – Deadlock- What is Deadlock? deadlock is a situation where a set of process are blocked because each process is holding a resources and waiting for another resources acquired by some other process.

Necessary condition for deadlock- M u t ual e x c lus i o n - I f t w o p r oc e s s c a n no t use same resources at same time. Hold and wait- A process waits for some resources while holding and another resources at the same time. No preemption -The process which once schedu l ed w i l l b e e x ecu t ed t il l t h e c omp l e t i on. Circular wait- All the processes must be waiting for the resources in a cyclic manner.

Deadlock detection algorithm- R es o u r c e s allo c a tion gr a ph (directed ) - Directed graph is also known as resources allocation graph. A ll o c a ti o n g r a p h a r e use d t o desc r i bed deadlock. This graph consist of a set of vertices and a set of edges. It is represented as G=(V,E). In resources allocation graph the process can be defined by the circle & the resources can be defined by the rectengle.

Number of process involved P1, P2 ,P3 Number of resources involved R1,R2 Number of waiting process P1,P2,P3 Shareable resources R1,R2 [R1, R2 is shareable resources so there is no deadlock in the system.

Me t hods f or handling deadlock- There are three methods for dealing wit deadlock. We can use a protocol to prevent or avoid the deadlock insuring that a system will never enter in a deadlock state. We can also allow the system to enter in a deadlock state &detected it and recover from the deadlock situation.

We can ignore the problem all together and prevent that deadlock never occurred in the system.

Deadlock Ayoidence Algorithm - Banker's Algorithm (Safety Algo ) the resource allocation graph froc algorithm is not applicable to a allocation System with multiple instances of each resource type for such a System Borker's Algorithm is used as a deadlock avoidence.Algorithm for this algorithm. we need the following data structure.

Avaibility – A vector of length Indicato resources of number of available each type 2- Maximum Demands - Maximum is nim matrix which define the maximum demond each process. 3. Allocation - This the Ro resources each currently allocated to each define type 4. Need - This nxm Indicates the remaining resources such as reed of the Jeach process.Need [ i , j] = Max [ i , j] - Allocation [ ij ]

Summary of deadlock- The deadlock can be resolved by breaking the symmetry .In operating system , a deadlock occurs when a process enters a waiting state because a requested system resources is held by another waiting process which in turn is waiting for another resources held by another waiting process. preventing deadlock is crucial for ensuring the smooth operation and optimal performance of computer systems.
Tags