Download - Disk Sheduling
-
8/12/2019 Disk Sheduling
1/15
Chapter : Mass-Storage Systems
-
8/12/2019 Disk Sheduling
2/15
Overview of Mass Storage Structure
Magnetic disks provide bulk of secondary storage of modern
computers Drives rotate at 60 to 200 times per second
Transfer rateis rate at which data flows between drive andcomputer
Positioning time(random-access time) is time to move disk
arm to desired cylinder (seek time) and time for desired sectorto rotate under the disk head (rotational latency)
Head crashresults from disk head making contact with the disksurface
Thats bad
Disks can be removable
Drive attached to computer via I/O bus
-
8/12/2019 Disk Sheduling
3/15
Moving-head Disk Machanism
-
8/12/2019 Disk Sheduling
4/15
-
8/12/2019 Disk Sheduling
5/15
Disk Scheduling (Cont.)
Several algorithms exist to schedule the servicing of disk I/Orequests.
We illustrate them with a request queue (0-199).
98, 183, 37, 122, 14, 124, 65, 67
Head pointer 53
-
8/12/2019 Disk Sheduling
6/15
FCFS
Illustration shows total head movement of 640 cylinders.
-
8/12/2019 Disk Sheduling
7/15
SSTF
Selects the request with the minimum seek time from the currenthead position.
SSTF scheduling is a form of SJF scheduling; may causestarvation of some requests.
Illustration shows total head movement of 236 cylinders.
-
8/12/2019 Disk Sheduling
8/15
SSTF (Cont.)
-
8/12/2019 Disk Sheduling
9/15
SCAN
The disk arm starts at one end of the disk, and moves toward theother end, servicing requests until it gets to the other end of thedisk, where the head movement is reversed and servicingcontinues.
Sometimes called the elevator algorithm.
Illustration shows total head movement of 208 cylinders.
-
8/12/2019 Disk Sheduling
10/15
SCAN (Cont.)
-
8/12/2019 Disk Sheduling
11/15
C-SCAN
Provides a more uniform wait time than SCAN.
The head moves from one end of the disk to theother servicing requests as it goes. When itreaches the other end, however, it immediately
returns to the beginning of the disk, withoutservicing any requests on the return trip.
-
8/12/2019 Disk Sheduling
12/15
C-SCAN (Cont.)
-
8/12/2019 Disk Sheduling
13/15
C-LOOK
Version of C-SCAN
Arm only goes as far as the last request in eachdirection, then reverses direction immediately,without first going all the way to the end of the
disk.
-
8/12/2019 Disk Sheduling
14/15
C-LOOK (Cont.)
-
8/12/2019 Disk Sheduling
15/15
End of Chapter 12