磁盘管理

来源:互联网 发布:每日流量控制软件 编辑:程序博客网 时间:2024/05/22 14:08
  1. Disk requests come in to the disk driver for cylinders 10, 22, 2, 40, and 38 in that order. The arm is initially at cylinder 20. Suppose a piece of seek takes 6ms per cylinder moved. Please compute seek time using:
    (a)FCFS (First come first served);
    (b)SSF (Shorted seek first);
    (c)ELEVATOR ALGORITHM (initially moving upward).
    Please draw the arm motion figure.

磁盘请求按顺序进入磁盘驱动器10,22,2,40和38。 手臂最初是在柱面20上。假设一块寻道柱面移动花费6毫秒。 请使用以下方式计算搜索时间:
(a)FCFS(先来先服务);
(b)SSF(最短寻道优先);
(c)电梯算法(最初向上移动)。
请绘制手臂运动图。

Answer:
(a)
Seek time=(10+12+20+38+2)×6
=492ms

这里写图片描述
从20开始,按照题目所给顺序依次寻找就可以了


(b)
Seek time=(2+12+8+36+2)×6
=360ms
这里写图片描述
从20开始,每次都找离当前位置最近的柱面


(c)
Seek time=(2+16+2+30+8)×6
=348ms
这里写图片描述


In which of the four I/O software layers is each of the following done.
(a)Computing the track,sector,and head for a disk read.
(b)Writing commands to the device registers.
(c)Checking to see if the user is permitted to use the device.
(d)Converting binary integers to ASCII for printing


在四个I / O软件层中的哪一个是以下每个完成的。
(a)计算磁盘读取的轨道,扇区和磁头。
(b)向设备寄存器写入命令。
(c)检查用户是否被允许使用设备。
(d)将二进制整数转换为ASCII进行打印


Solution:
(a) Device driver
(b) Device driver
(c) Device-independent IO software
(d) User-level IO software


解:
(a)设备驱动程序
(b)设备驱动程序
(c)与设备无关的IO软件
(d)用户级IO软件

原创粉丝点击