Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Consider a file currently consisting of 8 3 blocks. Assume that the file control block ( and the index block, in the case of indexed
Consider a file currently consisting of 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 IO operations are required for contiguous, linked, and indexed singlelevel allocation strategies, if for one block, the following conditions hold. In the contiguous allocation case, assume that there is room to grow in the beginning and in the end. Assume that the block information to be added is stored in memory. For linked allocation, there is a head and tail pointer pointing respectively to the first and last node.
Note that while calculating the total number of IO operations for each, also indicate how many are from r read and w write For each part, if there is more than one answer, choose the one that gives you the least number of IO operations.
The block is removed from the beginning
The block is added after st block
The block is removed from the end
Assumptions:
Read one whole block one IO operation
Write one whole block one IO operation
The directory information for each allocation is already in the RAM. If the directory information is updated, it does not need to be written back to the disk
For linked allocation, a file allocation table FAT is not used, ie only the address of the starting and ending block is in memory
All preparation of a block including putting in the data and any link value is done in main memory and then the block is written to disk with one write operation
The file control block does not have to be written to disk after a change this is typical where many operations are performed on a file
At most one index block is required per file and it does not have to be written to disk after a change
For linked, contiguous and indexed allocations, assume that no IO operations are necessary to add a freed block to the free list
The OS has information about the free blocks. It does not have to go to the disk to find a free block
When a block is removed, nothing needs to be written to that disk block indicating it is removedConsider a file currently consisting of 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 IO operations are required for contiguous, linked, and indexed singlelevel allocation strategies, if for one block, the following conditions hold. In the contiguous allocation case, assume that there is room to grow in the beginning and in the end. Assume that the block information to be added is stored in memory. For linked allocation, there is a head and tail pointer pointing respectively to the first and last node.
Note that while calculating the total number of IO operations for each, also indicate how many are from r read and w write For each part, if there is more than one answer, choose the one that gives you the least number of IO operations.
The block is removed from the beginning
The block is added after st block
The block is removed from the end
Assumptions:
Read one whole block one IO operation
Write one whole block one IO operation
The directory information for each allocation is already in the RAM. If the directory information is updated, it does not need to be written back to the disk
For linked allocation, a file allocation table FAT is not used, ie only the address of the starting and ending block is in memory
All preparation of a block including putting in the data and any link value is done in main memory and then the block is written to disk with one write operation
The file control block does not have to be written to disk after a change this is typical where many operations are performed on a file
At most one index block is required per file and it does not have to be written to disk after a change
For linked, contiguous and indexed allocations, assume that no IO operations are necessary to add a freed block to the free list
The OS has information about the free blocks. It does not have to go to the disk to find a free block
When a block is removed, nothing needs to be written to that disk block indicating it is removed
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started