0% found this document useful (0 votes)
433 views5 pages

Disk Management: Multiple Choice 1ype Questions

1) The document discusses disk management concepts including RAID configurations, seek time, rotational latency, disk scheduling algorithms, and disk drive components. 2) It provides examples to calculate the average cylinder movements for different disk scheduling algorithms, including SSTF, C-SCAN, and SCAN. The queue of pending requests and current head position are given to solve the examples. 3) Key disk concepts like seek time, rotational latency, advantages of SCAN over C-SCAN, and disadvantages of SSTF are explained in short answer questions. Sample calculations of average cylinder movements are shown for given disk drive specifications and request queues.

Uploaded by

Suraj Dasgupta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
433 views5 pages

Disk Management: Multiple Choice 1ype Questions

1) The document discusses disk management concepts including RAID configurations, seek time, rotational latency, disk scheduling algorithms, and disk drive components. 2) It provides examples to calculate the average cylinder movements for different disk scheduling algorithms, including SSTF, C-SCAN, and SCAN. The queue of pending requests and current head position are given to solve the examples. 3) Key disk concepts like seek time, rotational latency, advantages of SCAN over C-SCAN, and disadvantages of SSTF are explained in short answer questions. Sample calculations of average cylinder movements are shown for given disk drive specifications and request queues.

Uploaded by

Suraj Dasgupta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

MOPERATING SYSTEM

DISK MANAGEMENT
Multiple Choice 1ype Questions
uration disks are used to provide
R A I Dc o n f i g u r a t i o n
WBUT 2007, 2014(CS), 2016(CS)]
a )f a u l t t o l e r a n c e
b) nearest cylinder next
d) none of these
data density b
c high
Answer:(a)
aa move the disk arm to be desired cylinder in a hard disk is known as
time ton
2
The WBUT 2012(CS), 2016(CS)]
a) Rotainaly latency b) Positioning time
c )Indexed
d) Hashed
Answer: (a)
h of the following is crucial time while accessing data on the disk?
WBUT 2013(1T)]
a) seek time b) rotational time
c) transmission time d) waiting time
Answer: (a)
Time required of read-write head to move to desired cylinder is WBUT 2013(IT)]
a) transfer time b) seek time
c) rotational latency e t tol eln d) none of thesetevs srt atg
Answer: (b)
5.Where does the swap space reside? WBUT 2014(IT), 2017(T), 2018(T)
a) RAM b) DISK c) ROM d) on-chip cache

Answer: (b)
WBUT 2014(IT), 2017(IT)]
6.The smallest possible unit of disk storage isc) block d) extent
a) word b) segment
Answer: (c)

disk drive mechanism for a block of data to be read


e total time to
from is its
prepare a
WBUT 2018(CS)]
a) Access time
b) Seek time
c) Latency plus seek time
time
ACCess time plus seek time plus transmission
Answer: (c)

OS-103
POPULAR PuBLICATIONS OPERATING STEM
Short Answer Type Questions c y l i n d e rm o v e m e n t s

(120-90)+(17
(170-120)+(19
(199-170)+(270-199)
1. a) What is seek time? What is rotational latency?
b) What are the advantages of SCAN disk Scheduling technique over ei.
(299-270)+(299-89)+ (89-79)+(79
(36-15)
disk scheduling technique?
Answer:
BUT 2013(CS), 2017(IT)
0+50+29+71+29 +210+10+43+21

a) 1 Part: 493 movement for scan will be


