wisemonkeys logo
FeedNotificationProfileManage Forms
FeedNotificationSearchSign in
wisemonkeys logo

Blogs

Deadlock Prevention

profile
Shreya Mantry
Aug 15, 2024
0 Likes
0 Discussions
90 Reads

DEADLOCK PREVENTION


Deadlock is a situation in computing where two or more processes are unable to proceed because each is waiting for the other to release resources. Strategies used in computer systems in order to ensure that different processes can run smoothly without getting stuck waiting for each other forever is  Deadlock prevention.


The deadlock has the following characteristics:

  1. Mutual Exclusion
  2. Hold and Wait
  3. No Preemption
  4. Circular Wait


Deadlock can be prevented by ruling out any of the above four conditions:


  • Mutual Exclusion:

Make data read only, so that processes can use the data concurrently. We know that many write procedure cannot take place at same time. Thus allow only exclusive users to writee into the file. And let others have access to read only.


  • Hold and Wait:

The hold-and-wait condition can be prevented by requiring all processes to request for required access at a time. While doing so all other processes will be blocked until all requests are granted. This means that other non running processes will have to wait until their turn.


  • No preemption:

if a process requests for certain resources, it must release its original resources first. And if another process is using that resources it needs to release them


  • Circular wait

Each resource will have a numeric order. All processes must follow that order only while requesting resources. No process will be granted if they request for resources have higher priority than they have currently. 


Thus in these ways deadlock can be prevented.



Comments ()


Sign in

Read Next

Digital Balance: Keeping Children Mindful in the Screen Age

Blog banner

New Horizon Europe project ‘EvoLand’ sets off to develop new prototype services.

Blog banner

Importance Of Yoga.

Blog banner

Memory management

Blog banner

Knowledge Management in Continual Service improvement (CSI)

Blog banner

The Role of Cyber Forensics in Criminology

Blog banner

Pink sauce pasta

Blog banner

'Positivity in life'

Blog banner

What is a Malware ?

Blog banner

Real time scheduling

Blog banner

Game Theory in Blockchain

Blog banner

Shoulders

Blog banner

Paging

Blog banner

NETWORK SECURITY RISKS

Blog banner

UniProcessor Scheduling

Blog banner

City of Mumbai (Bombay):

Blog banner

indian premier league

Blog banner

Can ChatGPT Answer All My Questions About Life?

Blog banner

Cyber Forensics in a Ransomware Attack Recovery

Blog banner

Data Science in Mental Health Prediction

Blog banner

Deadlock

Blog banner

Microsoft powerpoint presentation

Blog banner

WORKFRONT SOFTWARE

Blog banner

Multiple-Processor Scheduling in Operating System

Blog banner

Google App Engine

Blog banner

Danger assessment in GIS

Blog banner

Zomato's Secret Digital Marketing Techniques!

Blog banner

Virtual Machine

Blog banner

Bharat Maps

Blog banner

Short-Form Video Marketing: Why It's Dominating the Internet

Blog banner

Artical on FreshBooks

Blog banner

evolution of operating system - Disha Parekh

Blog banner

Mumbai

Blog banner

Process and Threading

Blog banner

Riddhi Miyani 53003220140

Blog banner

15 Interesting Facts about India

Blog banner

What is OS Fingerprinting?

Blog banner

Product Discount Calculator

Blog banner

ADD A SPICE TO YOUR LIFE.

Blog banner

Remote Work in 2026

Blog banner

HUBSPOT

Blog banner

"Can Lisp do Machine Learning?"

Blog banner