0% found this document useful (0 votes)
17 views11 pages

Operating System MCQs Overview

Uploaded by

noakhali
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
17 views11 pages

Operating System MCQs Overview

Uploaded by

noakhali
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

1. What is operating system?

a) collection of programs that manages hardware resources


b) system service provider to the application programs
c) link to interface the hardware and application programs
d) all of the mentioned

Answer: b) system service provider to the application programs

2. To access the services of operating system, the interface is provided by the ___________
a) System calls
b) API
c) Library
d) Assembly instructions

Answer: a) System calls

3. Which one of the following is not true?


a) kernel is the program that constitutes the central core of the operating system
b) kernel is the first part of operating system to load into memory during booting
c) kernel is made of various modules which can not be loaded in running operating system
d) kernel remains in the memory during the entire computer session

Answer: c) kernel is made of various modules which can not be loaded in running operating system

4. By operating system, the resource management can be done via __________


a) time division multiplexing
b) space division multiplexing
c) time and space division multiplexing
d) none of the mentioned

Answer: c) time and space division multiplexing

5. If a process fails, most operating system write the error information to a ______
a) log file
b) another running process
c) new file
d) none of the mentioned

Answer: a) log file

6. Which one of the following is not a real time operating system?


a) VxWorks
b) Windows CE
c) RTLinux
d) Palm OS

Answer: d) Palm OS
7. In Unix, Which system call creates the new process?
a) fork
b) create
c) new
d) none of the mentioned

Answer: a) fork

8. What is the ready state of a process?


a) when process is scheduled to run after some execution
b) when process is unable to run until some task has been completed
c) when process is using the CPU
d) none of the mentioned

Answer: a) when process is scheduled to run after some execution

9. What is interprocess communication?


a) communication within the process
b) communication between two process
c) communication between two threads of same process
d) none of the mentioned

Answer: b

10. Which system call returns the process identifier of a terminated child?
a) wait
b) exit
c) fork
d) get

Answer: a

11. The address of the next instruction to be executed by the current process is provided by the
__________
a) CPU registers
b) Program counter
c) Process stack
d) Pipe

Answer: b

12. The number of processes completed per unit time is known as __________
a) Output
b) Throughput
c) Efficiency
d) Capacity

Answer: b
13. Which of the following is not the state of a process?
a) New
b) Old
c) Waiting
d) Running

Answer: b

14. What is a Process Control Block?


a) Process type variable
b) Data Structure
c) A secondary storage section
d) A Block in memory

Answer: b

15. What is the degree of multiprogramming?


a) the number of processes executed per unit time
b) the number of processes in the ready queue
c) the number of processes in the I/O queue
d) the number of processes in memory
View Answer

Answer: d
Explanation: None.

16. What will happen when a process terminates?


a) It is removed from all queues
b) It is removed from all, but the job queue
c) Its process control block is de-allocated
d) Its process control block is never de-allocated
View Answer

Answer: a
Explanation: None.

17. What is a long-term scheduler?


a) It selects which process has to be brought into the ready queue
b) It selects which process has to be executed next and allocates CPU
c) It selects which process to remove from memory by swapping
d) None of the mentioned
View Answer

Answer: a
Explanation: None.
18. What is a medium-term scheduler?
a) It selects which process has to be brought into the ready queue
b) It selects which process has to be executed next and allocates CPU
c) It selects which process to remove from memory by swapping
d) None of the mentioned
View Answer

Answer: c
Explanation: None.

19. What is a short-term scheduler?


a) It selects which process has to be brought into the ready queue
b) It selects which process has to be executed next and allocates CPU
c) It selects which process to remove from memory by swapping
d) None of the mentioned
View Answer

Answer: b

20. The primary distinction between the short term scheduler and the long term scheduler is
__________
a) The length of their queues
b) The type of processes they schedule
c) The frequency of their execution
d) None of the mentioned
View Answer

Answer: c

21. In a time-sharing operating system, when the time slot given to a process is completed, the process
goes from the running state to the __________
a) Blocked state
b) Ready state
c) Suspended state
d) Terminated state
View Answer

Answer: b

22. If a process is executing in its critical section, then no other processes can be executing in their
critical section. This condition is called?
a) mutual exclusion
b) critical exclusion
c) synchronous exclusion
d) asynchronous exclusion
View Answer
Answer: a
Explanation: None.

23. Which one of the following is a synchronization tool?


a) thread
b) pipe
c) semaphore
d) socket
View Answer

Answer: c

24. A semaphore is a shared integer variable __________


a) that can not drop below zero
b) that can not be more than zero
c) that can not drop below one
d) that can not be more than one
View Answer

Answer: a
Explanation: None.

25. In UNIX, each process is identified by its __________


a) Process Control Block
b) Device Queue
c) Process Identifier
d) None of the mentioned
View Answer

Answer: c

26. Remote Procedure Calls are used ____________


