GITAM School of Technology
(Estd. u/s 3 of the UGC Act, 1956)
Accredited by NAAC with ‘A+’ Grade
Department of Computer Science and Engineering
OS Question Bank
Year: 2nd Year
Module 1
Chapter-1:-
1. What is an operating systems? Explain the goals of an operating system.
2. Explain the role of operating system with user and system viewpoints.
3. List & explain the different types of operating system with its properties, advantages and
disadvantages.
4. Enumerate the concept of multitasking. Explain the special programs used to generate a
system.
5. Give brief description on distributed system and real time embedded systems.
6. What is multitasking system? Explain the concept & also mention its advantages.
7. Explain multiprocessor system with neat diagram. And also mention its advantages.
8. Discuss the difference between time-sharing systems and multi-programming systems.
9. Describe the differences between symmetric and asymmetric multiprocessing. What are
three advantages and one disadvantage of multiprocessor systems?
Chapter-2:-
1. Discuss in details about the functions provided by the operating system.
2. What are operating system services? Explain any 5 of them.
3. Describe three general methods for passing parameters to the operating system.
4. What is process management with respect to system calls? Explain.
5. What is system call? Explain how system calls are used with diagram.
6. What are system programs? Explain any 5.
7. Explain monolithic, layered and micro kernel structures of operating system design with
case studies.
8. In what ways is the modular kernel approach similar to the layered approach? In what ways
does it differ from the layered approach?
MODULE -2
Chapter-1:-
1. With a diagram, explain the different states of a process.
2. Explain processs control block with a neat diagram.
3. What is dispatcher?Explain
4. What are the three levels of scheduling? Explain
5. What is context switching?
6. What is medium-term scheduler explain.
7. Describe the differences among short-term, medium-term, and long-term scheduling
8. Including the initial parent process, how many processes are created by the program shown
in figure below?
#include<stdio.h>
#include<unistd.h>
intmain()
{ I* fork a child process *I
fork();
I* fork another child process *I
fork();
I* and fork another *I
fork();
return 0;
}
9. Using the program in below, identify the values of pid at lines A, B, C, and D. (Assume that
the actual pids of the parent and child are 2600 and 2603, respectively.)
#include<stdio.h>
#include<unistd.h>
#include<sys/types.h>
intmain()
{
pid_tpid' pid1;
I* fork a child process *I
pid = fork();
if (pid< 0)
{
I* error occurred *I
fprintf(stderr, "Fork Failed");
return 1;
}
else if (pid == 0)
{ I* child process *I
pid1 = getpid();
printf("child: pid = %d",pid); I* A *I
printf("child: pid1 = %d",pid1); I* B *I
}
else
{ I* parent process *I
pid1 = getpid() ;
printf("parent: pid = %d",pid); I* C *I
printf("parent: pid1 = %d" ,pid1); I* D *I
wait(NULL);
}
return 0;
}
10. Using the following program, explain what the output will be at Line A.
#include<stdio.h>
#include<unistd.h>
#include<sys/types.h>
int value = 5;
intmain()
{
pid_tpid;
pid = fork();
if (pid == 0)
{
I* child process *I
value += 15;
return 0;
}
else if (pid> 0)
{ I* parent process *I
wait(NULL);
printf("PARENT: value= %d",value); I* LINE A *I
return 0;
}
return 0;
}
Chapter-2:-
1. Explain CPU scheduling criteria.
2. List & Explain the two scheduling algorithm with an example.
3. Explain RR scheduling algorithm with an example.
4. What is SJF Scheduling? Explain with an example and Gantt chart.
5. Write short notes on:
i) Multi-level queue scheduling (MLQ)
ii) Multi-level feedback queue scheduling.
6. Explain the different criteria of evaluating an algorithm.
7. What is deterministic modeling with reference to algorithm evaluation/ Explain
8. Explain any 2 method of algorithm evaluation.
9. Consider the following process &CPU burst given in following table
Table:
Process arrival time priority Burst time
p1 3 3 5
p2 1 1 2
p3 2 3 10
p4 1 4 6
p5 5 2 1
a. Draw Gant chart for FCFS, SJF, priority & round robin (with time quantum
1millisecond)
b. Calculate turnaround time of all the scheduling algorithms
c. Calculate waiting time of each process for all scheduling algorithm
d. Calculate minimum average waiting among four scheduling algorithms.
10. What is InterProcess Communication? Explain two fundamental models of InterProcess
Communication.
11. What are threads? Explain its different types.
12. Difference between Single-threaded and multi-threaaded process.
13. What are the benefits of multithreaded programming.
14. what are the difference between the process and thread
MODULE -3
Chapter-1:-
1. Explain critical section problem.
2. Explain Peterson’s solution to Critical Section Problem.
3. What are the requirements of critical section problem? Explain.
4. Describe implementation of synchronization hardware using i) swap( ) ii) Test and set
instruction.
5. Write short notes on monitors and semaphores.
6. What are Race condition? Explain the use of semaphores to achieve synchronization in
producer-consumer problem.
7. What are monitors? Explain the structure of a monitor and using the dining philosophers
problem explain how mutual exclusion can be achieved?
8. Write a program for producer and consumer using semaphores.
9. Describe the mutual-exclusion implementation with TestAndSet( ).
10. Discuss the solution to Dining-philosophers problem using montors.
11. Explain the structure and function of a monitors.
12. Write a program for readers-writers problem.
13. Explain in details classical problems of process synchronization with its solution.
Chapter-:-
1. What is deadlock? Explain with an example.
2. Explain the necessary conditions for deadlock situation
3. Explain deadlock characterization and wait-for a graph in detail.
4. What are the different methods used for handling deadlocks? Explain
5. Briefly explain deadlock prevention mechanisms.
6. Explain deadlock avoidance with suitable example.
7. Explain Banker’s algorithm .
8. Write and explain safety algorithm detail.
9. Write algorithm for resource request.
10. When do you run a deadlock detection algorithm? Explain with an example.
11. Explain deadlock detection algorithm for single instance resource type & multiple instance
resource type.
12. Briefly explain deadlock avoidance.
13. Explain the resource allocation graph with an example.
14. Explain the usage of resource pre-emption in deadlock recovery.
15. Explain deadlock recovery in detail.
16. Consider the following snapshot of a system
Process Allocation Max Available
A B C A B C A B C
P0 0 1 0 7 5 3 3 3 2
P1 2 0 0 3 2 2
P2 3 0 2 9 0 2
P3 2 1 1 2 2 2
P4 0 0 2 4 3 3
Answer the following questions using banker’s algorithm
i) What is the content of the matrix need?
ii) Is the system in a safe state?
iii) If a request from process P1 arrives for (1,0,2) can the request be granted immediately?
MODULE -4
Chapter-1:-
1. Explain the concept of swapping with neat diagram. Why it is required?
2. Explain the terms: a) Logical memory b) Physical memory
3. Explain the terms first fit, best fit, and worst fit.
4. Given memory partitions of 100k, 500k, 200k, 300k, and 600k ( in order) how would each
of the first fit, best fit, & worst fit algorithms place processes of 212k, 417k, 112k and
426k( in order)? Which algorithm makes the most efficient use of memory.
5. Explain the contiguous memory allocation.
6. What is fragmentation? Explain the different types of fragmentation.
7. Explain why fragmentation does not occur in a paged system.
8. Define paging. Explain the concept of paging hardware with neat diagram.
9. Define Segmentation. Explain the concept of segmentation hardware with neat diagram.
10. Differentiate between paging & Segmentation.
11. What are the advantages & Disadvantages of Paging?
12. Differentiate between external & internal fragmentation.
13. What are Translation load aside buffer (TLB)? Explain TLB in details with a simple paging
system with a neat diagram.
14. Explain segmentation with paging.
15. Why are segmentation and paging sometimes combined into one scheme?
16. What is the purpose of paging the page table?
Chapter-2:-
1. Explain the concept of virtual memory.
2. What is Demand paging? Explain
3. Describe the hardware & software support for demand paging.
4. Explain the use of valid –invalid bit in page table.
5. Explain the performance of demand paging.
6. Explain page replacement with a block diagram.
7. Define page fault. Explain the procedure of handling page fault with a block diagram.
8. Explain FIFO page replacement algorithm with a example.
9. What is Belady’s anomaly? Explain.
10. Explain LRU & Optimal page replacement algorithm with an example.
11. What do you mean by allocation of frames? Explain.
12. What is working set model? Explain.
13. Define thrashing.
14. How do you measure the performance of demand paging.
15. Consider the following page reference string
1, 2, ,5, 2, 3, 5, 7, 1, 2, 3, 8, 6, 4, 3, 2, 2, 3, 6.
Assuming there are 3 memory frames, how many page faults would occur in the case of
i) LRU ii) Optimal Algorithm
Note that initially all frames are empty.
16. Consider the following segment table:
Segment Base Length
219 600
2300
100
1327 580
1952
What are the physical addresses of the following logical address?
i) 0430 ii) 110 iii) 2500 iv) 3400 v) 4112
17. Write a program to implements FIFO,LRU & Optimal page replacement algorithm.
Chapter-3:-
1. What is a file? List & explain the various file attributes.
2. Briefly explain file operations.
3. Explain the different types of files.
4. Discuss the various file access methods.
5. What is a directory? What are its different structures?
6. Explain single level directory structure with neat diagram.
7. Describe two-level directory structure with neat diagram.
8. Briefly explain Tree-structured and Acyclic-graph directories with neat diagram.
9. What is the difference between absolute path name & relative path name?
MODULE -5
Chapter-1:-
1. Briefly explain I/O Hardware.
2. Explain the terms: a) Polling b) Interrupt c) Buffering d) Caching
e) Spooling & Device Reservation f) Error Handling g) I/O Protection
3. List some of the features of interrupt-handling.
4. Explain how the I/O – related portions of the kernel are structured in software layers with
the help of neat diagram.
5. Briefly explain Blocking & Non-Blocking I/O.
6. Explain Kernel Data Structures with neat diagram.
7. Explain the life cycle of an I/O request with neat diagram.
Chapter-2:-
1. Briefly explain Disk Structure.
2. Define seek time & rotational latency time.
3. Write a short note on disk scheduling algorithm.
4. Explain any two disk scheduling algorithm.
5. Explain SCAN and C-SCAN disk scheduling.
6. The head of a moving head disk with 200 tracks, numbered 0 to 199 is currently serving a
request at track 143 and has just finished a request at track 125. The queue of request in
FIFO order is 86,147,91,177,94,150, 102,175,130. What is the total number of head
movements to satisfy these requests for the following disk scheduling algorithm.
i) FCFS ii) SSTF iii) SCAN iv) C-SCAN
7. Suppose that a disk drive has 100 cylinders, numbered 0 to 99. The drive is currently
serving a request at cylinder 26. The queue of pending requests are 37, 100, 14, 88, 33, 99,
12. Draw the graph for the following disk scheduling algorithms:
a. FCFS b. SSTF c. SCAN d. C-SCAN d. LOOK e. C-LOOK
Chapter-3:
1. Explain the goals of protection.
2. Describe access matrix in detail.
3. Briefly explain protection & security.
4. Briefly explain domain of protection.
5. State three advantages and disadvantages of placing functionality in a device controller,
rather than in the kernel.
6. Explain the concept of access matrix, with various access rights.
7. Differentiate the access right between read and read*.
Chapter-4:
1. Explain in detail the file system in LINUX system.
2. Explain in detail the memory management in LINUX system
3. Explain about Linux’s Completely-Fair scheduler in detail.
4. Explain in detail the design principles, kernel modules, process management, scheduling in
LINUX system.