Home CS439

CS439: Principles of Computer Systems

Homework 8, Part 1

Due in Section on Friday, April 1, 2016

Part 1 of the homeworks must be completed before section and brought to section. Please refer to the homework turnin instructions.

  1. Consider a multi-level paging system with 128 pages and a page size of 256 bytes. The system has 1024 bytes of physical memory and is byte addressable. Assume the first-level page table holds 8 entries.
    1. How many bits are in a physical address?
    2. How many bits of the virtual address represent the first-level page table?
    3. How many bits of the virtual address represent the page number?
    4. How many bits are in the complete virtual address?
    5. What size are the page frames?
  2. Disk requests come into the disk driver for tracks 10, 22, 20, 2, 40, 6, and 38, in that order. A seek takes 6 msec per track moved. How much seek time is needed for the following scheduling algorithms?
    a) FIFO
    b) SSTF
    c) LOOK (SCAN, but doesn't move to the end)
    In all cases, the arm is initially at track 20, and you may assume that the head is traveling towards higher numbers.

    Adapted from Tannenbaum Chapter 5 Number 24.

  3. The MegaGiga hard disk rotates at 5400 rpm with an arm seek time given by = 4 + 0.05t msec, where t is the number of tracks the arm seeks. Assume a block size of 512 bytes, and 1024 tracks with 512 blocks/track, and 2 platters with 4 usable surfaces. The disk controller and DMA read or write data from/to disk at a rate of 4MB/sec. What is the storage capacity of the disk?
  4. Pooh Software Ltd. is selling a file system that uses a UNIX-like file system with multi-level indexing. For more reliability, the inode array is actually replicated on the disk in two different places. The intent is that if one or a group of sectors that are storing either replica of the array become bad, the system can always recover from the replica. Discuss the effect of having this replicated data structure on performance.

  5. Jane would like to append data to the file /usr/jane/classes/cs439/exam_study_notes.txt. Assuming she has the correct permissions, describe the steps the operating system would need to take to append the data.