Question: 3 a . [ Points 5 ] Suppose a file has been allocated 5 0 disk blocks ( numbered 0 . . 4 9 )

3a.[Points 5]Suppose a file has been allocated 50 disk blocks (numbered 0..49). If block 15 is to be deleted, determine the number of read/write operations on blocks assuming: (i) Contiguous allocation (ii) Linked allocation (iii) Indexed allocation (where the index was already loaded in main memory)
3b.[Points 5] Consider a file currently consisting of 50(0..49) blocks. Assume that the file control block (and the index block, in the case of indexed allocation) is already in memory. Calculate how many disk I/O operations are required forcontiguous allocation strategy, to add a new block X. Assume that there is no room to grow atthe beginning but there is room to grow at the end. Also assume thatthe block information to be added is stored in memory.
Block X is to be added at the beginning (so it becomes the 0thblock of the file)
Block X is to be added in the middle (so it becomes the 25thblock of the file).
Block X is added at the end (so it becomes the 50thblock of the file).
3c.[Points 5] Consider a file currently consisting of 50(0..49) blocks. Assume that the file control block (and the index block, in the case of indexed allocation) is already in memory. Calculate how many disk I/O operations are required forlinked allocationstrategy, to add a new block X. Assume that there is no room to grow atthe beginning but there is room to grow at the end. Also assume thatthe block information to be added is stored in memory.
Block X is to be added at the beginning (so it becomes the 0thblock of the file)
Block X is to be added in the middle (so it becomes the 25thblock of the file).
Block X is added at the end (so it becomes the 50thblock of the file).
3d.[Points 5] Answer the following questions relating to free-space management.
1. What is the advantage of managing the free-space list as a bit-vector as opposed to a linked list?
2. Suppose a disk has 128 K blocks, each block of 2 Kbytes, how many blocks are needed for managing a bit-vector?

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!