Operating System Final Semester Mock Paper for MCA Students



Operating System
Final Mock Test Semester Examination

Time: 3 Hours                                    Total Marks: 100

Note:               (1) Attempt ALL questions
                        (2) All questions carry equal marks.
           
1. Attempt any four of the following questions:  (5 x 4 = 20)

(a)    What is an operating system? What are the main functions of an operating system? Write in detail.
(b)   What is the difference between multiprogramming and multitasking? What are the main advantages of multiprogramming?
(c)    Define and explain the need of System Protection. Give two examples.
(d)   Differentiate between Concurrent processing, Parallel processing and Serial processing. Explain with Figures.
(e)    What are the advantages and disadvantages of the layered approach to system design

2. Attempt any four parts of the following:   (5 x 4 = 20)

(a)    Explain the operation of multilevel scheduling. What advantages is there in having different quantum size on different levels of a multilevel queuing system.

(a)    Describe the differences between short term, medium term and long term scheduling.
(b)   A CPU scheduling algorithm determines an order for the execution of its scheduled jobs. Given jobs to be scheduled on one processor, how many possible different schedules are there? What are the performance criteria used to evaluate CPU scheduling algorithm?
(c)    What is a thread? How thread is different from a process? What resources are used when a thread is created?
(d)    Define a critical section problem and its solution by using Semaphore. Use this approach to solve producer/consumer problem.

3. Attempt any two of the following:             (10 x 2 = 20)

(a)                Consider the Shortest Remaining Job First (SRJF)             
      algorithm.
Process id
Arrival time
Execution time
A
B
C
D
E
0
1
2
6
12
7
5
3
2
3

If there is tie within the processes, the tie is broken in the favor of the oldest process.

(i) Draw the Gantt chart and find the average waiting time and turnaround time for the algorithm.
 
(ii) If the scheduler takes 0.2 unit of CPU time in context switching for the completed job and 0.1 unit of additional CPU time for incomplete jobs for saving their context, calculate the percentage of CPU time wasted.
(b) Explain the difference between deadlock and starvation.
 Differentiate between deadlock prevention, deadlock   
 avoidance and deadlock detection techniques.
  (c) Consider a system consisting of four resources of the same type that are shared by three processes, each of which needs at most two resources. Show that the system is deadlock-free.


4. Attempt any two of the following questions: (10 x 2 = 20)

(a)    How many page-faults would occur for the following reference string, for four page frames using Optimal algorithm: 1, 2, 3, 4, 5, 5, 3, 4, 1, 6, 7, 8, 7, 8, 9, 7, 8, 9, 5, 4, 5, 4, 2 
(b)   Describe a mechanism by which one segment could belong to the address space of two different processes.
(c)       Prove that Peterson’s solution (programming solution without using any synchronization tools) satisfies all requirements of the critical-section problem designed for two processes.


5. Attempt any two of the following questions: (10 x 2 = 20)

(a)    Consider a paging system with the page table in memory.
(i)           If a memory reference takes 1.4 micro second how long does a paged memory reference take?
(ii)         If we add 8 associative registers and 75% of all page table reference are found in the associative registers. What is the effective memory reference time? (Assume that finding a page table entry in the associative registers takes zero time if it is there).

    (b) Explain how monitors (including condition variables) are implemented using semaphores.

     (c) Explain any two of the followings:
(i)                 Process state transition diagram
(ii)               Inter process communication
(iii)              Dispatch Latency
(iv)              Virtual Machine