Test your Operating System skills with MCQs with answers and explanations. Covers CPU scheduling, synchronization, deadlocks, memory management, virtual memory, file systems, and OS internals.
This operating system quiz focuses on medium to advanced level concepts with carefully curated objective questions, correct answers, and clear explanations. Ideal for interviews and in-depth OS learning.
Practice Operating System MCQs with Detailed Explanations
Answer at least
12
questions to submit.
1.
Which CPU scheduling algorithm is optimal in terms of average waiting time but impractical to implement?
Medium
Correct answer:Shortest Job First
Shortest Job First minimizes average waiting time but requires exact knowledge of future CPU burst times.
2.
In preemptive priority scheduling, which issue can occur if priorities are not adjusted?
Medium
Correct answer:Starvation
Low-priority processes may never execute if higher-priority processes keep arriving.
3.
What is the main drawback of Round Robin scheduling with very small time quantum?
Medium
Correct answer:High context switching overhead
A very small time quantum increases the number of context switches, reducing CPU efficiency.
4.
Which condition is NOT required for a deadlock to occur?
Medium
Correct answer:Preemption
Deadlock requires no preemption, not preemption itself.
5.
Which technique allows the operating system to recover from deadlock?
Medium
Correct answer:Deadlock detection and recovery
Detection and recovery allow deadlocks to occur and then resolve them.
6.
Banker’s algorithm is primarily used for which purpose?
Medium
Correct answer:Deadlock avoidance
Banker’s algorithm avoids deadlock by ensuring the system remains in a safe state.
7.
Which page replacement algorithm can suffer from Belady’s anomaly?
Medium
Correct answer:FIFO
FIFO may increase page faults when more frames are added, known as Belady’s anomaly.
8.
Which page replacement algorithm approximates the optimal algorithm?
Medium
Correct answer:LRU
LRU replaces the page that has not been used for the longest time, approximating optimal behavior.
9.
Thrashing occurs when:
Medium
Correct answer:Processes spend more time paging than executing
Thrashing happens when excessive paging prevents useful execution.
10.
Which technique is used to reduce thrashing?
Medium
Correct answer:Working set model
The working set model limits the number of pages allocated to a process.
11.
Which memory management scheme eliminates external fragmentation?