Name: ________________________________ Login: _____________

Comp111 Final Exam
Dec 19, 2012 - open books and notes

No electronic devices of any kind allowed, including cellphones, calculators, pagers, etc. Please turn these off before beginning the exam.

Please show all work on these pages. Feel free to use the back of each page as needed. Make sure that your work for each problem is clearly marked, especially on the backs of pages. These pages will be graded and returned electronically, like exercises, and the results will be made available online.
1a       of 10
1b       of 10
1c       of 10
2a       of 10
2b       of 10
2c       of 10
3a       of 10
3b       of 10
3c       of 20
Total       of 100

    Name: ________________________________ Login: _____________

  1. A web service accepts requests at an average rate of 100 requests/second. The response time is an average of 1/10 second per request.
    1. (10 points) How many requests are queued at a time, on average? Please show your work.

    2. Suppose that you leave everything else constant, and double the speed of the CPU on the computer. How does the answer to the first part of this problem change? Is this answer an upper bound, a lower bound, or an exact estimate of average queue size? Why?

    3. Suppose that you start over from the first part of the problem, and reject 1/2 of the requests through admission control. What happens to the average response time? Is this an upper bound, a lower bound, or an exact estimate?

    Name: ________________________________ Login: _____________

  2. The most expensive disk drives now have built-in flash journals that buffer data before writing it to the disk.
    1. (10 points) What shortcomings of writing the journal directly to disk does a flash journal address?

    2. (10 points) Does this flash require a virtualization layer similar to those used to implement disk-based filesystems on flash? Why or why not?

    3. (10 points) Should the journal hash table be written to flash or disk? Why?

    Name: ________________________________ Login: _____________

  3. Questions about operating system function:
    1. (10 points) Why is memory for processes allocated in pages rather than in smaller units?

    2. (10 points) In scheduling, what is the purpose of organizing schedules into fixed-size "epochs"? Which kinds of scheduling need epochs, and which kinds do not?

    3. (20 points) At the beginning of the course, I indicated that operating systems try to utilize algorithms that run in constant time, i.e., the runtime does not vary with problem size or number of entities being managed. Give several examples of how running in constant time influences operating system design, and then at least one example where we violated the principle in order to achieve better OS functionality and/or features.