a) for communication between two processes remotely different from each other on the same system
b) for communication between two processes on the same system
c) for communication between two processes on separate systems
d) none of the mentioned
View Answer

Answer: c

27. What is stub?


a) transmits the message to the server where the server side stub receives the message and invokes
procedure on the server side
b) packs the parameters into a form transmittable over the network
c) locates the port on the server
d) all of the mentioned
View Answer

Answer: d
28. The initial program that is run when the computer is powered up is called __________
a) boot program
b) bootloader
c) initializer
d) bootstrap program
View Answer

Answer: d

29. How does the software trigger an interrupt?


a) Sending signals to CPU through bus
b) Executing a special operation called system call
c) Executing a special program called system program
d) Executing a special program called interrupt trigger program
View Answer

Answer: b

30. What is an interrupt vector?


a) It is an address that is indexed to an interrupt handler
b) It is a unique device number that is indexed by an address
c) It is a unique identity given to an interrupt
d) None of the mentioned
View Answer

Answer: a

31. Which module gives control of the CPU to the process selected by the short-term scheduler?
a) dispatcher
b) interrupt
c) scheduler
d) none of the mentioned
View Answer

Answer: a

32. The processes that are residing in main memory and are ready and waiting to execute are kept on a
list called _____________
a) job queue
b) ready queue
c) execution queue
d) process queue
View Answer

Answer: b

33. The interval from the time of submission of a process to the time of completion is termed as
____________
a) waiting time
b) turnaround time
c) response time
d) throughput
View Answer

Answer: b

34. In priority scheduling algorithm, when a process arrives at the ready queue, its priority is compared
with the priority of ____________
a) all process
b) currently running process
c) parent process
d) init process
View Answer

Answer: b
Explanation: None.

35. Which algorithm is defined in Time quantum?


a) shortest job scheduling algorithm
b) round robin scheduling algorithm
c) priority scheduling algorithm
d) multilevel queue scheduling algorithm
View Answer

Answer: b

36. Process are classified into different groups in ____________


a) shortest job scheduling algorithm
b) round robin scheduling algorithm
c) priority scheduling algorithm
d) multilevel queue scheduling algorithm
View Answer

Answer: d

37. In multilevel feedback scheduling algorithm ____________


a) a process can move to a different classified ready queue
b) classification of ready queue is permanent
c) processes are not classified into groups
d) none of the mentioned
View Answer

Answer: a

38. Which one of the following can not be scheduled by the kernel?
a) kernel level thread
b) user level thread
c) process
d) none of the mentioned
View Answer

Answer: b

39. What is Dispatch latency?


a) the speed of dispatching a process from running to the ready state
b) the time of dispatching a process from running to ready state and keeping the CPU idle
c) the time to stop one process and start running another one
d) none of the mentioned
View Answer

Answer: c

40. What is Turnaround time?


a) the total waiting time for a process to finish execution
b) the total time spent in the ready queue
c) the total time spent in the running queue
d) the total time from the completion till the submission of a process
View Answer

Answer: d

41. Round robin scheduling falls under the category of ____________


a) Non-preemptive scheduling
b) Preemptive scheduling
c) All of the mentioned
d) None of the mentioned
View Answer

Answer: b

42. With round robin scheduling algorithm in a time shared system ____________
a) using very large time slices converts it into First come First served scheduling algorithm
b) using very small time slices converts it into First come First served scheduling algorithm
c) using extremely small time slices increases performance
d) using very small time slices converts it into Shortest Job First algorithm
View Answer

Answer: a

43. Which is the most optimal scheduling algorithm?


a) FCFS – First come First served
b) SJF – Shortest Job First
c) RR – Round Robin
d) None of the mentioned
View Answer
Answer: b
Explanation: None.

44. The real difficulty with SJF in short term scheduling is ____________
a) it is too good an algorithm
b) knowing the length of the next CPU request
c) it is too complex to understand
d) none of the mentioned
View Answer

Answer: b

45. Which one of the following is the deadlock avoidance algorithm?


a) banker’s algorithm
b) round-robin algorithm
c) elevator algorithm
d) karn’s algorithm
View Answer

Answer: a

46. A problem encountered in multitasking when a process is perpetually denied necessary resources is
called ____________
a) deadlock
b) starvation
c) inversion
d) aging
View Answer

Answer: b

47. To avoid deadlock ____________


a) there must be a fixed number of resources to allocate
b) resource allocation must be done only once
c) all deadlocked processes must be aborted
d) inversion technique can be used
View Answer

Answer: a

48. Semaphore is a/an _______ to solve the critical section problem.


a) hardware for a system
b) special program for a system
c) integer variable
d) none of the mentioned
View Answer

Answer: c
49. A deadlock can be broken by ____________
a) abort one or more processes to break the circular wait
b) abort all the process in the system
c) preempt all resources from all processes
d) none of the mentioned
View Answer

Answer: a
Explanation: None.

