edited by
5,043 views
21 votes
21 votes

Disk requests come to disk driver for cylinders $10, 22, 20, 2, 40, 6$ and $38$, in that order at a time when the disk drive is reading from cylinder $20$. The seek time is $6$ msec per cylinder. Compute the total seek time if the disk arm scheduling algorithm is.

  1. First come first served.
  2. Closest cylinder next.
edited by

2 Answers

Best answer
31 votes
31 votes
  1. In FCFS sequence will be $\Rightarrow 20, 10, 22, 20, 2, 40, 6, 38$
    Total movement: $ |20-10| + |10-22| + |22-20| + |20-2| + |2-40| + |40-6| + |6-38| = 146$
    So total seek time $= 146 \times 6 = \mathbf{876 msec}$


     

  2. In Closest cylinder next sequence will be $\Rightarrow 20, 22, 10, 6, 2, 38, 40$
    Total movement: $|20-22| + |22-2| + |2-40| = 60$
    So total seek time $= 60 \times 6 = \mathbf{360 msec}$

edited by
11 votes
11 votes

A)FCFS:(20-10) + (22-10) + (22-2) + (40-2) + (40-6) + (38-6) = 146

But seek time is 6ms per cylinder,So total seek time = 146 * 6 = 876.

B)Closest cylinder next:(22-20) + (22-10) + (10-6) + (6-2)  + (38-2) + (40-38) = 60

So total seek time = 60 * 6 = 360.

edited by

Related questions

0 votes
0 votes
0 answers
1
11 votes
11 votes
1 answer
4
makhdoom ghaya asked Nov 30, 2016
7,138 views
For secondary key processing which of the following file organizations is preferred? Give a one line justification:Indexed sequential file organization.Two-way linked lis...