Process scheduling
- Process scheduling is the method by which an operating system decides the order in which processes are executed.
- It ensures efficient utilization of CPU and system resources, enabling multiple processes to share the CPU effectively.
- optimize CPU usage, memory management, and overall system performance
Types of Schedulers
Schedulers are categorized into three main types based on their functionality:
-
Long-term Scheduler (Job Scheduler)
- Determines which processes are admitted to the system for processing.
- Selects processes from the job pool.
- Controls the degree of multiprogramming.
-
Short-term Scheduler (CPU Scheduler)
- Decides which of the ready, in-memory processes is to be executed (allocated CPU time).
- Executes frequently (milliseconds).
- Makes decisions based on process priority and scheduling algorithms.
-
Medium-term Scheduler
- Temporarily removes processes from main memory and places them in a backing store (swapping).
- Manages the degree of multiprogramming.
- Involves swapping processes in and out of memory.