edited by
7,481 views
4 votes
4 votes

Consider the disk system with 100 cylinders. The request to access the cylinders occur in the following sequence.

4, 37, 10,7,19,73,2,15,6,20

Assuming the head is currently at cylinder 50 what is the time taken to satisfy all requests if it takes 1 ms to move from one cylinder to adjacent one and shortest seek ime first algorithm is used.

  1. 95 ms
  2. 119 ms
  3. 233 ms
  4. 276 ms
edited by

2 Answers

Best answer
10 votes
10 votes
As shortest seek time algorithm is used and the head starts from cylinder 50, the order followed is :

$50\rightarrow 37\rightarrow 20\rightarrow 19\rightarrow 15\rightarrow 10\rightarrow 7\rightarrow 6\rightarrow 4\rightarrow 2\rightarrow 73$

So, as it takes 1 ms to move to adjacent cylinder, the time taken is:

13+17+1+4+5+3+1+2+2+71 =119 ms

Hence option (B) is right answer.
selected by
0 votes
0 votes

The given sequence is
4, 34, 10,7, 19, 73, 2, 15, 6, 20
Arrange the sequence in order
2, 4, 6, 10, 15, 19, 20, 34, 73
 ⇒ 1 ms to move from one cylinder to adjacent one
⇒ (16*1)+(14*1)+(1*1)+(4*1)+(5*1)+(3*1)+(1*1)+(2*1)+(2*1)+(71*1)
⇒ 16+14+1+4+5+3+1+2+2+71
⇒ 119 ms

Answer:

Related questions

7 votes
7 votes
2 answers
1
sh!va asked May 7, 2017
6,411 views
Which of the following statement is true?Hard real time OS has less jitter than soft real time OSHard real time OS has more jitter than soft real time OSHard real time OS...
5 votes
5 votes
1 answer
2
sh!va asked May 7, 2017
7,444 views
The Linux command mknod myfifo b 4 16will create a character device if user is rootwill create a named pipe FIFO if user is rootwill create a block device if user is root...
6 votes
6 votes
4 answers
3
sh!va asked May 7, 2017
5,452 views
A critical regionis a piece of code which only one process executes at a timeis a region prone to deadlockis a piece of code which only a finite number of processes execu...
6 votes
6 votes
3 answers
4
sh!va asked May 7, 2017
6,682 views
Mutual exclusion problem occursbetween two disjoint processes that do not interactamong processes that share resourcesamong processes that do not use the same resourcebet...