Seek time is defined as the time required to move the disk arm to cylinder
the reast.
the required tr .Average
consists of two key components:
i) The initial startup time
k. It
493 49.3
i) The time taken to traverse the tracks that have to be crossed once
10
the
to speed. access
accee
arm is oe e L LongAnswer Type Questions t 2
up
2nd Part: OOOSe a disk drive nas00 cyinders, numbered 0 to 299. The current head
Rotational latency is defined the time required to reach the desired
as
sector bv tho .. at 90. The queue of pending requests, in FIFO order is 36, 79,
1.n of the disk is170.
write head. Magnetic disks have rotational speed in the range 5400 to
10,000 r.D m 15, 120, 199,
270, 89,
alelate the average cylinder movements for the following algorithms:
b) i) The average head movements in scan is less than c-Scan
ii) C-SCAAN.
i) SSTF; WBUT 2007, 2010, 2013(IT)]
ii) The c-scan increases the total seek time but scan does not. scheduling algorithm. OR,
SuODOse a disk drive has 300 cylinders, numbered 0 to 229. The current head
2. Suppose a disk drive has 300 at 90. The queue of pending requests, in FlFO order is 36, 79,
oosition of the disk is170.
cylinders, numbered 0 to 299. The
current head 15, 120, 199, 270,
89,
position of the disk is at 90. The queue of pending requests, for Shotest Seek Time First (SSTF)
15, 120, 199, 270, 89, 170
in FIFO order is
36, 79 Calculate the average cylinder movements
algorithm. Mention any one disadvantage of SSTF WBUT 2009, 2015(CS)]
Calculate the average cylinder movements for the
i) SSTF following algorithms: Answer:
i) C-SCAN ) For SSTF algorithm,
ii) SCAN 5 36 79 89 120 170 199 270 299
Answer: WBUT 2019(C
0
i) and i): Refer to Question No. 1 of Long Answer Type Questions.
ii) Scan: Jaelianaoilt The head movements are
Given queue 36, 79, 15, 120, 199, 270, tow (199-170)
=(90 -89) +(89-79)+ (120 79) + (170- 120) + +(270-199)
89, 170 + (270-36) + (36-15)
Current head position = 90
=I+ 10+41+ 50 + 29 +71 +234 + 21-457
79 89 90 457/8 57.125
120 170 199 270 299 Theaverage cylinder movements will be = =

ii)C-SCAN:
Given queue = 36, 79, 15, 120, 199, 270, 89, 170
oee eulg yontus Current head position =
90.
270 299
0 15 36 79 89 120 170 199

90

OS-104 OS-105
POPULAR PUBLICATIONS
OPERATING SYSTEM
movements (90- 89) +(89-79) (79- 36) (36-15)+(1
+ +
Cylinder +(0-299) +(299-270) +(270-199) + (199-17 (15-0) Disadvanages:
= 1+10+43+21+15+200+71+29+50= 568 Starvationm a y occur.

s S T Fs e r v i c e s r e q u e s t s uests for those tracks which are highly localized. So, the innermost
cylinder movement for
SSTF =
5 6.8 .
receive poor service to the as compared
tracks. midrange
Average 10 o u t e r m o s t
tracks

and
120 199 270
15 89 170
Last Part: b )F C F S :

the SSTF algorithm is substantial improvement over


over he
Although a
the ECEo
FCFS,
optimal.
but it hot

2. a) Explain the working of Shortest Seek Time First (SSTF) disk se 79


1219 2
policy. What are its advantages and disadvantages? =

b) Suppose a disk drive has 300 cylinders, numbered 0 to 299. The current m o v e m e n t s

of the desk arm is 90. The queue of pending requests, in FIFO orderis sition Total
head
+(170-36)+ (79-336) + (79-15) + (120-15) + (199-120) +(270-99)+
90)+
120, 199, 270, 89, 170. Calculate the average movements for the fo,75 (170-
the following (270-89) + 71 + 181 =
757
algorithms: + 64 + 105 +79
i) FCFS sSTF. vc WBUT 2013(CS), 2047 80+ 134 + 43
Average
head movements 94.62
Answer: 8
a) This algorithm works on this principle "When a disk operation finishes, cho
or choose the the sSTF: Refer
to Question No. I
of Long Answer Type Questions.
request that is to
closest the current
seek time from the current head position"
head position request that has
nimum Averagehead movements i.e. =57.12 o o litnassa. oi5 ene tur
Consider the disk Queue, (87, 170, 40, 150, 36, 72, 66. 15). alb
The initial head position is say 60. Now, closet to the head position is the equest a
disk read/write head
movement diagram for SSTF, SCAN, C-SCAN and
cylinder 66. Then the closet to 66 is 72, and then 87 and so on. 3. Draw the
we track requests as WBUT 2016(CS), 2016(T)]
FIFO, for the
0 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 160 170 T1 25, 75, 35, 100, 95, 175, 78, 125, 90, 35
Answer:
SSTF: [Initial position =60 (say)]
35
25,75,35, 100, 95, 175, 78, 125, 90, 140 150 160 170 180
S0 60 70 80 90 100 110 120 130
0 10 20 30 40

