Os PDF
Os PDF
View Answer
Answer: d
Explanation: None.
2. To access the services of operating system, the interface is provided by the ___________
a) System calls
b) API
c) Library
d) Assembly instructions
View Answer
Answer: a
Explanation: None.
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
View Answer
Answer: c
Explanation: None.
4. Which one of the following error will be handle by the operating system?
a) power failure
View Answer
Answer: d
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: c
Explanation: None.
7. If a process fails, most operating system write the error information to a ______
a) log file
c) new file
View Answer
Answer: a
Explanation: None.
8. Which facility dynamically adds probes to a running system, both in user processes and in the
kernel?
a) DTrace
b) DLocate
c) DMap
d) DAdd
View Answer
Answer: a
Explanation: None.
a) VxWorks
b) Windows CE
c) RTLinux
d) Palm OS
View Answer
Answer: d
Explanation: None.
a) monolithic kernel
b) hybrid kernel
c) microkernel
View Answer
Answer: b
Explanation: None.
1. The systems which allow only one process execution at a time, are called __________
a) uniprogramming systems
b) uniprocessing systems
c) unitasking systems
View Answer
Answer: b
Explanation: Those systems which allows more than one process execution at a time, are called
multiprogramming systems. Uniprocessing means only one processor.
b) open files
View Answer
Answer: d
Explanation: None.
a) fork
b) create
c) new
View Answer
Answer: a
Explanation: None.
a) normal exit
b) fatal error
View Answer
Answer: d
Explanation: None.
b) when process is unable to run until some task has been completed
View Answer
Answer: a
Explanation: When process is unable to run until some task has been completed, the process is in
blocked state and if process is using the CPU, it is in running state.
View Answer
Answer: b
Explanation: None.
View Answer
Answer: a
Explanation: None.
a) Function parameters
b) Local variables
c) Return addresses
View Answer
Answer: d
Explanation: None.
a) wait
b) exit
c) fork
d) get
View Answer
Answer: a
Explanation: None.
10. 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
View Answer
Answer: b
Explanation: None.
1. A Process Control Block(PCB) does not contain which of the following?
a) Code
b) Stack
c) Bootstrap program
d) Data
View Answer
Answer: c
Explanation: None.
a) Output
b) Throughput
c) Efficiency
d) Capacity
View Answer
Answer: b
Explanation: None.
View Answer
Answer: d
Explanation: None.
a) New
b) Old
c) Waiting
d) Running
View Answer
Answer: b
Explanation: None.
b) Data Structure
d) A Block in memory
View Answer
Answer: b
Explanation: None.
a) Process Register
b) Program Counter
c) Process Table
d) Process Unit
View Answer
Answer: c
Explanation: None.
View Answer
Answer: d
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
a) Job Queue
b) PCB queue
c) Device Queue
d) Ready Queue
View Answer
Answer: b
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
5. If all processes I/O bound, the ready queue will almost always be ______ and the Short term
Scheduler will have a ______ to do.
a) full, little
b) full, lot
c) empty, little
d) empty, lot
View Answer
Answer: c
Explanation: None.
View Answer
Answer: c
Explanation: None.
View Answer
Answer: b
Explanation: None.
8. The primary distinction between the short term scheduler and the long term scheduler is
__________
View Answer
Answer: c
Explanation: None.
9. The only state transition that is initiated by the user process itself is __________
a) block
b) wakeup
c) dispatch
View Answer
Answer: a
Explanation: None.
10. 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
Explanation: None.
View Answer
Answer: c
Explanation: None.
12. Suppose that a process is in “Blocked” state waiting for some I/O service. When the service is
completed, it goes to the __________
a) Running state
b) Ready state
c) Suspended state
d) Terminated state
View Answer
Answer: b
Explanation: None.
13. The context of a process in the PCB of a process does not contain __________
c) memory-management information
View Answer
Answer: d
Explanation: None.
14. Which of the following need not necessarily be saved on a context switch between processes?
c) Program counter
View Answer
Answer: b
Explanation: None.
a) A device
b) Timer
c) Scheduler process
d) Power failure
View Answer
Answer: c
Explanation: None.
a) cooperating process
b) child process
c) parent process
d) init process
View Answer
Answer: a
Explanation: None.
2. When several processes access the same data concurrently and the outcome of the execution
depends on the particular order in which the access takes place, is called?
a) dynamic condition
b) race condition
c) essential condition
d) critical condition
View Answer
Answer: b
Explanation: None.
3. 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.
a) thread
b) pipe
c) semaphore
d) socket
View Answer
Answer: c
Explanation: None.
View Answer
Answer: a
Explanation: None.
a) mutex locks
b) binary semaphores
View Answer
Answer: c
7. When high priority task is indirectly preempted by medium priority task effectively inverting the
relative priority of the two tasks, the scenario is called __________
a) priority inversion
b) priority removal
c) priority exchange
d) priority modification
View Answer
Answer: a
Explanation: None.
a) hardware level
b) software level
View Answer
Answer: c
Explanation: None.
View Answer
Answer: d
Explanation: None.
View Answer
Answer: a
Explanation: None.
1. Restricting the child process to a subset of the parent’s resources prevents any process from
__________
View Answer
Answer: c
Explanation: None.
2. A parent process calling _____ system call will be suspended until children processes terminate.
a) wait
b) fork
c) exit
d) exec
View Answer
Answer: a
Explanation: None.
3. Cascading termination refers to termination of all child processes before the parent terminates
______
a) Normally
b) Abnormally
c) Normally or abnormally
View Answer
Answer: a
Explanation: None.
4. With _____________ only one process can execute at a time; meanwhile all other process are
waiting for the processor. With ______________ more than one process can be running
simultaneously each on a different processor.
a) Multiprocessing, Multiprogramming
b) Multiprogramming, Uniprocessing
c) Multiprogramming, Multiprocessing
d) Uniprogramming, Multiprocessing
View Answer
Answer: d
Explanation: None.
b) Device Queue
c) Process Identifier
View Answer
Answer: c
Explanation: None.
6. In UNIX, the return value for the fork system call is _____ for the child process and _____ for the
parent process.
View Answer
Answer: c
Explanation: None.
View Answer
Answer: a
Explanation: None.
8. The child process completes execution, but the parent keeps executing, then the child process is
known as __________
a) Orphan
b) Zombie
c) Body
d) Dead
View Answer
Answer: b
Explanation: None.
a) allows processes to communicate and synchronize their actions when using the same address
space
b) allows processes to communicate and synchronize their actions without using the same address
space
View Answer
Answer: b
Explanation: None.
c) share data
View Answer
Answer: a
Explanation: None.
3. Which of the following two operations are provided by the IPC facility?
View Answer
Answer: d
Explanation: None.
View Answer
Answer: c
Explanation: None.
5. The link between two processes P and Q to send and receive messages is called __________
a) communication link
b) message-passing link
c) synchronization link
View Answer
Answer: a
Explanation: None.
a) A communication link can be associated with N number of process(N = max. number of processes
supported by system)
c) Exactly N/2 links exist between each pair of processes(N = max. number of processes supported by
system)
View Answer
Answer: b
Explanation: None.
a) there is another process R to handle and pass on the messages between P and Q
View Answer
Answer: c
Explanation: None.
View Answer
Answer: b
Explanation: None.
9. In the Zero capacity queue __________
c) the sender keeps sending and the messages don’t wait in the queue
View Answer
Answer: b
Explanation: None.
c) is referred to as a link
View Answer
Answer: b
Explanation: None.
11. Bounded capacity and Unbounded capacity queues are referred to as __________
a) Programmed buffering
b) Automatic buffering
d) No buffering
View Answer
Answer: b
Explanation: None
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
View Answer
Answer: c
Explanation: None.
2. To differentiate the many network services a system supports ______ are used.
a) Variables
b) Sockets
c) Ports
d) Service names
View Answer
Answer: c
Explanation: None.
3. RPC provides a(an) _____ on the client side, a separate one for each remote procedure.
a) stub
b) identifier
c) name
d) process identifier
View Answer
Answer: a
Explanation: None.
4. 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
Answer: d
Explanation: None.
5. To resolve the problem of data representation on different systems RPCs define _____________
View Answer
Answer: c
Explanation: None.
View Answer
Answer: d
Explanation: None.
View Answer
Answer: b
Explanation: None.
8. A process that is based on IPC mechanism which executes on different systems and can
communicate with other processes using message based communication, is called ________
View Answer
Answer: c
Explanation: None.
1. 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
Explanation: None.
View Answer
Answer: b
Explanation: None.
3. What is a trap/exception?
View Answer
Answer: b
Explanation: None.
4. What is an ISR?
View Answer
Answer: c
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
a) the CPU uses polling to watch the control bit constantly, looping to see if a device is ready
b) the CPU writes one data byte to the data register and sets a bit in control register to show that a
byte is available
c) the CPU receives an interrupt when the device is ready for the next byte
View Answer
Answer: b
Explanation: None.
a) the CPU uses polling to watch the control bit constantly, looping to see if a device is ready
b) the CPU writes one data byte to the data register and sets a bit in control register to show that a
byte is available
c) the CPU receives an interrupt when the device is ready for the next byte
View Answer
Answer: a
Explanation: None.
a) the CPU uses polling to watch the control bit constantly, looping to see if a device is ready
b) the CPU writes one data byte to the data register and sets a bit in control register to show that a
byte is available
c) the CPU receives an interrupt when the device is ready for the next byte
View Answer
Answer: c
Explanation: None.
View Answer
Answer: b
Explanation: None.
View Answer
Answer: a
Explanation: None.
c) Once done handling, bringing back the system to the original state it was before the interrupt
occurred
View Answer
Answer: d
Explanation: None.
1. Which module gives control of the CPU to the process selected by the short-term scheduler?
a) dispatcher
b) interrupt
c) scheduler
View Answer
Answer: a
Explanation: None.
2. 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
Explanation: None.
3. 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
Explanation: None.
4. Which scheduling algorithm allocates the CPU first to the process that requests the CPU first?
c) priority scheduling
d) none of the mentioned
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
6. In priority scheduling algorithm, when a process arrives at the ready queue, its priority is
compared with the priority of ____________
a) all process
c) parent process
d) init process
View Answer
Answer: b
Explanation: None.
View Answer
Answer: b
Explanation: None.
View Answer
Answer: d
Explanation: None.
View Answer
Answer: a
Explanation: None.
10. Which one of the following can not be scheduled by the kernel?
c) process
View Answer
Answer: b
Explanation: User level threads are managed by thread library and the kernel is unaware of them.
View Answer
Answer: b
Explanation: None.
a) time
b) space
c) money
View Answer
Answer: a
Explanation: None.
View Answer
Answer: b
Explanation: None.
Answer: c
Explanation: None.
5. A process is selected from the ______ queue by the ________ scheduler, to be executed.
View Answer
Answer: c
Explanation: None.
a) When a process switches from the running state to the ready state
b) When a process goes from the running state to the waiting state
c) When a process switches from the waiting state to the ready state
View Answer
Answer: b
7. The switching of the CPU from one process or thread to another is called ____________
a) process switch
b) task switch
c) context switch
View Answer
Answer: d
Explanation: None.
8. What is Dispatch latency?
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
View Answer
Answer: c
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: d
Explanation: None.
View Answer
Answer: b
Explanation: None.
d) the total time from the completion till the submission of a process
View Answer
Answer: b
Explanation: None.
View Answer
Answer: c
Explanation: None.
a) the total time taken from the submission time till the completion time
b) the total time taken from the submission time till the first response is produced
c) the total time taken from submission time till the response is output
View Answer
Answer: b
Explanation: None.
a) Non-preemptive scheduling
b) Preemptive scheduling
View Answer
Answer: b
Explanation: None.
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
d) using very small time slices converts it into Shortest Job First algorithm
View Answer
Answer: a
3. The portion of the process scheduler in an operating system that dispatches processes is
concerned with ____________
a) assigning ready processes to CPU
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
View Answer
Answer: b
Explanation: None.
6. The strategy of making processes that are logically runnable to be temporarily suspended is called
____________
b) Preemptive scheduling
View Answer
Answer: b
Explanation: None.
7. What is Scheduling?
View Answer
Answer: a
Explanation: None.
8. There are 10 different processes running on a workstation. Idle processes are waiting for an input
event in the input queue. Busy processes are scheduled with the Round-Robin time sharing method.
Which out of the following quantum times is the best value for small response times, if the
processes have a short runtime, e.g. less than 10ms?
a) tQ = 15ms
b) tQ = 40ms
c) tQ = 45ms
d) tQ = 50ms
View Answer
Answer: a
Explanation: None.
9. Orders are processed in the sequence they arrive if _______ rule sequences the jobs.
d) critical ratio
View Answer
Answer: c
Explanation: None.
10. Which of the following algorithms tends to minimize the process flow time?
View Answer
Answer: b
Explanation: None.
11. Under multiprogramming, turnaround time for short jobs is usually ________ and that for long
jobs is slightly ___________
a) Lengthened; Shortened
b) Shortened; Lengthened
c) Shortened; Shortened
d) Shortened; Unchanged
View Answer
Answer: b
Explanation: None.
a) I only
d) I, II and III
View Answer
Answer: d
Explanation: I) Shortest remaining time first scheduling is a preemptive version of shortest job
scheduling. It may cause starvation as shorter processes may keep coming and a long CPU burst
process never gets CPU.
II) Preemption may cause starvation. If priority based scheduling with preemption is used, then a low
priority process may never get CPU.
III) Round Robin Scheduling improves response time as all processes get CPU after a specified time.
c) RR – Round Robin
View Answer
Answer: b
Explanation: None.
View Answer
Answer: b
Explanation: None.
b) multiprogramming systems
c) multiprocessor systems
d) operating systems
View Answer
Answer: b
Explanation: In a time sharing system, each user needs to get a share of the CPU at regular intervals.
4. Consider the following set of processes, the length of the CPU burst time given in milliseconds.
P1 6
P2 8
P3 7
P4 3
Assuming the above process being scheduled with the SJF scheduling algorithm.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: d
Explanation: None.
View Answer
Answer: a
Explanation: The larger the CPU burst, the lower the priority.
c) it can lead to some low priority process waiting indefinitely for the CPU
View Answer
Answer: c
Explanation: None.
8. What is ‘Aging’?
View Answer
Answer: d
Explanation: None.
a) Starvation
b) Wait queue
c) Ready queue
d) Aging
View Answer
Answer: d
Explanation: None.
a) i only
d) i, ii and iii
View Answer
Answer: d
Explanation: None.
11. Which of the following scheduling algorithms gives minimum average waiting time?
a) FCFS
b) SJF
c) Round – robin
d) Priority
View Answer
Answer: b
Explanation: None.
a) that can be used by one process at a time and is not depleted by that use
View Answer
Answer: a
Explanation: None.
a) mutual exclusion
b) a process may hold allocated resources while awaiting assignment of other resources
View Answer
Answer: d
Explanation: None.
a) the system can allocate resources to each process in some order and still avoid a deadlock
View Answer
Answer: a
Explanation: None.
b) using thread
c) using pipes
View Answer
Answer: a
Explanation: None.
a) banker’s algorithm
b) round-robin algorithm
c) elevator algorithm
d) karn’s algorithm
View Answer
Answer: a
Explanation: None.
a) in advance processes rarely know how much resource they will need
View Answer
Answer: d
Explanation: None.
View Answer
Answer: c
Explanation: None.
a) deadlock
b) starvation
c) inversion
d) aging
View Answer
Answer: b
Explanation: None.
9. Which one of the following is a visual ( mathematical ) way to determine the deadlock
occurrence?
b) starvation graph
c) inversion graph
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
a) must always be less than the total number of resources available in the system
b) must always be equal to the total number of resources available in the system
c) must not exceed the total number of resources available in the system
d) must exceed the total number of resources available in the system
View Answer
Answer: c
Explanation: None.
b) interrupts
c) system calls
d) special programs
View Answer
Answer: c
Explanation: None.
View Answer
Answer: b
4. For a deadlock to arise, which of the following conditions must hold simultaneously?
a) Mutual exclusion
b) No preemption
View Answer
Answer: d
Explanation: None.
View Answer
Answer: a
Explanation: If another process requests that resource (non – shareable resource), the requesting
process must be delayed until the resource has been released.
a) A process must be not be holding a resource, but waiting for one to be freed, and then request to
acquire it
b) A process must be holding at least one resource and waiting to acquire additional resources that
are being held by other processes
c) A process must hold at least one resource and not be waiting to acquire additional resources
View Answer
Answer: b
Explanation: None.
View Answer
Answer: a
Explanation: None.
c) may exist
View Answer
Answer: a
a) is required
b) is not required
View Answer
Answer: b
Explanation: They do not require mutually exclusive access, and hence cannot be involved in a
deadlock.
10. To ensure that the hold and wait condition never occurs in the system, it must be ensured that
____________
b) each process must request and be allocated all its resources before it begins its execution
View Answer
Answer: d
Explanation: c – A process may request some resources and use them. Before it can can request any
additional resources, however it must release all the resources that it is currently allocated.
11. The disadvantage of a process being allocated all its resources before beginning its execution is
____________
View Answer
Answer: b
Explanation: None.
12. To ensure no preemption, if a process is holding some resources and requests another resource
that cannot be immediately allocated to it ____________
View Answer
Answer: d
Explanation: None.
13. One way to ensure that the circular wait condition never holds is to ____________
a) impose a total ordering of all resource types and to determine whether one precedes another in
the ordering
b) to never let a process acquire resources that are held by other processes
View Answer
Answer: a
Explanation: None.
1. Each request requires that the system consider the _____________ to decide whether the current
request can be satisfied or must wait to avoid a future possible deadlock.
View Answer
Answer: a
Explanation: None.
2. Given a priori information about the ________ number of resources of each type that maybe
requested for each process, it is possible to construct an algorithm that ensures that the system will
never enter a deadlock state.
a) minimum
b) average
c) maximum
d) approximate
View Answer
Answer: c
Explanation: None.
3. A deadlock avoidance algorithm dynamically examines the __________ to ensure that a circular
wait condition can never exist.
c) operating system
d) resources
View Answer
Answer: a
Explanation: Resource allocation states are used to maintain the availability of the already and
current available resources.
b) the system can allocate resources to each process in some order and still avoid a deadlock
c) the state keeps the system protected and safe
View Answer
Answer: b
Explanation: None.
a) safe allocation
b) safe resource
c) safe sequence
View Answer
Answer: c
Explanation: None.
a) deadlocks
b) not deadlocks
c) fatal
View Answer
Answer: b
Explanation: None.
7. A system has 12 magnetic tape drives and 3 processes : P0, P1, and P2. Process P0 requires 10
tape drives, P1 requires 4 and P2 requires 9 tape drives.
Process
P0
P1
P2
Maximum needs (process-wise: P0 through P2 top to bottom)
10
a) P0, P1, P2
b) P1, P2, P0
c) P2, P0, P1
d) P1, P0, P2
View Answer
Answer: d
Explanation: None.
View Answer
Answer: b
Explanation: None.
9. The resource allocation graph is not applicable to a resource allocation system ____________
View Answer
Answer: a
Explanation: None.
10. The Banker’s algorithm is _____________ than the resource allocation graph algorithm.
a) less efficient
b) more efficient
c) equal
View Answer
Answer: a
Explanation: None.
11. The data structures available in the Banker’s algorithm are ____________
a) Available
b) Need
c) Allocation
View Answer
Answer: d
Explanation: None.
a) Allocation – Available
b) Max – Available
c) Max – Allocation
d) Allocation – Max
View Answer
Answer: c
Explanation: None.
13. A system with 5 processes P0 through P4 and three resource types A, B, C have A with 10
instances, B with 5 instances, and C with 7 instances. At time t0, the following snapshot has been
taken:
Process
P0
P1
P2
P3
P4
A B C
0 1 0
2 0 0
3 0 2
2 1 1
0 0 2
A B C
7 5 3
3 2 2
9 0 2
2 2 2
4 3 3
Available
A B C
3 3 2
The sequence <P1, P3, P4, P2, P0> leads the system to ____________
a) an unsafe state
b) a safe state
c) a protected state
d) a deadlock
View Answer
Answer: b
Explanation: None.
1. The wait-for graph is a deadlock detection algorithm that is applicable when ____________
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: b
Explanation: None.
a) rarely
b) frequently
View Answer
Answer: b
Explanation: None.
5. What is the disadvantage of invoking the detection algorithm for every request?
View Answer
Answer: c
Explanation: None.
6. A deadlock eventually cripples system throughput and will cause the CPU utilization to ______
a) increase
b) drop
c) stay still
View Answer
Answer: b
Explanation: None.
7. Every time a request for allocation cannot be granted immediately, the detection algorithm is
invoked. This will help identify ____________
View Answer
Answer: a
Explanation: None.
8. A computer system has 6 tape drives, with ‘n’ processes competing for them. Each process may
need 3 tape drives. The maximum value of ‘n’ for which the system is guaranteed to be deadlock
free is?
a) 2
b) 3
c) 4
d) 1
View Answer
Answer: a
Explanation: None.
9. A system has 3 processes sharing 4 resources. If each process needs a maximum of 2 units then,
deadlock ____________
b) may occur
c) has to occur
View Answer
Answer: a
Explanation: None.
10. ‘m’ processes share ‘n’ resources of the same type. The maximum need of each process doesn’t
exceed ‘n’ and the sum of all their maximum needs is always less than m+n. In this setup, deadlock
____________
b) may occur
c) has to occur
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
2. The two ways of aborting processes and eliminating deadlocks are ____________
View Answer
Answer: c
Explanation: None.
View Answer
Answer: b
Explanation: None.
View Answer
Answer: d
Explanation: None.
c) Amount of time a deadlocked process has thus far consumed during its execution
View Answer
Answer: c
Explanation: None.
6. 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
Explanation: None.
7. To _______ to a safe state, the system needs to keep more information about the states of
processes.
View Answer
Answer: b
Explanation: None.
8. If the resources are always preempted from the same process __________ can occur.
a) deadlock
b) system crash
c) aging
d) starvation
View Answer
Answer: d
Explanation: None.
View Answer
Answer: a
Explanation: None.
a) data consistency
b) data insecurity
c) data inconsistency
View Answer
Answer: c
Explanation: None.
2. A situation where several processes access and manipulate the same data concurrently and the
outcome of the execution depends on the particular order in which access takes place is called
____________
a) data consistency
b) race condition
c) aging
d) starvation
View Answer
Answer: b
Explanation: None.
3. The segment of code in which the process may change common variables, update tables, write
into files is known as ____________
a) program
b) critical section
d) synchronizing
View Answer
Answer: b
Explanation: None.
4. Which of the following conditions must be satisfied to solve the critical section problem?
a) Mutual Exclusion
b) Progress
c) Bounded Waiting
View Answer
Answer: d
Explanation: None.
a) if a process is executing in its critical section, then no other process must be executing in their
critical sections
b) if a process is executing in its critical section, then other processes must be executing in their
critical sections
c) if a process is executing in its critical section, then all the resources of the system must be blocked
until it finishes execution
View Answer
Answer: a
Explanation: None.
6. Bounded waiting implies that there exists a bound on the number of times a process is allowed to
enter its critical section ____________
a) after a process has made a request to enter its critical section and before the request is granted
View Answer
Answer: a
Explanation: None.
7. A minimum of _____ variable(s) is/are required to be shared between processes to solve the
critical section problem.
a) one
b) two
c) three
d) four
View Answer
Answer: b
Explanation: None.
b) each process receives a number (may or may not be unique) and the one with the lowest number
is served next
c) each process gets a unique number and the one with the highest number is served next
d) each process gets a unique number and the one with the lowest number is served next
View Answer
Answer: b
Explanation: None.
a) single
b) atomic
c) static
View Answer
Answer: b
Explanation: None.
c) atomically
View Answer
Answer: c
Explanation: None.
c) integer variable
View Answer
Answer: c
Explanation: None.
a) wait
b) stop
c) hold
View Answer
Answer: a
Explanation: None.
View Answer
Answer: d
Explanation: None.
View Answer
Answer: b
Explanation: None.
7. The wait operation of the semaphore basically works on the basic _______ system call.
a) stop()
b) block()
c) hold()
d) wait()
View Answer
Answer: b
Explanation: None.
8. The signal operation of the semaphore basically works on the basic _______ system call.
a) continue()
b) wakeup()
c) getup()
d) start()
View Answer
Answer: b
Explanation: None.
b) it is invalid
View Answer
Answer: a
Explanation: None.
10. The code that changes the value of the semaphore is ____________
View Answer
Answer: c
Explanation: None.
11. The following program consists of 3 concurrent processes and 3 binary semaphores. The
semaphores are initialized as S0 = 1, S1 = 0, S2 = 0.
Process P0
while(true)
wait(S0);
print '0';
release(S1);
release(S2);
Process P1
wait(S1);
release(S0);
Process P2
wait(S2);
release(S0);
a) At least twice
b) Exactly twice
c) Exactly thrice
d) Exactly once
View Answer
Answer: a
Explanation: None.
repeat
P(mutex)
{Critical Section}
V(mutex)
forever
The code for P10 is identical except that it uses V(mutex) instead of P(mutex). What is the largest
number of processes that can be inside the critical section at any moment (the mutex being
initialized to 1)?
a) 1
b) 2
c) 3
View Answer
Answer: c
Explanation: Any one of the 9 processes can get into critical section after executing P(mutex) which
decrements the mutex value to 0. At this time P10 can enter critical section by incrementing the
value to 1. Now any of the 9 processes can enter the critical section by again decrementing the
mutex value to 0. None of the remaining processes can get into their critical sections.
13. Two processes, P1 and P2, need to access a critical section of code. Consider the following
synchronization construct used by the processes.
Process P1 :
while(true)
w1 = true;
while(w2 == true);
Critical section
w1 = false;
Remainder Section
Process P2 :
while(true)
w2 = true;
while(w1 == true);
Critical section
w2 = false;
Remainder Section
Here, w1 and w2 have shared variables, which are initialized to false. Which one of the following
statements is TRUE about the above construct?
View Answer
Answer: d
Explanation: None.
View Answer
Answer: c
Explanation: None.
2. In the bounded buffer problem, there are the empty and full semaphores that ____________
View Answer
Answer: a
Explanation: None.
View Answer
Answer: b
Explanation: None.
4. To ensure difficulties do not arise in the readers – writers problem _______ are given exclusive
access to the shared object.
a) readers
b) writers
View Answer
Answer: b
Explanation: None.
View Answer
Answer: a
Explanation: None.
View Answer
Answer: b
Explanation: None.
7. All processes share a semaphore variable mutex, initialized to 1. Each process must execute
wait(mutex) before entering the critical section and signal(mutex) afterward.
.....
critical section
.....
wait(mutex);
In this situation :
View Answer
Answer: c
Explanation: None.
8. All processes share a semaphore variable mutex, initialized to 1. Each process must execute
wait(mutex) before entering the critical section and signal(mutex) afterward.
wait(mutex);
.....
critical section
.....
wait(mutex);
View Answer
Answer: a
Explanation: None.
9. Consider the methods used by processes P1 and P2 for accessing their critical sections whenever
needed, as given below. The initial values of shared boolean variables S1 and S2 are randomly
assigned. (GATE 2010)
Method used by P1 :
while(S1==S2);
Critical section
S1 = S2;
Method used by P2 :
while(S1!=S2);
Critical section
S2 = not(S1);
View Answer
Answer: d
Explanation: None.
a) semaphore
View Answer
Answer: c
Explanation: None.
2. A monitor is characterized by ____________
b) an identifier
View Answer
Answer: a
Explanation: None.
3. A procedure defined within a ________ can access only those variables declared locally within the
_______ and its formal parameters.
a) process, semaphore
b) process, monitor
c) semaphore, semaphore
d) monitor, monitor
View Answer
Answer: d
Explanation: None.
b) n number of processes can be active at a time within the monitor (n being greater than 1)
View Answer
Answer: a
Explanation: None.
View Answer
Answer: a
Explanation: None.
b) waiting for another process to complete before it can itself call the signal operation
View Answer
Answer: a
Explanation: None.
c) nothing happens
View Answer
Answer: c
Explanation: None.
a) transaction
b) operation
c) function
View Answer
Answer: a
Explanation: None.
a) committed, destroyed
b) aborted, destroyed
c) committed, aborted
View Answer
Answer: c
Explanation: None.
3. The state of the data accessed by an aborted transaction must be restored to what it was just
before the transaction started executing. This restoration is known as ________ of transaction.
a) safety
b) protection
c) roll – back
d) revert – back
View Answer
Answer: c
Explanation: None.
a) to ensure atomicity
View Answer
Answer: d
Explanation: None.
5. In the write ahead logging a _____________ is maintained.
a) a memory
b) a system
c) a disk
d) a log record
View Answer
Answer: d
Explanation: None.
c) until the whole log record has been checked for inconsistencies
View Answer
Answer: a
Explanation: None.
7. The undo and redo operations must be _________ to guarantee correct behaviour, even if a
failure occurs during recovery process.
a) idempotent
b) easy
c) protected
View Answer
Answer: a
Explanation: Idempotent – Multiple executions of an operation have the same result as does one
execution.
8. The system periodically performs checkpoints that consists of the following operation(s)
____________
a) Putting all the log records currently in main memory onto stable storage
b) putting all modified data residing in main memory onto stable storage
View Answer
Answer: d
Explanation: None.
9. Consider a transaction T1 that committed prior to checkpoint. The <T1 commits> record appears
in the log before the <checkpoint> record. Any modifications made by T1 must have been written to
the stable storage either with the checkpoint or prior to it. Thus at recovery time ____________
View Answer
Answer: c
Explanation: None.
View Answer
Answer: a
Explanation: None.
Answer: c
Explanation: None.
View Answer
Answer: a
Explanation: None.
c) A transaction may release locks, but does not obtain any new locks
View Answer
Answer: a
Explanation: None.
c) A transaction may release locks, but does not obtain any new locks
View Answer
Answer: c
Explanation: None.
15. Which of the following concurrency control protocols ensure both conflict serializability and
freedom from deadlock?
I) 2-phase locking
a) I only
b) II only
c) Both I and II
d) Neither I nor II
View Answer
Answer: b
Explanation: None.
a) Starvation
b) Deadlock
c) Aging
d) Signaling
View Answer
Answer: b
Explanation: If a thread which had already locked a mutex, tries to lock the mutex again, it will enter
into the waiting list of that mutex, which results in a deadlock. It is because no other thread can
unlock the mutex.
2. What is a semaphore?
a) is a binary mutex
View Answer
Answer: c
Explanation: None.
View Answer
Answer: b
Explanation: None.
4. What is a mutex?
a) is a binary mutex
View Answer
Answer: b
Explanation: None.
a) 42
b) 2
c) 7
d) 12
View Answer
Answer: b
Explanation: P represents Wait and V represents Signal. P operation will decrease the value by 1
every time and V operation will increase the value by 1 every time.
b) -1
c) 0.8
d) 0.5
View Answer
Answer: a
Explanation: None.
Process A
int Y;
A1: Y = X*2;
A2: X = Y;
Process B
int Z;
B1: Z = X+1;
B2: X = Z;
X is set to 5 before either process begins execution. As usual, statements within a process are
executed sequentially, but statements in process A may execute in any order with respect to
statements in process B.
How many different values of X are possible after both processes finish executing?
a) two
b) three
c) four
d) eight
View Answer
Answer: c
Explanation: Here are the possible ways in which statements from A and B can be interleaved.
A1 A2 B1 B2: X = 11
A1 B1 A2 B2: X = 6
A1 B1 B2 A2: X = 10
B1 A1 B2 A2: X = 10
B1 A1 A2 B2: X = 6
B1 B2 A1 A2: X = 12.
Process A
int Y;
A1: Y = X*2;
A2: X = Y;
signal(T);
Process B
int Z;
B1: wait(T);
B2: Z = X+1;
X = Z;
Now, how many different values of X are possible after both processes finish executing?
a) one
b) two
c) three
d) four
View Answer
Answer: a
Explanation: The semaphore T ensures that all the statements from A finish execution before B
begins. So now there is only one way in which statements from A and B can be interleaved:
A1 A2 B1 B2: X = 11.
b) IPC mechanisms
c) System protection
View Answer
Answer: b
Explanation: None.
a) Mutual Exclusion
b) Bounded Waiting
c) Aging
d) Progress
View Answer
Answer: b
Explanation: None.
Windows
Linux
Oracle
DOS
12
Answer: (c) 8
Explanation: The maximum length of the filename is 8 characters in the DOS operating system. It is
commonly known as an 8.3 filename.
1948
1949
1950
1951
Explanation: The first operating system was developed in the early 1950's. It was also called a single-
stream batch processing system because it presented data in groups.
1994
1990
1992
1985
Hide Answer Workspace
Explanation: The first MS Windows operating system was introduced in early 1985.
.txt
.xls
.ppt
.bmp
Explanation: The .txt file extension is a standard text document extension that contains the
unformatted text. It is the default file extension for the notepad.
prompt
kernel
shell
command
Explanation: The FAT stands for File allocation table. The FAT is a file system architecture. It is used
in computer systems and memory cards. A FAT of the contents of a computer disk indicates which
field is used for which file.
8) BIOS is used?
By operating system
By compiler
By interpreter
By application software
Explanation: BIOS is used by the operating system. It is used to configure and identify the hardware
in a system such as the hard drive, floppy drive, optical drive, CPU, and memory.
Restarting computer
To scan
To turn off
Explanation: Page faults occur when a process tries to access a block page of the memory and that
page is not stored in RAM (Read only memory) or memory.
To prevent deadlock
To deadlock recovery
None of these
Explanation: Banker's algorithm is used to prevent the deadlock condition. The banker algorithm is
sometimes called the detection algorithm. It is named the banker algorithm because it is used to
determine whether a loan can be granted in the banking system or not.
12) When you delete a file in your computer, where does it go?
Recycle bin
Hard disk
Taskbar
None of these
Explanation: When you delete a file on your computer device, it is transferred to your computer
system's recycle bin or trash.
None of these
Explanation: The Linux operating system is an open-source operating system made up of a kernel. It
is a very safe operating system.
None of these
Explanation: The IDL stands for Interface Definition Language. It is used to establish communications
between clients and servers in RPC (Remote Procedure Call).
Cold boot
Hot boot
To disk protection
To CPU protection
To memory protection
None of these
Decreases
Increases
Remains constant
None of these
Explanation: None
Windows
MAC
Ms-Dos
None of these
Explanation: The single-user operating system is the operating system in which only one user can
access the computer system at a time, and Ms-DOS is the best example of a single-user operating
system.
CPU
RAM
Address bus
Data bus
21) If a page number is not found in the translation lookaside buffer, then it is known as a?
Buffer miss
Explanation: A Translation Lookaside Buffer miss arises when the page table entry needed to
translate a virtual address to a physical address is not available in the translation lookaside buffer.
Windows 7
WordPad
Photoshop
MS-excel
Window 2000
Window 1998
None of these
Explanation: Windows XP supports the 64-bits. Windows XP is designed to expand the memory
address space. Its original name is Microsoft Windows XP Professional x64 and it is based on the x86-
64 architecture.
24) Which of the following windows does not have a start button?
Windows 7
Windows 8
Windows XP
None of these
Explanation: Windows 8 does not have a start button because it uses the tablet mode, but windows
8.1 has a start button.
25) Which of the following operating systems does not support more than one program at a time?
Linux
Windows
MAC
DOS
Mutual exclusion
Circular wait
No preemption
All of these
Explanation: None
27) Who provides the interface to access the services of the operating system?
API
System call
Library
Assembly instruction
Explanation: The system call provides an interface for user programs to access the services of the
operating system through the API (Application Program Interface).
28) Where are placed the list of processes that are prepared to be executed and waiting?
Job queue
Ready queue
Execution queue
Process queue
Explanation: The ready queue is a set of all the processes that processes are ready to execute and
wait.
29) Who among the following can block the running process?
Fork
Read
Down
All of these
Explanation: None
30) Which of the following does not interrupt the running process?
Timer interrupt
Device
Power failure
Scheduler process
Explanation: Scheduler process does not interrupt in any running process. Its job is to select the
processes for long-term, short-term, and short-term scheduler.
Graphics program
Word Processing
Database program
Explanation: Microsoft Windows is an operating system that was developed by Microsoft company.
The Microsoft Windows is available in 32-bits and 64-bits in the market.
Accessories
Paint
Word
All of above
Explanation: The windows accessories are a group of programs in the operating system. Windows XP
offers many accessories or software that you can use to help with your work. The accessories are not
full features programs, but it is useful for a specific task in the operating systems. It provides many
programs such as a painting program, a calculator, a word processor, a notepad, and Internet
software.
MAC
MS-DOS
Windows 10
Process Control
34) Which of the following operating systems do you use for a client-server network?
MAC
Linux
Windows XP
Windows 2000
Explanation: Windows 2002 operating systems were used to implement a client Server Network. It is
a server OS that was developed by Microsoft in April 24, 2002. It includes some features of Windows
XP.
Windows 10
Windows XP
Windows 95
Windows 98
36) What type of commands are required to perform various tasks in DOS?
Internal commands
External commands
Valuable commands
Primary commands
37) What is the number of characters contained in the primary name of the file of MS-DOS?
Up to 8 characters
3 characters
Up to 10 characters
Explanation: MS-DOS operating system uses the file system that supports the 8.3 characters. The
eight characters are used to the filename, and three characters are used to the extension.
38) Which command is used to fetch a group (.doc) of files that have just been deleted?
Undelete
Undelete/all
Undelete *.doc
All of above
Explanation: Undelete *.doc command is used to fetch a group (.doc) of files that have just been
deleted.
Compiler
Utilities
Explanation: The system software is a type of computer program designed to run hardware and
software programs on a computer.
According to some definitions, system software also includes system utilities, system restore,
development tools, compilers, and debuggers.
40) Which program runs first after booting the computer and loading the GUI?
Desktop Manager
File Manager
Windows Explorer
Authentication
Explanation: The authentication program is run first after booting the computer and loading the GUI.
Authentication is a process of verifying the person or device. For example, when you log in to
Facebook, you enter a username and password.
1. Which of the following is NOT a valid deadlock prevention scheme? (GATE CS 2000)
(b) Number the resources uniquely and never request a lower numbered resource than the last one
requested.
References:
http://www.cs.jhu.edu/~yairamir/cs418/os4/sld013.htm
http://en.wikipedia.org/wiki/Deadlock
------
(a) Thrashing
(b) Deadlock
Answer: (b)
Explanation:
3. A graphics card has on board memory of 1 MB. Which of the following modes can the
card not support? (GATE CS 2000)
Answer: (b)
Explanation:
Monitor size doesn’t matter here. So, we can easily deduce that answer should be (b) as this has the
highest memory requirements. Let us verify it.
Number of bytes required for 1600 x 400 resolution with 16M colors = (1600 * 400 * 24)/8 which is
192000000 (greater than 1MB).
4 Consider a virtual memory system with FIFO page replacement policy. For an arbitrary page access
pattern, increasing the number of page frames in main memory will (GATE CS 2001)
Answer: (c)
Explanation:
Incrementing the number of page frames doesn’t always decrease the page faults (Belady’s
Anomaly). For details see http://en.wikipedia.org/wiki/Belady%27s_anomaly
a) Register
b) Cache
c) Main memory
d) Disk
Answer: (d)
Attention reader! Don’t stop learning now. Get hold of all the important CS Theory concepts for SDE
interviews with the CS Theory Course at a student-friendly price and become industry ready.