The University of Nottingham: Operating Systems

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

G53OPS-E1

The University of Nottingham


SCHOOL OF COMPUTER SCIENCE

A LEVEL 3 MODULE, SPRING  SEMESTER 2010-2011

OPERATING SYSTEMS

Time allowed TWO hours

Candidates may complete the front cover of their answer book and sign their desk card but must
NOT write anything else until the start of the examination period is announced

You must answer FOUR questions out of SIX


(only the FOUR nominated solutions will be marked)  
 
Only silent, self contained calculators with a Single-Line Display are permitted in this
examination.

Dictionaries are not allowed with one exception. Those whose first language is not English may
use a standard translation dictionary to translate between that language and English provided
that neither language is the subject of this examination. Subject specific translation dictionaries
are not permitted.

No electronic devices capable of storing and retrieving text, including electronic dictionaries, may
be used.

DO NOT turn your examination paper over until instructed to do so

G53OPS-E1 Turn over


G53OPS-E1

1. Describe the three most basic process states in a multi-programming operating


system and the transitions possible between them.
(5 Marks)

There are many different policies for scheduling runnable processes. Name and briefly describe
five of these.
(10 Marks)

The three basic process states need to be extended for a practical operating system. Draw a
state transition diagram showing the most important extra states that may be needed and
explain the purpose of each and how they relate.
(10 Marks)

2. (a) Coffman gives four conditions that must hold for a deadlock to be present. List and
briefly explain each one.
(8 Marks)

(b) Briefly describe two options for recovery from deadlock, giving any advantages and
disadvantages.
(6 Marks)

(c) In order to avoid race conditions, what four conditions must be satisfied?
(6 Marks)

(d) Show the strict alternation algorithm.


(5 Marks)

G53OPS-E1 Turn over


G53OPS-E1
3. (a) Describe the operation of Translation Lookaside Buffers (TLBs – also know as Current
Page Registers) in a paged operating system. What is the sequence of events when

(i) a TLB is 'hit';

(ii) a TLB is 'missed' but the required page is in main memory;

(iii) a TLB is 'missed' but the required page is not in main memory.

Show clearly how the various components of the system fit together.
(17 Marks)

(b) In a simple paged system with only one level of page tables the access times are as
follows.

ASSOCIATIVE MEMORY HIT:


To read associative memory 1 ns
To read main memory 6 ns

ASSOCIATIVE MEMORY MISS:


To read associative memory 1 ns
To add the page number to the page table origin register 2 ns
To read page table 6 ns
To read main memory 6 ns

(i) Calculate the effective access time for a hit rate of 93 per cent.
(3 Marks)

(ii) If the page fault service time is 1.2 ms, what is the maximum page fault rate
that the system can tolerate without incurring more than a 15 per cent degradation.
(5 Marks)

4. (a) In a paged operating system, when a page is to be brought into main memory from
disc, it must be placed in a page frame. If there is no empty page frame available, a page must
be evicted from main memory to make room for the new page. The choice of which frame to
select is made by a page replacement algorithm. Describe two page replacement algorithms.
(6 Marks)

(b) Briefly describe how paging mechanisms can be used in conjunction with the working
set model to produce performance improvements in virtual memory systems.
(6 Marks)

(c) Explain the mechanism and problems associated with multiprogramming operating
systems that use variable size partitions. When linked lists are used to store the used and free
partitions, a memory allocation algorithm is needed. Briefly describe three such algorithms.
(13 Marks)

G53OPS-E1 Turn over


G53OPS-E1

5. (a) UNIX uses a “pointers to blocks” method in the form of inodes to implement it's
hierarchical file system. Describe how the original (non-Berkeley) UNIX does this and contrast it
to another system of your choice.
(10 Marks)

(b) Explain how the Berkeley File System increases the throughput of the original Unix by
various means.
(15 Marks)

6. (a) Discuss the aims of process scheduling.


(8 Marks)

(b) You are responsible for maximizing the utilisation of computing resources for a large
scale multiuser system. You are receiving complaints from most users about response and
turnaround times when accessing the server. Investigations reveal that the CPU is being utilised
only 20% of the time. Which of the following could be reasons for the poor CPU utilisation?
Explain why for each that you choose and why not for the others.

i) insufficient memory;

ii) frame size too small;

iii) frame size is too large;

iv) too much memory;

v) one CPU is not enough.


(8 Marks)

(c) Assume a disc has the following characteristics: 1000 sectors (numbered 0
to 999) per surface; 10 sectors per track; and tracks are numbered from 0 (innermost) to 99
(outermost). Consider the following time ordered list of disc I/O requests, where the value given
is the sector number requested.

548, 123, 459, 156, 645, 818, 825, 843, 239

Assuming all requests have arrived before accessing commences and that no more requests
arrive during processing, compute the average track distance (i.e. number of tracks) the head
moves per request, using

i) fist in, first out (FIFO);


(3 Marks)
ii) scan (in increasing track number);
(3 Marks)
iii) circular scan (in increasing track number).
(3 Marks)

G53OPS-E1 End

You might also like