OS Question Bank
OS Question Bank
compare at least three different methods of passing parameters to a system call, such as via
registers, stack, or memory. Discuss their advantages and limitations in different system
architectures.
2. Analyze the role of these functions in ensuring efficient operation of a computer system, and
discuss how they interact with each other.
3. Imagine you are working on the development of a multi-process application in an operating
system. The application has two processes: Process A needs to send a large amount of data to
Process B for further processing. Both processes must share this data efficiently and in real-time.
You are tasked with deciding which IPC mechanism would be most effective for this
communication—shared memory or pipes. Based on the given scenario, define Inter-Process
Communication (IPC) and explain why it is important for processes to communicate with each
other.
4. Imagine you are working on an operating system that runs several applications simultaneously.
One of the processes, Process X, is paused and needs to be resumed later. Why is the
information stored in the PCB important when switching between processes, especially in the
case of resuming Process X?
5. Imagine you are the developer of an operating system used in a real-time embedded system,
such as one found in an ATM machine. Provide a diagram to illustrate the process states and how
the ATM system’s processes might transition between these states during operation.
6. Analyze how these scheduling criteria influence the choice of scheduling algorithms. For
example, how does optimizing for response time differ from optimizing for throughput?
7. Discuss a real-world scenario where SMP would be preferred over AMP or vice versa. Justify your
choice based on system requirements, cost, and scalability.
8. Compare and contrast the Layered OS and Microkernel OS in terms of modularity, performance,
and complexity. Which structure would be more suitable for a real-time system, and why?
9. Write about three types of schedulers in OS. Which scheduler will decide the degree of
multiprogramming in a system? Justify your answer.
10.Provide examples of real-world applications for both Pre-emptive and Non-pre-emptive
scheduling. Explain why each method is suited to its respective application.
11.Why is context switching considered to be an overhead to the system?
12.w the long-term scheduler directly affects the system performance. Justify
13.A writer process like to send some bulk information to a reader process. Explain the IPC
mechanism that can be used for this purpose.
14.Analyse the role of these functions in ensuring efficient operation of a computer system, and
discuss how they interact with each other.
15.Five batch jobs A through E arrive at a computer system in the order A to Eat 12 almost the same
time. They have estimated running times of 6, 4, 1,3, and 7 seconds. Their (externally
determined) priorities are 3, 5, 2, l, and 4 respectively, with 5 being the highest priority. For each
of the following scheduling algorithms, determine the average process waiting time. Ignore
process switching overhead. (i) Round Robin (assume quantum :2 sec) (ii) First-come first-served
(iii) Shortest job first (iv) priority scheduling
16.Which type of operating system is best suited for applications like scientific experiments, medical
imaging systems, weapon systems, and robotics? Explain its key characteristics and why it is ideal
for these scenarios.
17.Compare and contrast monolithic and microkernel architectures. How does the interaction
between shell and kernel differ in these architectures?
18.Suppose a system uses strict priority scheduling where high-priority tasks continuously arrive.
Explain how a low-priority task might experience starvation and what is the solution
19.Consider a scenario where a user executes a command to list files (ls in Linux). Describe how
the shell and kernel interact to process this command.
20.The long-term scheduler controls the degree of multiprogramming. Justify your answer.
21.What challenges might arise if a user program tries to bypass system calls for direct hardware
access?
22.What challenges might arise if a user program tries to bypass system calls for direct hardware
access?
23.How can poorly designed system calls lead to vulnerabilities in a secure operating system?
Illustrate with a real-world example
24.Compare and contrast the layered approach and microkernel design in the context of
autonomous vehicle operating systems. Which structure would you choose and why?
Autonomous vehicles benefit from microkernel designs due to fault isolation and modularity.
However, for performance-critical operations, a layered approach with optimized inter-layer
communication might be more efficient. A hybrid design could balance reliability and speed.
25.What is a system call? How many child processes will be created for the following code? Justify
your answer.
void main()
{
fork();
fork();
fork();
fork();
printf("Hello\n");
fork();
printf("How is it going\n");
}
26.How many processes are created by the following program? What will be the order of output?
#include <stdio.h>
#include <unistd.h>
void main() {
fork();
sleep(2);
printf("Hello\n");
}
27.Write a program where the child process terminates with an exit status of 5 using the exit()
system call, and the parent process retrieves this status using wait().
28.Can you suggest a scenario where a simple structure might be more beneficial than a layered
approach?
29.A company wants to design an operating system for both mobile phones and servers. Explain
how a layered approach can help in achieving scalability across such varied hardware. Provide
examples of layers that might differ between the two systems.
30.Describe the differences among short-term, medium-term, and longterm scheduling.
33.Using the program in Figure 3.34, 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.)
+ Problems in CPU SCHEDULING