50. If we preempt a resource from a process, the process cannot continue with its normal execution and
it must be ____________
a) aborted
b) rolled back
c) terminated
d) queued
View Answer

Answer: b

51. What is the solution to starvation?


a) the number of rollbacks must be included in the cost factor
b) the number of resources must be included in resource preemption
c) resource preemption be done instead
d) all of the mentioned
View Answer

Answer: a
Explanation: None.

52. CPU fetches the instruction from memory according to the value of ____________
a) program counter
b) status register
c) instruction register
d) program status word
View Answer

Answer: a

53. Which one of the following is the address generated by CPU?


a) physical address
b) absolute address
c) logical address
d) none of the mentioned
View Answer

Answer: c
54. Program always deals with ____________
a) logical address
b) absolute address
c) physical address
d) relative address
View Answer

Answer: a

Common questions

Powered by AI

System calls provide the interface between a running program and the operating system, allowing user-level programs to request services of the kernel. These services include operations such as file manipulation, process control, communication, and more. Through system calls, a user-mode program can request the kernel to perform privileged operations that the program itself is not permitted to execute directly. This separation maintains the security and stability of the system by preventing unauthorized access to hardware resources and sensitive data .

In UNIX systems, each process is assigned a unique Process Identifier (PID) which distinguishes it from all other processes running in the system. PIDs are critical for process management as they allow the kernel and other processes to reference a specific process. They are used in system calls that manage processes and are integral to tasks such as process termination, status checking, and signal sending. The use of PIDs ensures accurate process control and communication, which is fundamental for stable and secure system operation .

Logical addresses are used by programs as references to memory locations during execution. They are generated by the CPU and are used by programs to access their memory. These logical addresses are translated to physical addresses by the memory management unit within the system, through a process known as address binding. Logical addresses facilitate dynamic relocation and memory protection by abstracting the memory management process from the application, enabling secured and flexible memory operations .

Deadlock in operating systems is a situation where a set of processes are blocked because each process is waiting for a resource that is held by another process. It results in a standoff where no progress can be made. Deadlock can be avoided by ensuring that at least one of the necessary conditions for deadlock does not hold. These conditions include mutual exclusion, hold and wait, no preemption, and circular wait. By implementing techniques like resource allocation ordering, acquiring all resources at once, or enabling preemption, the risk of deadlock can be mitigated .

A semaphore is a synchronization tool used to manage concurrent processes by using a simple integer value to signal process status. Semaphores are used to solve problems such as mutual exclusion and to prevent race conditions. An integer variable in a semaphore can be adjusted through operations like "wait" and "signal" to control access to resources. Despite its effectiveness, semaphores can be complex to implement and may lead to problems such as deadlocks or priority inversion if not carefully managed, as tasks may end up waiting indefinitely .

Mutual exclusion is a principle in process synchronization that ensures that multiple processes or threads do not enter their critical sections simultaneously. A critical section is a part of the program that accesses shared resources, like data structures or devices. Ensuring mutual exclusion prevents race conditions where the output or final state of the operation depends on the sequence of processes execution. It is vital because it guarantees data consistency and integrity, avoiding possible conflicts and errors caused by concurrent access to shared resources .

The round-robin scheduling algorithm ensures fairness by assigning each process an equal fixed time slot, known as a quantum, within which it can execute. If a process does not complete during its time slot, it is placed at the back of the ready queue, allowing the next process to execute. This algorithm is particularly effective in time-sharing systems to ensure no task monopolizes the CPU time. However, its limitations include increased overhead from frequent context switching and inefficiency with processes of widely varying lengths, as all processes receive equal time regardless of their needs .

The long-term scheduler, or job scheduler, determines which processes are admitted to the system for processing. It selects processes from the pool and loads them into memory for execution. The medium-term scheduler manages the degree of multiprogramming and is responsible for process swapping between main memory and disk storage to optimize the utilization of CPU. Finally, the short-term scheduler, or CPU scheduler, selects among the processes that are ready to execute and allocates the CPU to one of them. The major distinction between these schedulers lies in the frequency of their operation, with the short-term scheduler executing more frequently, thus playing a critical role in overall system performance .

The Shortest Job First (SJF) scheduling algorithm assigns the CPU to the process with the smallest execution time. This can minimize the average waiting time, making it optimal in that sense. However, one significant challenge is the need to know in advance the duration of each job, which is not always possible. This can lead to difficulties in implementation, particularly for jobs with unknown execution times. Additionally, SJF may lead to starvation of longer processes if many short processes continuously arrive .

The kernel is the core component of an operating system that manages operations of the computer and the hardware. It is responsible for tasks such as process management, memory management, device management, and system calls. The kernel remains in memory throughout the entire session while a computer is powered on and it is the first part of the OS to load, serving as the bridge between applications and hardware. It ensures that each process and application is allocated sufficient memory, hardware resources, and execution time to function correctly, thus contributing significantly to system functionality .

You might also like