What are the different types of process states and queues?


Let us begin by understanding the types of process states.

Types of Process States

There are different types of Process States which are as follows −

  • New − The process is about to be created in this state but not yet created, it is the program which is present in secondary memory that will be picked up by OS to create the process.

  • Ready − The process enters the ready state after the creation of a process that means the process is loaded into the main memory.

  • Running − The process is chosen by the CPU for instructions and the executions within the process and they are executed by any one of the available CPU cores.

  • Waiting − Whenever the process requests access to I/O or needs input from the user or needs access to a critical region it enters the blocked or wait state.

  • Terminated − Process is killed as well as PCB (Process Control Box) is deleted.

  • Suspend ready − Process that was initially in the ready state and now if many processes are coming to ready state then main memory resources availability is less so some processes will be suspended and move to secondary memory i.e. Suspend Ready State

  • Suspend wait or suspend blocked − Similar to suspend ready but uses the process which was performing I/O operation and lack of main memory caused them to move to secondary memory. When work is finished it may go to suspend ready.

So, all the states which are used in Process Running are given below −

Types of Queues

Now let us learn about the three types of Queue in Process Scheduling.

  • Job Queue − It is used to store all the processes of the system. It contains the list of processes that reside on mass storage/secondary storage and await main memory allocation. When a process resides in Job Queue then the state of the process is a NEW state

  • Ready Queue − It is a queue of all processes that are ready and waiting to be scheduled on a core/CPU . When a process resides in Ready Queue then the state of the process is Ready state

  • Device Queue − Those processes that are blocked due to the unavailability of an I/O device constitute this queue. So this queue contains all the blocked processes and is waiting for I/O. When a process resides in the Device Queue then the state of the process is state Blocked or wait for State.

The types of queues are given in the diagram below −

Updated on: 01-Dec-2021

1K+ Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements