wisemonkeys logo
FeedNotificationProfileManage Forms
FeedNotificationSearchSign in
wisemonkeys logo

Blogs

Deadlock and Starvation

profile
Shubham Yadav
Aug 15, 2024
0 Likes
0 Discussions
51 Reads

1. Deadlock


Deadlock in an operating system occurs when a set of processes become stuck because each process is waiting for a resource that another process holds, and none of the processes can proceed. This situation usually arises in multi-process systems where processes share resources such as files, memory, or devices. The four necessary conditions for deadlock, often referred to as Coffman’s conditions, are mutual exclusion, hold and wait, no preemption, and circular wait. If all these conditions hold simultaneously, the system can enter a deadlock state. Deadlocks can be addressed through prevention, avoidance, or detection and recovery methods. Prevention involves designing the system to negate one or more of the Coffman conditions, while avoidance uses algorithms like Banker’s Algorithm to ensure the system never enters an unsafe state. Detection and recovery involve allowing the deadlock to occur but having mechanisms to identify and resolve it by terminating processes or rolling them back.


2.Starvation


Starvation occurs in an operating system when a process waits indefinitely to gain access to a resource it needs, even though the resource is available at times. This typically happens in scheduling algorithms that favor certain processes over others, like when a low-priority process is continually preempted by higher-priority processes. Starvation is a significant problem because it can lead to reduced system performance and inefficiency. Solutions to starvation include using aging, a technique where the priority of a waiting process is gradually increased, ensuring that every process eventually gets a chance to execute. By incorporating aging into scheduling algorithms, the operating system can prevent starvation by ensuring that processes waiting for resources for a long time are eventually given access, thus maintaining system fairness.


Comments ()


Sign in

Read Next

Old age lifestyle

Blog banner

CYBER FORENCIS: PAST, PRESENT AND FUTURE.

Blog banner

How return on investment is defined in IT services

Blog banner

GIS info about Bermuda Triangle

Blog banner

OS DESIGN CONSIDERATIONS FOR MULTIPROCESSOR

Blog banner

What's Better : Supervised or Unsupervised Learning

Blog banner

virtual machine

Blog banner

How Reading Books Shape a Child’s Imagination and Thinking?

Blog banner

What is Anxiety? How to manage Anxiety?

Blog banner

Cloud Forensic Tools And Storage :A Review Paper

Blog banner

Consumer to consumer Business model

Blog banner

The Dark Web: A Breeding Ground for Cybercriminals – How to Guard Against Threats

Blog banner

Direct memory access

Blog banner

MEMORY HIERARCHY

Blog banner

Risk factors in service transistion

Blog banner

OS assignment 3

Blog banner

The Rise of Evil Twin Attacks: A New Kind Of Spoofing Cyberattack

Blog banner

Short note on Microsoft office

Blog banner

Real-time Scheduling - 53003230061

Blog banner

Processing Crime and Incident Scenes

Blog banner

Social Media Sentiment Analysis

Blog banner

All you need to know about Cassandra

Blog banner

DISK SCHEDULING

Blog banner

Benefits of Yoga

Blog banner

SMARTSHEET MANAGEMENT SOFTWARE

Blog banner

MEMORY MANAGEMENT FILE

Blog banner

Zoho

Blog banner

Data-Driven Prediction of Virtual Item Prices in Online Games

Blog banner

LEMON PICKLE SWEET AND MILD HOT

Blog banner

Scheduling

Blog banner

Koinex is shutting down and here is how you can withdraw...

Blog banner

What is Email? Uses of Emails

Blog banner

Cyber Forensics on IOT Devices

Blog banner

Student Grade Calculator in LISP

Blog banner

38_Exploring The Honeynet Project

Blog banner

What is the point of living if we can die at any moment of our lives ?

Blog banner

GOOGLE

Blog banner

All you need to know about “Off-page SEO”

Blog banner

Internet of Things and cyber security

Blog banner

The Power of Teamwork: Learning Collaboration Through Everyday Activities

Blog banner

Online Games

Blog banner

ACHIEVEMENTS IN OPERATING SYSTEMS

Blog banner