Upload
john-jo
View
206
Download
0
Embed Size (px)
Citation preview
DCS5058 OPERATING SYSTEM 2013/2014
RMY/YHY/CMJ/KHW/NAN Page 1
REVISION QUESTION SEM 3, 2013/2014
1) Describe the differences between Symmetric Multiprocessing and Asymmetric
Multiprocessing. (6M)
2) List and explain TWO (2) problems of serial processing. (4M)
3) Draw and explain in detailed the TWO (2) I/O methods. (7M)
4) Describe the caching process in storage hierarchy. (2M)
5) With the aid of diagram, explain the THREE (3) measures used to organize the storage
system hierarchy. (4M)
6) Process Control Block (PCB) holds the information of all processes and keeps track
of all the processes. Briefly explain SEVEN (7) elements in a PCB. (7M)
7) List and explain THREE (3) benefits of microkernel organization. (6M)
8) Based on the table below, answer the following questions.
Process Burst Time (ms) Priority Arrival Time (ms)
P1 24 3 3
P2 8 2 0
P3 3 1 7
P4 7 4 6
i. Draw TWO (2) Gantt Charts illustrating the execution of processes using the following
scheduling algorithms:
a. First-Come First-Served (2 M)
b. Round Robin (Quantum = 3) (3 M)
ii. Calculate the waiting time of each process and average waiting time for all processes in
each of the scheduling algorithms. (6 M)
DCS5058 OPERATING SYSTEM 2013/2014
RMY/YHY/CMJ/KHW/NAN Page 2
9) Based on the table below, answer the following question.
Process Burst Time
(ms)
Priority Arrival Time
(ms)
P1 10 3 2
P2 13 1 0
P3 7 3 2
P4 17 4 4
P5 5 2 6
Draw the Gantt chart for each of the following scheduling algorithms. Calculate the waiting time
for each of the process as well as the average waiting time.
i. First-Come First-Served (5M)
ii. Non-preemptive Shortest-Job-First (5M)
iii. Preemptive Shortest-Job-First (5M)
iv. Non-preemptive Priority (5M)
v. Preemptive Priority (5M)
ivv. Round-Robin (Quantum = 3) (5M)
DCS5058 OPERATING SYSTEM 2013/2014
RMY/YHY/CMJ/KHW/NAN Page 3
10) Consider a system with four processes P1, P2, P3 and P4 and resource types scanner, printer
and magnetic disk having the following requirements and current allocations for these resources:
Scanner Printer Magnetic Disk
Max Allocation Max Allocation Max Allocation
P1 8 1 2 1 0 0
P2 6 1 1 0 1 0
P3 7 3 7 4 3 3
P4 4 2 5 3 6 3
Available
Scanner Printer Disk
3 3 3
i. Given the available resources as shown above, calculate the total instances of resource
type scanner, printer and magnetic disk. (1.5 M)
ii. Determine the content of the matrix Need. (3 M)
iii. Determine if the above system is in a safe state. (4.5 M)
11) Given a heap of memory management scheme with the following free list where U: Used
and H: Hole:
U H U U H H U H U H U H H H
The following process requests will be received in order:
Process number Size in Kilobytes
1 55
2 20
3 15
4 47
5 30
1 Show how the memory requests above are allocated using each of the allocation schemes:
2
i. Worst Fit (WF) [5 M]
ii. Best Fit (BF) [5 M]
0K 30K 48K 60K 100K 120K 160K 200K 256K 310K 330K 400K 425K 460K 580K
DCS5058 OPERATING SYSTEM 2013/2014
RMY/YHY/CMJ/KHW/NAN Page 4
12) Given a heap of memory management scheme with the following free list:
U U H H U H U U H H U H U H H H
The following process requests will be received in order:
Process Number Size in Kilobytes
1 25
2 56
3 89
4 63
5 41
Show how the memory requests above are allocated using the following memory allocation
schemes.
i. Best Fit (BF) (3 M)
ii. First Fit (FF) (3 M)
13) Consider the following page reference string:
3,4,2,1,4,7,2,5,3,6,1,3,5,7
Assuming a paging scheme with FOUR (4) frames is initially empty. Trace the allocation
of pages to frames and find out page fault occur using the following page replacement
algorithms:
i. First in First Out (FIFO) [7.5 M]
ii. Optimal [7.5 M]
0 K 34K 60K 80K 119K 130K 166K 190K 215K 244K 286K 298K 340K 455K 638K 688K 808K
* U - Used
* H - Hole
DCS5058 OPERATING SYSTEM 2013/2014
RMY/YHY/CMJ/KHW/NAN Page 5
14) Consider the following page reference string:
a b, c, d, a, e, c, f, a, b, a, c, e, b, d
Assume that a paging scheme with FOUR (4) frames is initially empty. Trace the allocation
of pages to frames and determine page faults occur using the following page replacement
algorithms:
i. Least Recently Used (LRU) algorithm (5 M)
ii. First In First Out (FIFO) algorithm (5 M)
15) Explain how create operations works in file system. [2m]
16) List FOUR (4) disadvantages of single-level directory structure. [4m]