Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
41 views

22CS304 – Operating Systems (Lab Integrated)

Uploaded by

jothishwar007
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
41 views

22CS304 – Operating Systems (Lab Integrated)

Uploaded by

jothishwar007
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Reg. No.

R.M.D. ENGINEERING COLLEGE


(An Autonomous Institution)
RSM Nagar, Kavaraipettai – 601 206
QP CODE: 235306
B.E. / B.TECH DEGREE END SEMESTER THEORY EXAMINATIONS – NOV/DEC 2023
Third Semester
Computer Science and Engineering / Information Technology /
Artificial Intelligence and Machine Learning
22CS304 – Operating Systems (Lab Integrated)
(Regulations 2022)
COs Course Outcome: After successful completion of the course, the students should be able to
CO1 Implement the basic concepts of operating system and process.
CO2 Analyse various CPU scheduling algorithms and thread mechanism.
CO3 Implement the concepts of process synchronization and deadlocks.
CO4 Design various memory management scheme to given situation.
CO5 Implement various I/O and file management techniques.
Time: 3 Hours Answer ALL Questions Max. Marks: 100
Part-A (10 x 2 = 20 Marks)

1. Illustrate the operating system services.


2. Compare the features of single processor and multiprocessor systems.
3. List the benefits of multithreaded programming.
4. What scheduling policy will you use for each of the following cases?
a. The processes arrive at large time intervals.
b. The system’s efficiency is measured by the percentage of jobs completed.
c. All the processes take almost equal amounts of time to complete.
d. Processes assigned with priority.
5. What are the necessary conditions of deadlock situation?
6. Demonstrate how mutex lock can be used to protect critical region.
7. Compare internal and external fragmentation.
8. Consider the scenario, if it takes 20 ns to search the TLB, 100ns to access memory and 100
ns to search the page table then find the effective access time for a 98% hit ratio.
9. Summarize the steps involved in DMA transfer.
10. Compare sequential and direct file access methods.
Part B (5 x 13 = 65 Marks)
11. a) i) Define Process. Explain the states of process and process control block. (7)
ii) Compare the two models of interprocess communication. (6)
(OR)
11. b) i) Explain the steps involved in process creation and termination. (7)
ii) Outline the purpose of system calls and summarize the types of system calls. (6)
12. a) i) Consider the following set of processes with burst time and priority. (13)
Process Burst time Priority
P1 2 2
P2 1 1
P3 8 4
P4 4 2
P5 5 3
The processes are assumed to have arrived in the order P1, P2, P3, P4, P5,
all at time 0.
a. Draw four Gantt charts that illustrate the execution of these processes
using the scheduling algorithms: FCFS, SJF, nonpreemptive priority
(a larger priority number implies a higher priority), and Round Robin
(quantum = 2).
b. Calculate the turnaround time and waiting time of each process for
each of the scheduling algorithms.
c. Which of the algorithms results in the minimum average waiting
time?
(OR)
12. b) i) Outline the types of multithreaded models. (7)
ii) Explain the various approaches to multiple-processor scheduling (6)

13. a) i) Outline the Dining philosopher problem and provide the solution for it using (7)
semaphore.
ii) Explain the methods used to recover system from deadlock. (6)
(OR)
13. b) i) Consider the following current state of a system. (13)
Allocation Max Available
ABCD ABCD ABCD
P0 0012 0012 1520
P1 1000 1750
P2 1344 2356
P3 0632 0652
P4 0014 0556
Answer the following questions using the banker’s algorithm:
a. What is the content of the matrix Need?
b. Is the system in a safe state?
c. If a request from process P1 arrives for (0,5,2,0), can the request be
granted immediately?

14. a) i) Demonstrate how the paging memory management scheme avoids external (7)
fragmentation.
ii) Given six memory partitions of 300 KB, 600 KB, 350 KB, 200 KB, 750 KB, (6)
and 125 KB (in order), how would the first-fit, best-fit, and worst-fit
algorithms place processes of size 115 KB, 500 KB, 358 KB, 200 KB, and
375 KB (in order)? Rank the algorithms in terms of how efficiently they use
memory.
(OR)
14. b) i) Consider the following page reference string: (13)
1, 2, 3, 4, 2, 1, 5, 6, 2, 1, 2, 3, 7, 6, 3, 2, 1, 2, 3, 6.
How many page faults would occur for the following replacement
algorithms, assuming four frames? Remember that all frames are initially
empty, so your first unique pages will cost one fault each.
a. LRU replacement
b. FIFO replacement
c. Optimal replacement

15. a) i) Summarize the various directory structures with diagram. (7)


ii) Explain any two the free space management approaches. (6)
(OR)
15. b) Explain the various disk allocation methods with illustration. (13)

Part C (1 x 15 = 15 Marks)
16. a) i) Analyze why interrupt and dispatch latency times must be bounded in a hard (8)
real-time system.
ii) How does the signal () operation associated with monitors differ from the (7)
corresponding operation defined for semaphores?
(OR)
16. b) i) Suppose that a disk drive has 5,000 cylinders, numbered 0 to 4,999. The (8)
drive is currently serving a request at cylinder 2,150, and the previous
request was at cylinder 1,805. The queue of pending requests, in FIFO order,
is: 2,069, 1,212, 2,296, 2,800, 544, 1,618, 356, 1,523, 4,965, 3681. Starting
from the current head position, what is the total distance (in cylinders) that
the disk arm moves to satisfy all the pending requests for each of the
following disk-scheduling algorithms?
a. FCFS
b. SSTF
c. SCAN
d. LOOK
ii) Illustrate how the page faults are handled in demand paging technique. (7)



You might also like