150 170
100 125

Total head movement in SSTF are


(66-60) + (72-66)+ (87-72) + (87-40)+(40-36)
+(36-15) + (150 -15) +(170-150) FIFO: [Initial position =60 (say)] 170 180
= 6+6+15+37+4+21+135+20 244 Cylinders 120 30 40 50 60 70 80 90 100 110 120 130 140 150 160

244
Average head movements = =30.5 Cylinder

2nd Part:
Advantages of SSTF:
i) It minimizes latency 125

ii) Better though put than FIF0.


OS-106 OS-107
POPULAR PUBLICATIONS
OPERATING SYSTEM
SCAN [Initial pointer = 60 (say)]

115 143 110 80 20


F C F Sa l g o r i t h m :

90 100 110 120 130


0 10 20 30 40 50 60 70 140 150 160
30 70
170
R0
Change Change No No Change No No Change
change
under CFS algorithm= 4
4
head
100 Total
time. and latency time?
hat are
seek
WBUT 2018(IT)
A n s w e r :

Seektime:

r
time required to move the disk arm to the required track.
C-SCAN [Initial pointer = 60 (say)]
Itis
defined as the
n+S

0 10 20 30 40 50 60 70 80 90 ie.
T,=m
100 10 120
130 140 150 160
170 180 seek time
T,=Estimated
Where
n No. oftracks reversed disk drive
195 100
m Constant that depends on

S Start uptime

Latency time:
eiedefined as the time required to reach the defined sector by the read/write head.
Latency can be computed by dividing the number of revolution per minute, R, into 30
4. a) What are the essential goals of disk scheduling?Why 30
is each
important? ie. 1
Answer: A WBUT 2018(IT)]
To satisfy a series of I/O request which can affect the b) Describe physical and logical formatting of disk. WBUT 2018(IT)]
required. These are no. of algorithms for scheduling disk performance,
disk scheduling is
I/O requests, like FIFO Answer:
requests in the order they are received), priority (According to the priority (service Ahard disk must be physically formatted before it can be logically formatted. A hard
the requesting process), SSTF associated with disk's physical formatting is usually performed by the manufacturer. Physical formatting
(Services the request whose track position is closest to the
current track position), SCAN divides the hard disk platters into their basic physical elements: Tracks, sectors and
(Move the read/write head back and forth between the
innermost and outermost track), Look (head cylinders. These elements define the way in which data is physically recorded on and
for the closest track in that
moving in one direction, satisfy the request read from the disk. Tracks are concentric circular paths written on each
direction), CSCAN (satisfy request while going in one and it is identified by number starting with track zero.
r e of a platter
directions, when the last track has been reached these
track). algorithms return to the starting Tracks are divided into smaller areas called sectors which are used to store a fixed
amount of data. It is usually formatted to contain 512 bytes of data.
b) A disk has 200
tracks (numbered 0 A cylinder is combined of a set of tracks that lie at the same distance from the spindle on
servicing the request of reading data fromthrough 199). At a given time, it was
track 120, and at the previous all the
service was for track 90, the
pending requests
reques so
located at the same distance from the platter.
For example, track three on every side of every platter is

