Long-Term Scheduler
The long-term scheduler works with the batch queue and selects the next batch job to be executed. Thus it plans the CPU scheduling for batch jobs. Processes, which are resource intensive and have a low priority are called batch jobs. These jobs are executed in a group or bunch. For example, a user requests for printing a bunch of files. We can also say that a long-term scheduler selects the processes or jobs from secondary storage device eg, a disk and loads them into the memory for execution. It is also known as a job scheduler. The long-term scheduler is called “long-term” because the time for which the scheduling is valid is long. This scheduler shows the best performance by selecting a good process mix of I/O-bound and CPU-bound processes. I/O bound processes are those that spend most of their time in I/O than computing. A CPU-bound process is one that spends most of its time in computations rather than generating I/O requests.
Difference between Short-Term, Medium Term, and Long-Term Scheduler
Process scheduling is an important activity done by the process manager to remove the process from the CPU and schedule the next process, the process removal and dispatch are based on multiple factors like process completion, priority, I/O requirement, etc. Process scheduling plays an important role in Multiprogramming operating systems.
There are mainly three types of schedulers in operating systems, which are: Short-term schedulers, medium-term schedulers, and long-term schedulers. In this article, we are going to discuss about difference between these schedulers.