Scheduler: Scheduler is the part of the operating system which decides which process has to be run and when in a multiprogramming environment. Scheduler also has to make sure that the CPU usage must be maintained in an efficient manner.
CPU bound process: A CPU bound process is the one which has long CPU bursts and waiting for I/O is uncommon. A CPU bound process is busy for longer time in computation.
I/O bound process: An I/O bound process is the one which has short CPU bursts and waiting for I/O is common. An I/O bound process is busy for longer time waiting for I/O requests.
Situations where scheduling is required: Here are the common situations where scheduling is required:
1) Creation of process: When a process is created, scheduling is required. A scheduler has to decide when to run the process.
2) On completion of a process: When a process is completed scheduler has to decide which process needs to be run next.
3) On occurrence of I/O interrupt: When an interrupt occurs, the process which was running is blocked and the scheduler has to make a decision on which process needs to be run next.