Operating Systems – Full Question Bank (Ch1–Ch4)
Chapter 1 – Introduction
1. 1. What is an operating system?
Answer: A program that acts as an intermediary between the user and the computer
hardware.
2. 2. What are the goals of an operating system?
Answer: Execute user programs, make computing convenient, and use hardware
efficiently.
3. 3. What are the four components of a computer system?
Answer: Hardware, Operating System, Application Programs, Users.
4. 4. What does the bootstrap program do?
Answer: Loads the OS kernel during startup.
5. 5. What are the four components of a computer system?
Answer: CPU, memory, I/O devices, and users.
6. 6. What is the function of the OS in a computer system?
Answer: Manages hardware and provides services to applications.
7. 7. What are the major OS design goals for different systems?
Answer: Convenience and performance for PCs, efficiency for servers, usability for
mobile devices.
8. 8. What are the roles of an OS?
Answer: Resource allocator and control program.
9. 9. What is the kernel?
Answer: The one program that always runs; the core of the OS.
10. 10. What are system programs?
Answer: Programs that come with the OS but are not part of the kernel.
11. 11. What is the function of the device controller?
Answer: Manages I/O operations and informs the CPU via interrupts.
12. 12. What is a trap?
Answer: A software-generated interrupt from errors or user requests.
13. 13. What is DMA?
Answer: Direct Memory Access – a method for fast data transfer to/from memory
without CPU.
14. 14. Define bit, byte, word.
Answer: Bit: smallest unit, Byte: 8 bits, Word: native unit of data for architecture.
15. 15. What is the storage hierarchy?
Answer: Registers → Cache → Main Memory → SSD/HDD → Optical/Tape.
16. 16. What is caching?
Answer: Storing frequently accessed data in faster storage.
17. 17. What is multiprogramming?
Answer: Organizing jobs so the CPU always has one to execute.
18. 18. What is time-sharing?
Answer: CPU switches jobs so users can interact with programs in real time.
19. 19. What are interrupts?
Answer: Signals sent to the CPU to gain attention for I/O or errors.
20. 20. What are dual-mode operations?
Answer: User mode vs. Kernel mode separation for protection.
Chapter 2 – OS Structures
21. 21. What are the five services provided by an OS to users?
Answer: Program execution, I/O operations, file-system manipulation, communication,
and error detection.
22. 22. What are the three OS services for system efficiency?
Answer: Resource allocation, accounting, protection & security.
23. 23. What is CLI?
Answer: Command-Line Interface allowing typed commands.
24. 24. What is GUI?
Answer: Graphical interface using icons and windows.
25. 25. What is a system call?
Answer: A programmatic way for processes to request services from the OS.
26. 26. What are common APIs?
Answer: Win32 API, POSIX API, Java API.
27. 27. What are the three parameter passing methods?
Answer: Registers, memory block, stack.
28. 28. What are system call categories?
Answer: Process control, file management, device management, info maintenance,
communication, protection.
29. 29. What are system programs?
Answer: Utilities that help with file manipulation, status info, text editing, etc.
30. 30. What is the purpose of OS design?
Answer: To define goals, structure the system, and choose implementation methods.
Chapter 3 – Processes
31. 31. What is a process?
Answer: A program in execution with its own resources and state.
32. 32. What are the five process states?
Answer: New, Running, Waiting, Ready, Terminated.
33. 33. What is a Process Control Block (PCB)?
Answer: A data structure that stores all information about a process.
34. 34. What is a context switch?
Answer: The act of saving and loading process state when switching between
processes.
35. 35. What are schedulers?
Answer: Short-term (CPU), Long-term (job), Medium-term (swapping).
36. 36. What is process creation?
Answer: Parent processes create children using system calls like fork().
37. 37. What is process termination?
Answer: When a process finishes or is terminated by its parent.
38. 38. What is a zombie process?
Answer: Terminated process not yet reaped by its parent.
39. 39. What is interprocess communication (IPC)?
Answer: Processes exchanging data through shared memory or message passing.
40. 40. What is the producer-consumer problem?
Answer: A classic IPC example where one process produces data and the other
consumes it.
Chapter 4 – Threads
41. 41. What is a thread?
Answer: The smallest unit of processing scheduled by an OS.
42. 42. What are the benefits of multithreading?
Answer: Responsiveness, resource sharing, economy, scalability.
43. 43. What are user threads vs kernel threads?
Answer: User threads are managed by libraries, kernel threads by the OS.
44. 44. What are the multithreading models?
Answer: Many-to-One, One-to-One, Many-to-Many, Two-level.
45. 45. What is a thread library?
Answer: A library that provides an API for creating and managing threads.
46. 46. What is Pthreads?
Answer: POSIX standard for thread creation and synchronization.
47. 47. How are threads created in Java?
Answer: By extending Thread class or implementing Runnable.
48. 48. What is the GIL in Python?
Answer: Global Interpreter Lock that restricts true multithreading.
49. 49. What is implicit threading?
Answer: Thread creation and management by libraries rather than the programmer.
50. 50. What is Amdahl’s Law?
Answer: It defines the speedup limit of a system based on parallelizable components.