Operating Systems 2074

Tribhuwan University
Institute of Science and Technology
2074
Bachelor Level / Fourth Semester / Science
Computer Science and Information Technology ( CSC259 )
( Operating Systems )
Full Marks: 60
Pass Marks: 24
Time: 3 hours
Candidates are required to give their answers in their own words as far as practicable.
The figures in the margin indicate full marks.

Section-A

Attempt any two questions:   (2x10=20)

1. Explain "race condition" and also state how process synchronization is handled using semaphore? Explain with algorithms.

10 marks view

                                            OR

Suppose three peoples are in line waiting for a department store to open for "the big sale". When the door opens, all three rush the door, but the door is not big enough for all them to pass through at once. Describe a solution for addressing this deadlock that will allow three peoples to pass through the door. Which of the 4 necessary deadlock conditions does your solution break? Explain

10 marks view

2.  Consider the following page reference string 1, 3, 5,4, 7, 1, 5, 6, 1, 2, 3, 7, 6, 3, 4, 1, 3, 8. How many page faults would occur for each of the following page replacement algorithms assuming 3 frames?

    a) FIFO

    b) OPR

    c) LRU

10 marks view

3. Consider following set of processes, with the length of the CPU-burst time and arrival time given in milliseconds.

        Process                Burst time                Arrival time

            P1                            10                                    0

            P2                            15                                    2

            P3                            22                                    3

            P4                            16                                    5

            P5                             5                                     6

For the given data, draw Gantt charts that illustrate the execution of these processes using SJF and Robin algorithms with quantum 4 milliseconds.

10 marks view

Section-B

Attempt any eight questions:   (8x5=20)

4.  Do you think a process can exist without any state? Justify your view with the help of process state transition diagram.

5 marks view

5.  Suppose that a disk drive has the cylinder numbered from 0 to 4999. The head is currently at cylinder number 143. The queue for services of cylinder is as 86, 1470, 913, 948, 1509,1774, 1022, 1750 and 130. What is the total head movement in each of the following disk algorithm to satisfy the requests?

    a) FCFS

    b) SSTF

5 marks view

6.  Define deadlock. How deadlock can be prevented?

5 marks view

7.  What is the advantage of interrupt over polling? Explain the working mechanism of interrupt controller.

5 marks view

8.  Are there any linkages between semaphore and deadlock condition? If yes, Explain with example.

5 marks view

9.  Describe the methods for implementing directories with examples.

5 marks view

10.  What is the difference between physical address and virtual address? Explain the conversion of virtual address into physical address by MMU.

5 marks view

11. Differentiate between time sharing and real time system.

5 marks view

12.  Explain about bit map and linked list memory management system.

5 marks view