【正文】
1, 5, 6, 2, 1, 2, 3, 7, 6, 3, 2, 1, 2, 3, 6.How many page faults would occur for the following replacement algorithms, assuming one, two, three, four, five, six, or seven frames? Remember all frames are initially empty, so your first unique pages will all cost one fault each.LRU replacementFIFO replacementOptimal replacement第十二章 Consider a file currently consisting of 100 blocks. Assume that the file control block (andthe index block, in the case of indexed allocation) is already in memory. Calculate howmany disk I/O operations are required for contiguous, linked, and indexed (singlelevel)allocation strategies, if, for one block, the following conditions hold. In the contiguousallocation case, assume that there is no room to grow in the beginning, but there is room to grow in the end. Assume that the block information to be added is stored in memory.a. The block is added at the beginning.b. The block is added in the middle.c. The block is added at the end.d. The block is removed from the beginning.e. The block is removed from the middle.f. The block is removed from the end. Suppose that a disk drive has 5000 cylinders, numbered 0 to 4999. The drive is currentlyserving a request at cylinder 143, and the previous request was at cylinder 125. The queueof pending requests, in FIFO order, is86, 1470, 913, 1774, 948, 1509, 1022, 1750, 130Starting from the current head position, what is the total distance (in cylinders) thatthe disk arm moves to satisfy all the pending requests, for each of the following diskschedulingalgorithms?(假設(shè)一個(gè)錯(cuò)哦盤驅(qū)動(dòng)器有5000個(gè)柱面,從0到4999,驅(qū)動(dòng)器正在為柱面143的一個(gè)請(qǐng)求提供服務(wù),即將到來的請(qǐng)求隊(duì)列是 86,1470,913,1774,948,1509,1022,1750,130從現(xiàn)在磁頭位置開始,按照下面的磁盤調(diào)度算法,要滿足隊(duì)列中即將到來的請(qǐng)求要求磁頭總的移動(dòng)距離(按柱面數(shù)計(jì))是多少?)a. FCFSb. SSTFc. SCANd. LOOKe. CSCANa. FCFS的調(diào)度是143, 86, 1470, 913, 1774, 948, 1509, 1022, 1750, 130.總尋求距離是7081.b. SSTF的調(diào)度是143, 130, 86, 913, 948, 1022, 1470, 1509, 1750, 1774. 總尋求距離是1745.c. SCAN的調(diào)度是143, 913, 948, 1022, 1470, 1509, 1750, 1774, 4999, 130, 86. 總尋求距離是9769.d. LOOK的調(diào)度是143, 913, 948, 1022, 1470, 1509, 1750, 1774, 130, 86. 總尋求距離是3319.e. CSCAN的調(diào)度是143, 913, 948, 1022, 1470, 1509, 1750, 1774, 4999, 86, 130. 總尋求距離是9813.f. CLOOK的調(diào)度是143, 913, 948, 1022, 1470, 1509, 1750, 1774, 86, 130.總尋求距離是3363.