track numbers 30, 70, 115, 143, 110, 80, 20, 25.(inHow many their
order of arrival) are fo spindle.
times will the heao IC a. hard disk has been physically formatted, it must also be logically formatted.
change direction for the disk scheduling
policies SSTF and FCF$? ocal formatting places a file system on the disk, allowing an operating system (Such as
WBUT 2018(1T)] the available disk space to store and retrieve files. Different
Answer: OSdifferent
ndows, linux) to use
file system. So logical file systems depends on OS formatting your
Current head movement =
lower to
SSTF algorithm: higher nard disk with one file system necessarily limits the number and types or . Dut
115 110 80 70 dividedution to the above problem. Before a disk is logically formatted,fileit can be
Change No 30 20 143 allowinPartitions.
allowing one to install
Each partition can be formatted with a different system,
No
Total head change under SSTF No No No No Change OS. multiple
algorithm =
2

OS-108 OS-109
POPULAR PUBLICATIONS
OPERATING SYSTEM
and C-SCAN algorithm in the context of disk
isk schedu
duling.
c) Compare SSTF

Answer:
In shortest Seek Time First (SSTH) algorithm request is serviced
WBUT 2018(T) BadBlock

Bs have
generally
tendency to become a tailure. Sometimes one or more sectors
A disk block with one or more bad sectors are called
ced become defective. A bad blocks.
according to nex
Disks

shortest distance. For example, comefarmat command, as a part ot Tormatting process, scans the disk to find bad
special value in the corresponding FAT entry to specify to the
34 50 62
MS-DOS

645 19123 180 199 blocks a n d


i n e not to allocate that block. Data that reside on the bad block are lost.
allocation routine

can be told to replace each bad sector logically with some sector
The disk aside during low-level formatting process. This scheme is known spare
as sector
aside
set
was
that
sparing or forwarding.

Some controlle
llers can be instructed to replace a bad block by sector slipping process.

and C-Scan algorith m:


Starting at 50,the next shortest distance is 62 instead of 34 since it is b) Scan
onlv 19 . alaorith m, the disk arm starts at one end of the disk
and moves towards the
from 62 to64 instead of 34 since there are only 2 tracks between them trac an
In the servicing
and s away requests as it reaches each
cylinder, until it
were to go the another way. Then it is 34 and then lI so on from 11 it can mo gets to the other end of
ifit othe At the other end, the direction of head movement is reversed and
and so on. oves to 95 servicing
But in C-scan (Circular Scan) algorithm it works just like the uous, The head continuously scans back and forth across the disk. The scan
elevator to some rithm is sometimes called elevator
algorithm, since the disk arm behaves just like an
it begins the scan towards the nearest end like S0 to 34,then Il and
then 199, 1R0 elevator in a building, Iirst serviCing a l request going up and then reversing to service
119, 95, 64, 62. 23 the other way.
11 34 50 62 64 95 119 123 180 199 requests
0 Example:
98, 183, 37, 122, 14, 124, 65, 67
Head starts at
=
53.
67 98 122 124 183 199

6. Write short notes on the 67


a) Boot block and Bad block
following:
b) Scan and C-Scan algorithmm WBUT 2008, 2012(CS)]
c) Scan disk scheduling algorithm [WBUT 2016(1T)] C-SCAN (Circular Scan) Scheduling is a variant of SCAN designed to
Answer: WBUT 2018(CS]] uniform wait time. Like scan, C-SCAN moves the provide a more
head from one end of the disk to
a) Boot Block other servicing request along the way. When the head reaches the other end, however,theit
When a computer is switched on an immediately returns to the beginning of the disk without
initial program called boot strap servicing any on the request
initializes the CPU registers, device controllers programme, wn return trip.
and other contents of main
then starts the operating system by finding out O.S. kernel on memory and
the disk, loading the
0 14 37 53 65 67 98 122 124 183 199
nto memory and begins the operating system execution from a fixed initial address. kernc
system stores a tiny boot strap loader in the boot ROM which in
Mos
Tull boot strap program from disk thatprogram
is stored in a
turn invoxc
disk called the boot block. A disk having a boot partition at a fixed location on
disk. partition is called a boot disk o system

You might also like