Skip to main content

Disk scheduling operating system




DISK SCHEDULING ALGORITHMS

A hard disk drive is a collection of plates called platters. The surface of each platter is divided into circular  tracks. Further more, each track is divided into smaller pieces called sectors. Disk I/O is done sector by sector. A group of tracks that are positioned on top of each other form a cylinder. There is a head connected to an arm for each surface, which handles all I/O operations.
For each I/O request, first  head is selected. It is then moved over the destination track. The disk is then rotated to position the desired sector under the head= and finally, the read/write operation is performed.
There are two objectives for any disk scheduling algorithm:
1. Minimize the throughput - the average number of requests satisfied per time unit.
2. Maximize the response time - the average time that a request must wait before it is satisfied.
Some of the disk scheduling algorithms are explained below.
  1. FCFS (First Come, First Served)
    • perform operations in order requested
    • no reordering of work queue
    • no starvation: every request is serviced
    • poor performance
  2. SSTF (Shortest Seek Time First)
    • after a request, go to the closest request in the work queue, regardless of direction
    • reduces total seek time compared to FCFS
    • Disadvantages
      • starvation is possible; stay in one area of the disk if very busy
      • switching directions slows things down
  3. SCAN
    • go from the outside to the inside servicing requests and then back from the outside to the inside servicing requests.
    • repeats this over and over.
    • reduces variance compared to SSTF.
  4. LOOK
    • like SCAN but stops moving inwards (or outwards) when no more requests in that direction exist.
  5. C-SCAN (circular scan)
    • moves inwards servicing requests until it reaches the innermost cylinder; then jumps to the outside cylinder of the disk without servicing any requests.
    • repeats this over and over.
    • variant: service requests from inside to outside, and then skip back to the innermost cylinder.
  6. C-LOOK
    • moves inwards servicing requests until there are no more requests in that direction, then it jumps to the outermost outstanding requests.
    • repeast this over and over.
    • variant: service requests from inside to outside, then skip back to the innermost request.

Comments

Popular posts from this blog

Download Sample Paper Of Cyber Security & Cyber Laws - Delhi Polytechnic - B.T.E Delhi

Cyber Security & Cyber Law Cyber Security & Cyber Law Cyber Security & Cyber Law

Download Sample Paper E-Commerce & M-Commerce - BTE Delhi- Delhi Polytechnic

sample Paper:EDM