×

Scheduling Algorithms in OS

There are various types of scheduling algorithm which are used by the operating system to schedule the process on the processor.

Objective of Scheduling Algorithms

There are the following objectives of Scheduling Algorithms:

  1. Fare allocation of CPU
  2. Increased throughput
  3. Improved CPU Utilization
  4. Minimum Turnaround time
  5. Minimum response time
  6. Minimum waiting time

Types of Scheduling Algorithms

There are various types of Scheduling Algorithms:

  1. First come, first serve (FCFS).
  2. Shortest Job first (SJF).
  3. Shortest remaining time first(SRTF).
  4. Round Robin (RR)
  5. Priority-based Scheduling
  6. Highest Response Ration Next
  1. First Come First Serve (FCFS): - FCFS (First Come First Serve) is either a preemptive or non-preemptive Scheduling algorithm. It is easy to use and understand. In FCFS, jobs are executed on a first-come, first-serve manner. FCFS performance is poor due to the high average waiting time.
  2. Shortest Job First (SJF): - Shortest Job First is a Non-Preemptive algorithm. In the shortest job first algorithm, the job having shortest or less burst time will get the CPU first. It is a good approach to minimize the waiting time. It is simple to implement in the batch operating system because in this CPU time is known in advance, but it is not used in interactive systems because, in an interactive system, CPU time is not known.
  3. Shortest Remaining Time First (SRTF): - Shortest Remaining Time First is a Preemptive Scheduling Algorithm in which the operating system schedules the job, based on the remaining time of the execution. The job having the shortest remaining time is executed first.
  4. Round Robin (RR): - Round Robin is a Preemptive Scheduling Algorithm, which is the most commonly used algorithm in CPU Scheduling.In this, each process is assigned a fix time interval to execute. It is called quantum. In the round-robin, if a process executes in a given time period, then it gets preempted. Round robin is a starvation free CPU scheduling algorithm because all the processes get fair sharing of CPU.
  5. Priority Based Scheduling: - In Priority-Based Scheduling, all the processes are assigned some priority, and according to the priority, the process gets the CPU. Priority is assigned on the basis of time requirements, memory requirements, and resource requirements. In this, if two processes have the same priority, then the scheduling is done according to their time of arrival or first-come, first-served basis.
  6. Highest Response Ratio Next: - In Highest Response Ration Next algorithm, the highest response ratio process is scheduled next. This algorithm reduced the problem of starvation in the system.

Related Topics

Turn Variable or Strict Alternative Approach

Turn Variable or Strict Alternative Approach Turn Variable Approach is used for process synchronization mechanism, which offers synchronization between two processes. Turn variable is implemented on user mode, and it is a software mechanism. We...

3 minutes read.

Multi-user Operating Systems

Introduction Since only one user may interact with the computer at any given time, the operating system we use on our personal computers, laptops, tablets, and phones is sometimes referred to...

8 minutes read.

Resource Allocation Graph in Operating System

Resource Allocation Graph in OS We use the resource allocation graph for the pictographic representation of the state of a system. The resource allocation graph contains all the information related to the processes that...

5 minutes read.

What is Thread and Types of Thread

What is Thread A thread means a lightweight process. Thread is the basic unit of CPU execution, which consists of thread ID, Program counter, set of registers to hold the information of current...

7 minutes read.

Deadlock Detection and Recovery

Deadlock Detection and Recovery In deadlock detection and recovery, to avoid or prevent a deadlock, the operating system uses various methods. For checking deadlock, an operating system continuously monitors the system. Then also,...

2 minutes read.

Semaphore in Operating System

What is Semaphore in Operating System Semaphore is defined as an integer variable which is used to solve the problem of the critical section in process synchronization. In semaphore, we use...

3 minutes read.

DOS Operating System

What is DOS Operating System? An operating system that runs from a hard disk drive is known as the DOS (Disk Operating System).In other words, DOS (Disk Operating System) is defined...

7 minutes read.

Deadlock Prevention in Operating System

Deadlock Prevention The conditions which we used for deadlock prevention are: Mutual ExclusionHold and WaitNo PreemptionCircular Wait 1. Mutual Exclusion: - From the resource point of view, the mutual exclusion means that simultaneously more...

4 minutes read.

Memory Management in Operating System

The term "Main Memory" refers to the computer's internal physical memory. It is distinguished from external mass storage devices like disk drives by using the term "main." RAM is another...

4 minutes read.

Distributed Shared Memory

Distributed Shared Memory is a process of managing memory over more than one node and makes inter-process communication which transfers to end users. It is a mechanism that allows user...

2 minutes read.

Evolution of Operating System

Evolution of Operating System The evolution of various types of operating systems can be briefly described as follows: Serial Processing Since 1950, the operating system started to be in use. Before 1950, there...

5 minutes read.

Operating System Properties

The Properties of Operating System are: Batch processingMultitaskingMulti-programmingInteractivityReal-Time SystemDistributed Environmentspooling 1. Batch Processing In Batch Processing, the OS first gathers the data and programs together in a batch, then processing starts. The operating system...

3 minutes read.

Difference between Process and Program in the Operating System

What is a process in the Operating System? A process is a program that is going through the execution. It also helps us to execute all the lines of code in...

4 minutes read.

Partitioning Algorithms

Partitioning Algorithms There are various types of Partitioning Algorithm: First-Fit AlgorithmNext-Fit AlgorithmBest-Fit AlgorithmWorst-Fit AlgorithmQuick-Fit Algorithm 1. First-Fit Algorithm: - In the First-Fit Partitioning algorithm, first, the linked list is scan, and when it...

3 minutes read.

What is Context Switching

Context Switching is the switching of CPU from one process to another process. Context switching means storing the process state so that we can reload the process when needed, and the execution...

3 minutes read.

Monitors in Operating System

Monitors in Operating System Monitors are used for process synchronization. With the help of programming languages, we can use a monitor to achieve mutual exclusion among the processes. Example of monitors:...

3 minutes read.

Difference between Multi-programming and Multitasking

Difference between Multiprogramming and Multitasking         Multiprogramming  Multitasking In Multiprogramming, at the same time, we can run the multiple processes concurrently on one...

2 minutes read.

MS-DOS Operating System

It is also referred to occasionally as "DOS", an abbreviation for disc operating systems. Operating systems with a graphical user interface (GUI) in different iterations of the graphical Microsoft Windows...

5 minutes read.

Segmentation in Operating System

The term segmentation in operating system refers to the division of computer memory into segments. Segmentation is a technique used by many modern operating systems to provide better memory management....

4 minutes read.

File in Operating System

What is File in Operating System?  A file is defined as a collection of the interrelated information that is stored in the secondary memory or the non-volatile memory such as optical...

4 minutes read.