Homework #5
CMSC 421, Section 0101 (Spring 1999)
Assigned: 28 April 1999
Due: 5 May 1999
Late homeworks will not be accepted.
- Problem 10.3 from the text.
- Problem 10.6 from the text.
- Problem 11.1 from the text.
- Consider a Unix file system with 12 direct pointers in each inode and 4 KB file blocks.
- How much overhead would be needed to store index blocks for a 100 MB file, not including the inode itself? What percentage of total file size would the overhead be?
- On average, how many 4 KB blocks would have to be read to get a random block from the file? Again, assume the inode is already in memory and doesn't need to be read from disk. HINT: figure out how many blocks can be read for each of direct, single, double, triple indirect and compute the average from this information.
- Suppose we have a disk with 6000 cylinders, numbered 0 to 5999. The disk is currently serving a request at track 492, and the previous request served by the disk was at track 431. The queue of pending requests (in order of time arrival, oldest request first) is:
301, 2001, 5197, 1984, 2102, 86, 155, 4033, 3988
Starting from the current head position, waht is the total seek distance (in cylinders) that the disk head has to travel using each of the following disk scheduling algorithms:
- FCFS
- SSTF
- SCAN
- LOOK
- C-LOOK
- Problem 13.10 from the text.