Disk and Drum Scheduling

You might also like

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 19

UNIVERSITY INSTITUTE OF TECHNOLOGY

RAJIV GANDHI PROUDYOGIKI VISWAVIDYALAYA


BHOPAL (M. P.)

Presentation on
“ Disk and Drum Scheduling ”

Submitted To Submitted By
Shivesh Kumar Pandey
Mr. Manish Ahirwar Sir 0101cs081054
CSE (5th semester)
Index
1. Disk Scheduling
2. Requirement of Disk Scheduling
3. Disk scheduling Algorithms
I. First Come First Serve (FCFS)
II. Shortest Seek Time First (SSTF)
III. SCAN
IV. C-SCAN
V. LOOK
VI. C-LOOK
VII. n-step SCAN
VIII. FSCAN
4. RAID concept
5. Reference
Disk Scheduling
 Disk scheduling is the problem of deciding which particular
request for data by your computer from your storage medium
should be serviced first.

 It is a fundamental problem in operating system scheduling in


terms of minimizing the waiting time for accessing data from
the hard drive.
Requirement of Disk Scheduling
Seek time: the time for the disk arm to move the heads to the
cylinder containing the desired sector.
Rotational latency: the additional time waiting for the disk to
rotate the desired sector to the disk head.
Disk bandwidth: The total number of bytes transferred, divided
by the total time between the first request for service and the
completion of the last transfer.

Three types of latency (i.e., delay):-


Positional delay (= seek delay + rotational delay) or seek delay –
mechanical and slowest.
Rotational delay
Transfer delay
Computing disk latency:
 Track size : 32K = 32,768 bytes.
 Rotation time : 16.67 msec.
 Average seek time : 30 msec.
 The average time to transfer k bytes :-
Disk Scheduling Algorithms
 First Come First Serve (FCFS)
 Shortest Seek Time First (SSTF)
 SCAN
 C-SCAN
 LOOK
 C-LOOK
 n-step SCAN
 FSCAN
First Come First Serve(FCFS)
 With this scheme, requests are
processed in the order that they
arrive.

 This is very easily


implemented with a FIFO
queue.

 When the hard drive is ready to


deliver information, it pulls the
request from the start of the
queue.
Shortest Seek Time First (SSTF)
 Select the request with the
minimum seek time from the
current head position.

 SSTF is a form of Short Job


First Scheduling.

 May cause starvation of some


requests.
SCAN
 The disk arm starts at one
end of disk, and moves
towards other end.
 Servicing request until it
gets to the other end of the
disk, where the head
movement is reversed and
servicing continues.
 Algorithm requires : the
disk head movement
direction, inward or
outward.
C-SCAN
 The head moves from one
end of the disk to other.
 Servicing requests as it
goes.

 When it reaches to one end


immediately returns to the
beginning of the disk
without servicing any
request on the return trip.
LOOK
 Specialized version of SCAN.
 Arm only goes as the last
request in each direction,
then reverses direction
immediately.

 Going to the end of the disk


is not compulsory as in the
case of SCAN.
C-LOOK
 Specialized version of C-
SCAN.
 Arm only goes as the last
request in each direction,
then reverses direction
immediately.

 Going to the end of the


disk is not compulsory as
in the case of C-SCAN.
n-step SCAN
 Segments the request queue to sub-queues with length of n,
and service them according to SCAN.

 So, we are more fair –not stuck only on one side of the disk if
requests keep coming.
FSCAN
 Contains two queues.

 While treating a queue, incoming requests enter the other


queue.

 When all the requests in the queue are serviced ,switch to


the other queue.

 Treat each queue using SCAN.


RAID
 Redundant Array of Independent Disks (Inexpensive Disks).

 A set of physical disk drives viewed by the Operating System as a


single logical drive.

 Data is distributed across the physical drives of the array.

 Redundant disk capacity is used to store parity information,


which guarantees data recoverability in case of disk failure.
Reference
 http://nixchun.pixnet.net
 http://www2.cs.uregina.ca
 www.wikipedia.com
 www.google.co.in

 Abraham Silberschatz, Greg Gagne, Peter Galvin, “Operating


System Principles”, Wiley.

You might also like