Consider a file currently consisting of 100 blocks. Assume that the file control
ID: 3847607 • Letter: C
Question
Consider a file currently consisting of 100 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 for contiguous, linked, and indexed (single-level) allocation strategies, if, for one block, the following conditions hold. In the contiguous-allocation case, assume that there is no room to grow at the beginning but there is room to grow at the end. Also assume that the block information to be added is stored in memory. The block is added at the beginning. The block is added in the middle. The block is added at the end. The block is removed from the beginning. The block is removed from the middle. The block is removed from the end.Explanation / Answer
contiguous: file is usually accessed sequentially,if file is small linked: file is large, accessed sequentially indexed:file is large, accessed randomly case a)when the block is added at the beginning: contiguous: 201 linked: 1 indexed:1 case b)when the block is added in the middle: contiguous: 101 linked:52 indexed:1 case c)when the block is added at the end contiguous:1 linked:3 indexed: 1 case d)when the block is removed from the beginning contiguous:198 linked:1 indexed:0 case e)when the block is removed from the middle contiguous:98 linked:52 indexed:0 case f)when the block is removed from end contiguous:0 linked:100 indexed: 0
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.