OS 2 marks
OS 2 marks
File management
Status Information
File Modification
Programming language support
Program loading & execution
Communication
44. What is Boot strapping? [R]
i. The boot program is stored on disk with predetermined address called boot
sector. The boot program then loads the operating system into memory to
startup the computer this arrangement is known as bootstrapping.
45. Difference b/w Monolithic & Microlithic. [An]
52. Install
53. Request may be serviced 54. Request may be serviced slower
faster
55. All OS services are included 57. Kernel Provides only IPC and low
in the level
67. Mention the circumstances that would a user be better off using a time-sharing
system rather than a PC or a single user workstation? (MAY/JUNE 2014) [An]
A user is better off fewer than three situations: when it is cheaper, faster, or
easier.
For example: When the user is paying for management costs and the costs are
cheaper for atime-sharing system than for a single-user computer.
When running a simulation or calculation that takes too long to run on a single PC or
workstation.When a user is travelling and doesn't have laptop to carry around, they can
connectremotely to a time-shared system and do their work.
68. Do timesharing differ from Multiprogramming? If so, How?(APR/MAY 2015)
i. Time Sharing: here, OS assigns some time slots to each job. Here,
each job is executed according to the allotted time slots.
ii. Job1: 0 to 5 Job2: 5 to 10 Job3: 10 to 15
Multi-Tasking: in this operating system, jobs are executed in
parallel by the operating system. But, we can achieve this multi-
tasking through multiple processors (or) multicore CPU only.
iii. CPU1: Job1 CPU2: Job2 CPU3: Job3
69. Why API s need to be used rather than system calls?(APR/MAY 2015) [An]
System calls are much slower than APIs (library calls) since for each system call, a context
switch has to occur to load the OS (which then serves the system call).Most detailsof OS
interface hidden from programmer by API Managed by run-time support library (Set of
functions built into libraries included with compiler.)
70. Describe the actions taken by a thread library to context switch between user- level
threads. [An]
The user-level threads are known only within a given process. To context switch, we only
need to save the thread-specific context: the program counter, CPU registers, and the
thread-specific stack pointer
71. What is the purpose of system programs? (May/Jun 2016) [R]
System programs can be thought of as bundles of useful system calls. They provide basic
functionality to users so that users do not need to write their own programs to solve
common problems.
72. What are the advantages of peer-to-peer systems over client-server systems?
(May/Jun 2016) [R]
a. It is easy to install and so is the configuration of computers on this network, all the
resources and contents are shared by all the peers, unlike server-client architecture
where Server shares all the contents and resources.
b. P2P is more reliable as central dependency is eliminated. Failure of one peer doesn‘t
affect the functioning of other peers. In case of Client –Server network, if server
goes down whole network gets affected.
c. There is no need for full-time System Administrator. Every user is the administrator
of his machine. User can control their shared resources.
d. The over-all cost of building and maintaining this type of network is comparatively
very less.
73. Compare and contrast DMA and cache memory. (Nov/Dec 2015) [An]
a. DMA is a hardware device that can move to/from memory without using CPU
instructions.
b. For instance, a hardware device (lets say, your PCI sound device) wants audio to
play back. You can either:
c. Write a word at a time via a CPU mov instructions.
d. Configure the DMA device. You give it a start address, a destination, and the
number of bytes to copy. The transfer now occurs while the CPU does something
else instead of spoon feeding the audio device.
e. DMA can be very complex (scatter gather, etc), and varies by bus type and system.
74. Write the difference between Batch systems and Time sharing systems. (Nov/Dec
2015) [An]
a. A batch is a sequence of jobs. This batch is submitted to batch processing operating
systems, and output would appear some later time in the form of a program or as
program error. To speed up processing similar jobs are batched together.The major
task of batch operating systems is to transfer control automatically from one job to
next. Here the operating is always in the memory.
b. Time sharing or multi-tasking is a logical execution of multiprogramming. Multiple
jobs are executed by the CPU switching between them. Here the computer system
provides on line communication between the user and the system.
c. Here the CPU is never idle. Time shared operating system allows many users to
share the computer simultaneously.
d. Time sharing systems requires some sort of memory management and protection.
75. How does an interrupt differ from a trap or what is the difference between trap and
interrupt? (NOV/DEC 2016) [An] (APR/MAY 2018)
An interrupt handler is called to deal with the cause of the interrupt; control is thenreturned
to the interrupted context and instruction. A trap is a software-generated interrupt. An
interrupt can be used to signal the completion of an I/O to obviate the need for device
polling.
76. What are the disadvantages of multiprocessor systems? (NOV/DEC 2016) [R]
a. If one processor fails then it will affect in the speed
b. Multiprocessor systems are expensive.
c. Complex OS is required.
d. It's more complex.
e. It requires context switching which slightly impacts
77. Consider memory systems with a cache access time of 10 ns and a memory access
time of 110 ns-assume the memory access time includes the time to check the cache.
if the effective access time is 10 % greater than the cache access time, Whatis the hit
ration H? (APR/MAY 2017) [E]
78. What are the objectives of operating systems? (APR/MAY 2017) [R] (NOV/DEC
2017) [R]
i. An OS is a program that controls the execution of application programs and
acts as an interface between applications and the computer hardware.
Objectives of OS: Convenience: An OS makes a computer more convenient
to use. Efficiency: An OS allows the computer system resources to be used
in an efficient manner.
79. What is SYS GEN and system boot ?[R] (NOV/DEC 2017) (NOV/DEC 2021)
SYS GEN :It is the Short for SYStem GENeration, sysgen is a utility that enablesan
operating system to configure hardware and software setups properly.
System Boot:
Booting the system is done by loading the kernel into main memory, and startingits
execution.
The CPU is given a reset event, and the instruction register is loaded with a
predefined memory location, where execution starts.
80. Mention the purpose of system calls.[R] (APR/MAY 2018)
a. System calls allow user-level processes to request services of the operating system.
b. If a file system requires the creation or deletion of files.
c. Reading and writing from files also require a system call.
d. Creation and management of new processes.
e. Network connections also require system calls. This includes sending and
receivingpackets.
f. Access to a hardware devices such as a printer, scanner etc. requires a system call.
81. What is dual mode operation and what is the need of it?(APRIL/MAY 2019) In
monitor mode, the CPU can use all instructions and access all areas of memory.
a. In user mode, the CPU is restricted to unprivileged instructions and a specified area
ofmemory. User code should always be executed in user mode and the OS design
ensures that it is.
82. Distinguish between Multicore and Multiprocessor. (NOV/DEC 2021)
i. Multicore systems have a single processor with multiple processing units.
These processing units are termed cores. On the other hand, multiprocessor
systems have two or more processors. A multiprocessor system is much
more reliable than a multicore system but a multiprocessor system has a
complex configuration compared to a multicore system. Both multicore
processors and multiprocessors are used to speeding up the computing
process of the system.
UNIT II
83. Define process. What is the information maintained in a PCB ?
Ans. A process is simply a program in execution. i.e. an instance of a program. execution.
PCB maintains pointer, state, process number, CPU register, PC, memory allocation etc.
84. Define task control block.
TCB is also called PCB.
85. What is PCB? Specify the information maintained in it. AU CSE/IT: Dec.-12
Each process is represented in the operating system by a process control block. PCB contains
information like process state, program counter, CPU register, accounting information etc.
86. What is independent process ?
Independent process cannot affect or be affected by the execution of another process.
87. Name and draw five different process states with proper definition. AU: Dec.-17
Process states are new, running, waiting, ready and terminated. Fig. 2.16.1 shows process
state diagram.
88. Define context switching.
Ans. Switching the CPU to another process requires saving the state of the old process and
loading the saved state for the new process. This task is known as context switch.
89. What are the reasons for terminating execution of child process ?
Ans. Parent may terminate execution of children processes via abort system call for a variety of
reasons, such as:
Child has exceeded allocated resources.
Task assigned to child is no longer required.
Parent is exiting and the operating system does not allow a child to continue if its
parent terminates.
90. What is ready queue ?
Ans. The processes that are residing in main memory and are ready and waiting to execute are
kept on a list called the ready queue.
91. List out the data fields associated with process control blocks.
Data fields associated with process control block is CPU registers, PC, process state, memory
management information, input-output status information etc.
92. What are the properties of communication link ?
Properties of communication link
1. Links are established automatically.
2. A link is associated with exactly one pair of communicating processes.
3. Between each pair there exists exactly one link.
4. The link may be unidirectional, but is usually bidirectional.
93. What is socket ?
A socket is defined as an endpoint for communication.
94. What is non-preemptive scheduling ?
Ans.Non-preemptive scheduling ensures that a process relinquishes control of the CPU only
when it finishes with its current CPU burst.
95. Differentiate preemptive and non-preemptive scheduling.
Ans. :
96.
97. What do you mean by short term scheduler ?
Short term scheduler, also known as a dispatcher executes most frequently, and makes the
finest-grained decision of which process should execute next. This scheduler is invoked
whenever an event occurs.
98. Which are the criteria used for CPU scheduling ?
Criteria used for CPU scheduling are CPU utilization, throughput, turnaround time, waiting
time, response time.
99. Explain why two level scheduling is commonly used.
Ans. It provides the hybrid solution to the problem of providing good system utilization and
good user service simultaneously.
100. Why is it important for the scheduler to distinguish I/O-bound programs from CPU-
bound programs?
I/O-bound programs have the property of performing only a small amount of computation
before performing IO. Such programs typically do not use up their entire CPU quantum.
CPU-bound programs, on the other hand, use their entire quantum without performing any
blocking IO operations. Consequently, one could make better use of the computer's resources
by giving higher priority to I/O-bound programs and allow them to execute ahead of the
CPU-bound programs.
101. What is response time?
Response time is the amount of time it takes from when a request was, submitted until the
first response is produced, not output.
102. Define waiting time.
Amount of time a process has been waiting in the ready queue.
103. Define scheduling algorithm ?
In multiprogramming systems, whenever two simultaneously in the ready state, a choice has
to be made which process to run next. The part of the OS that makes the choice is called the
scheduler and the algorithm it uses is called the scheduling algorithm.
104. Define the term dispatch latency.
Time it takes for the dispatcher to stop one process and start another running.
105. What is preemptive priority method?
Ans. A preemptive priority will preempt the CPU if the newly arrived process is higher than
the priority of the currently running process.
106. What is medium term scheduling ?
Medium-term scheduling used especially with time-sharing systems as an intermediate
scheduling level. A swapping scheme is implemented to remove partially run programs from
memory and reinstate them later to continue where they left off.
107. What is preemptive scheduling ?
Preemptive scheduling can preempt a process which is utilizing the CPU in between its
execution and give the CPU to another process.
108. What is the difference between long-term scheduling and short-term scheduling ?
Long term scheduling adds jobs to the ready queue from the job queue. Short term scheduling
dispatches jobs from the ready queue to the running state.
109. List out any four scheduling criteria.
Response time, throughput, waiting time and turn around time.
110. Define the term 'Dispatch latency'.
Dispatch latency: Time it takes for the dispatcher to stop one process and start another running.
It is the amount of time required for the scheduler to stop one process and start another.
111. Distinguish between CPU-bounded and I/O bounded processes.
112. Define priority inversion problem.
The higher priority process would be waiting for the low priority one to finish. This situation
is known as priority inversion problem.
113. What advantage is there in having different time-quantum sizes on different levels of a
multilevel queuing system?
Processes that need more frequent servicing, for instance, interactive processes such as
editors, can be in a queue with a small time quantum. Processes switch no need for frequent
servicing can be in a queue with a larger quantum, requiring fewer context switches to complete
the processing, and thus making more efficient use of the computer.
114. How does real-time scheduling differs from normal scheduling ?
Normal scheduling provides no guarantee on when a critical process will be scheduled; it
guarantees only that the process will be given preference over non-critical processes. Real-time
systems have stricter requirements. A task must be serviced by its deadline; service after the
deadline has expired is the same as no service at all.
115. What is Shortest-Remaining-Time-First (SRTF) ?
If a new process arrives with CPU burst length less than remaining time of
process, current executing preempt. This scheme is known as the Shortest-Remaining-Time-First.
116. What is round robin CPU scheduling ?
Each process gets a small unit of CPU time (time quantum). After this time has elapsed, the
process is preempted and added to the end of the ready queue.
117. What is meant by starvation in operating system?
Starvation is a resource management problem where a process does not get the resources
(CPU) it needs for a long time because the resources are being allocated to other processes.
118. What is an aging?
Aging is a technique to avoid starvation in a scheduling system. It works by adding an aging
factor to the priority of each request. The aging factor must increase the requests priority as
time passes and must ensure that a request will eventually be the highest priority request
119. How to solve starvation problem in priority CPU scheduling ?
Aging - as time progresses increase the priority of the process, so eventually the process will
become the highest priority and will gain the CPU. i.e., the more time is spending a process
in ready queue waiting, its priority becomes higher and higher.
120. What is convoy effect?
A convoy effect happens when a set of processes need to use a resource for a short time, and
one process holds the resource for a long time, blocking all of the other processes. Essentially
it causes poor utilization of the other resources in the system.
121. How can starvation / indefinite blocking of processes be avoided in priority scheduling?
A solution to the problem of indefinite blockage of processes is aging. Aging is a technique
of gradually increasing the priority of processes that wait in the system for a long time.
122. "Priority inversion is a condition that occurs in real time systems where a low priority
process is starved because higher priority processes have gained hold of the CPU" -
Comment on this statement. AU CSE: May-17
A low priority thread always starts on a shadow version of the shared resource, the original
resource remains unchanged. When a high-priority thread needs a resource engaged by a low -
priority thread, the low priority thread is preempted, the original resource is restored and the high
priority thread is allowed to use the original
123. Provide two programming examples in which multithreading provides better.
performance than a single-threaded solution.
A Web server that services each request in a separate thread.
A parallelized application such as matrix multiplication where different parts of the matrix
may be worked on in parallel.
An interactive GUI program such as a debugger where a thread is used to monitor user input,
another thread represents the running application, and a show third thread monitors
performance.
124. State what does a thread share with peer threads.
Thread share the memory and resource of the process.
125. Define a thread. State the major advantage of threads.
A thread is a flow of execution through the process's code with its own program counter,
system registers and stack.
Efficient communication.
Minimize context switching time.
126. Can a multithreaded solution using multiple user-level threads achieve better
performance on a multiprocessor system than on a single processor system ?
A multithreaded system comprising of multiple user-level threads cannot make use of the
different processors in a multiprocessor system simultaneously. The operating system sees
only a single process and will not schedule the different threads of the process on separate
processors. Consequently, there is no performance benefit associated with executing multiple
user-level threads on a multiprocessor system.
127. What are the differences between user-level threads and kernel-level threads ?
i. Process state
Process number
Program counter
CPU registers
Memory limits
List of open files
CPU scheduling information
Memory management
information
Accounting information
I/O status information
165. What is meant by context switching?[R]
Switching the CPU to another process requires saving the state of the old process and
loading the savet the state for the new process. This task is known as context switch.
166. Define co- operating process and independent process.[R]
Independent process:
a. A process is independent if it cannot affect or be affected by the other processes
executing in the system.
b. A process that does not share data with any other process is independent.
Cooperating process:
c. A process is co-operating if it can affect or be affected by other processes
executing in the system.
d. Any process that shares data with any other process is cooperating.
167. What are the benefits of multithreaded programming? [R]
The benefits of multithreaded programming can be broken down into four major categories
Responsiveness
Resource sharing
Economy scalability
Utilization of multiprocessor architectures.
168. What is a thread?[R]
i. A thread otherwise called a lightweight process (LWP) is a basic unit of CPU uti
lization, it comprises of a thread id, a program counter, a register set and a stack. It
shareswith other threads belonging to the same process its code section, data section,
and operating system resources
Mutual exclusion
Progress & Bounded waiting
183. Define mutual exclusion. (MAY/JUNE 2013)[R]
Mutual exclusion refers to the requirement of ensuring that no two process or
threadsare in their critical section at the same time.i.e. If process Pi is executing in
its critical section, then no other processes can beexecuting in their critical
sections.
184. Define entry section and exit section.[R]
The critical section problem is to design a protocol that the processes can use to
cooperate. Each process must request permission to enter its critical section.
Entry Section: The section of the code implementing this request is the entry section.
Exit Section: The section of the code following the critical section is an exit section.
a. The general structure:
do {
entry section
critical section
exit section
remainder section
} while(1);
185. Give two hardware instructions and their definitions which can be used
for implementing mutual exclusion.[An]
TestAndSet
a. When a process switches from the running state to the waiting state, such as for an
I/O request or invocation of the wait ( ) system call.
b. When a process switches from the running state to the ready state, for example in
response to an interrupt.
c. When a process switches from the waiting state to the ready state, say at
completion of I/O or a return from wait ( ).
d. When a process terminates.
196. Define deadlock. (APRIL/MAY 2010)[R]
A process requests resources; if the resources are not available at that time, the
process enters a wait state. Waiting processes may never again change state, because
the resources they have requested are held by other waiting processes. This situation
is calleda deadlock.
197. What is the sequence in which resources may be utilized?[R]
Under normal mode of operation, a process may utilize a resource in the following
sequence:
a. Request: If the request cannot be granted immediately, then the requesting process
must wait until it can acquire the resource.
b. Use: The process can operate on the resource.
c. Release: The process releases the resource.
198. What are conditions under which a deadlock situation may arise?
A deadlock situation can arise if the following four conditions hold simultaneouslyin a
system:
Mutual exclusion
201. What are the methods for handling deadlocks? (APRIL/MAY 2011)[R]
The deadlock problem can be dealt with in one of the three ways:
Use a protocol to prevent or avoid deadlocks, ensuring that the system will never
enter a deadlock state.
Allow the system to enter the deadlock state, detect it and then recover.
Ignore the problem all together, and pretend that deadlocks never occur in the system.
202. How real-time Scheduling does differs from normal scheduling?
i. In a normal Scheduling, we have two types of processes. User process &
kernel Process. Kernel processes have time constraints. However, user
processes do not have timeconstraints.
ii. In a RTOS, all process are Kernel process & hence time constraints should be
strictlyfollowed. All process/task (can be used interchangeably) are based on
priority and time constraints are important for the system to run correctly.
203. What do you meant by short-term scheduler (NOV/DEC 2010) [R]
The selection process is carried out by the short-term scheduler or CPU scheduler.
The scheduler selects the process form the process in memory that is ready to execute
and allocates the CPU to the process.
204. What is the concept behind strong semaphore and spinlock?
A spinlock is one possible implementation of a lock, namely one that is implementedby busy
waiting ("spinning"). A semaphore is a generalization of a lock (or, the other wayaround, a
lock is a special case of a semaphore). Usually, but not necessarily, spinlocks are only valid
within one process whereas semaphores can be used to synchronize between different
processes, too.
A semaphore has a counter and will allow itself being acquired by one or several threads,
depending on what value you post to it, and (in some implementations) depending on what its
maximum allowable value is.
205. What is the meaning of the term busy waiting? (May/Jun 2016) [R]
Busy waiting means that a process is waiting for a condition to be satisfied in a tightloop
without relinquish the processor. Alternatively, a process could wait by relinquishingthe
processor, and block on a condition and wait to be awakened at some appropriate timein
the future.
206. Distinguish between CPU-bounded and I/O bounded processes.
CPU Bound means the rate at which process progresses is limited by the speed of
the CPU. A task that performs calculations on a small set of numbers, for example
multiplying small matrices, is likely to be CPU bound.
I/O Bound means the rate at which a process progresses is limited by the speed of the
I/Osubsystem. A task that processes data from disk, for example, counting the number
of lines in a file is likely to be I/O bound.
207. What resources are required to create threads (NOV/DEC 2016) [R]
When a thread is created, the thread does not require any new resources to execute the
thread shares the resources like memory of the process to which they belong. The
benefit of code sharing is that it allows an application to have several different threads
of activity all within the same address space.
208. “Priority inversion is a condition that occurs in real time systems where a low
priority process is starved because higher priority processes have gained hold of the
CPU”-Comment on this statement. (APR/MAY 2017) [An]
Priority inversion is a problematic scenario in scheduling in which a high
prioritytask is indirectly preempted by a lower priority task effectively "inverting" the
relative priorities of the two tasks. This violates the priority model that high priority tasks
can onlybe prevented from running by higher priority tasks and briefly by low priority
tasks whichwill quickly complete their use of a resource shared by the high and low
priority tasks.
214. List out the benefits and challenge of thread handling. (APR/MAY 2019)
Benefits:
a. Responsiveness.
b. Resource sharing
c. Economy
d. Scalability.
Challenges
e. Dividing activities
f. Balance
g. Data splitting
h. Data dependency
i. Testing and debugging
UNIT III
Virtual memory is commonly implemented by demand paging. In demand paging, the pager
brings only those necessary pages into memory instead of swapping in a wholeprocess.
Thus it avoids reading into memory pages that will not be used anyway, decreasing the
swap time and the amount of physical memory needed.
In certain situations the page tables could become large enough that by paging the page
tables, one could simplify the memory allocation problem (by ensuring that everything is
allocated as fixed-size pages as opposed to variable-sized chunks) and also enable the
swapping of portions of page table that are not currently used.
226.Compare paging with segmentation with respect to the amount of memory required
by the address translation structures in order to convert virtual addresses to physical
addresses. [An]
Paging requires more memory overhead to maintain the translation structures. Segmentation
requires just two registers per segment: one to maintain the base of the segment and the other to
maintain the extent of the segment. Paging on the other hand requires one entry per page, and
this entry provides the physical address in which the page is located.
226. What do you mean by thrashing? (APR/MAY 2015) [R] (APR/MAY 2019)
Thrashing is the coincidence of high page traffic and low CPU utilization.
227.How do you limit the effects of thrashing? [An]
To limit the effect of thrashing we can use local replacement algorithm. With Local
replacement algorithm, if the process starts thrashing, it cannot steal frames from
another process and cause the latter to thrash as well. The problem is not entirely solved.
Thus the effective access time will increase even for the process that is not thrashing.
227.What do mean by page fault? [R]
Page fault is the situation in which the page is not available whenever a processorneeds to
execute it.
228.Differentiate between Global and Local page replacement algorithms. [An]
In demand paging, a page is not loaded into main memory until it is needed. In puredemand
paging, even a single page is not loaded into memory initially. Hence pure demandpaging
causes a page fault.
232. Define Copy-on-write. [R]
Copy-on-write finds its main use in virtual memory operating systems; when a process
creates a copy of itself, the pages in memory that might be modified by either the process
or its copy are marked copy-on-write.
233. Define swapping.
A process needs to be in memory to be executed. However a process can be swapped
temporarily out of memory to a backing store and then brought back into memory for
continued execution. This process is called swapping.
234. What are the common strategies to select a free hole from a set of available holes?
The most common strategies are
The Global Descriptor Table or GDT is a data structure used by Intel x86-family
processors starting with the 80286 in order to define the characteristics of the various
memory areas used during program execution, including the base address, the size and
access privileges like executability and writability. These memory areas are called
segments.
The Local Descriptor Table (LDT) is a memory table used in the x86 architecture in
protected mode and contains memory segment descriptors: start in linear memory, size,
executability, writability, access privilege, actual presence in memory, etc.
a. The LDT is supposed to contain memory segments which are private to a specific
program, while the GDT is supposed to contain global segments.
b. The x86 processors contain facilities for automatically switching the current LDT
on specific machine events, but no facilities for automatically switching the
GDT.
c. The LDT is the sibling of the Global Descriptor Table (GDT) and defines up to
8192 memory segments accessible to programs –
d. Unlike the GDT, the zeroth entry is a valid entry, and can be used like any other
LDT entry.
e. Unlike the GDT, the LDT cannot be used to store certain system entries: TSSs or
LDTs.
245. Define demand paging in memory management. What are the steps required to
handle a page fault in demand paging. (Nov/Dec 2015) [R]
A demand paging system is quite similar to a paging system with swapping where
processes reside in secondary memory and pages are loaded only on demand, not
in advance. When a context switch occurs, the operating system does not copy any
of the old program‘s pages out to the disk or any of the new program‘s pages into
the main memoryInstead, it just begins executing the new program after loading
the first page and fetches that program‘s pages as they are referenced. While
executing a program, if the program references a page which is not available in the
main memory because it was swapped out a little ago, the processor treats this
invalid memory reference as a page fault and transferscontrol from the program to
the operating system to demand the page back into the memory.
246. How does the system detect thrashing? (May/Jun 2016) [An]
Thrashing is caused by under allocation of the minimum number of pages required
by a process, forcing it to continuously page fault. The system can detect thrashing
by evaluating the level of CPU utilization as compared to the level of
multiprogramming. It can be eliminated by reducing the level of
multiprogramming.
247. Name two differences between logical and physical addresses. (May/Jun 2016) [R]
A logical address does not refer to an actual existing address; rather, it refers to an
abstract address in an abstract address space. Contrast this with a physical address
that refers to an actual physical address in memory. A logical address is generated by the
CPUand is translated into a physical address by the memory management unit(MMU).
Therefore, physical addresses are generated by the MMU.
248. Will optimal page replacement algorithm suffer from Belady‟s anamaly?
Justify your answer (APR/MAY 2017)[An]
In computer storage, Belady‘s anomaly is the phenomenon in which increasing the number
of page frames results in an increase in the number of page faults for certain memory access
patterns. This phenomenon is commonly experienced when using the first-in first-out
(FIFO) page replacement algorithm.
249. Write about swapping. Let us assume the user process is of size 1MB and the
backingstore is a standard hard disk with a transfer rate of 5MBPS. Calculate the
transfer rate.
In this algorithm, we keep the counter of the number of reference that have beenmade to
each page. In this 2 schemes are used :-Least Frequency Used (LFU) Page Replacement
AlgorithmIt requires that the page with smallest count to be replaced.
Most Frequency (MFU) Used Page Replacement Algorithm: It is based on the
argument that the page with the smallest count was probably just brought in and has yet to
be used.
254. Consider the following segmentation table.
What are the physical addresses for the logical addresses 3400 and 0110?(APR/MAY
2019)
a. illegal reference; traps to operating system
b.2300+0110 = 2410
255. What is thrashing? and how to resolve this problem? (APR/MAY 2019)
In a virtual storage system (an operating system that manages its logical storage ormemory
in units called pages), thrashing is a condition in which excessive paging operations are
taking place. A system that is thrashing can be perceived as either a very slow system or one
that has come to a halt.One of the recommended ways to eliminate thrashing is to add more
memory to main memory. Another way of resolving the issue of thrashing is by adjusting
the size of the swap file.
UNIT IV
c. Name
d. Type
e. Location
f. Size
g. Protection
h. Time
i. Date
j. User identification
258. What are the various file operations? (NOV/DEC 2012, APRIL/MAY 2015) [R]
a. The six basic file operations are:
b. Creating a file
c. Writing a file
d. Reading a file
e. Repositioning within a file
f. Deleting a file
g. Truncating a file
259. What are all the information‟s associated with an open file? [R]
Several pieces of information are associated with an open file which may be:
a. File pointer
b. File open count
c. Disk location of the file
d. Access rights
260. What are the different accessing methods of a file? (APRIL/MAY 2010) [R]
The different types of accessing a file are:
i. Sequential access: Information in the file is accessed sequentially
ii. Direct access: Information in the file can be accessed without any
particular order.Other access methods: Creating index for the file, indexed
sequential access method (ISAM),etc.
261. What is Directory? [R]
The device directory or simply known as directory records information-such as name,
location, size, and type for all files on that particular partition. The directory can beviewed
as a symbol table that translates file names into their directory entries.
262. What are the operations that can be performed on a directory? [R]
The operations that can be performed on a directory are
a. Search for a file
b. Create a file
c. Delete a file
d. Rename a file
e. List directory
f. Traverse the file system
263. What are the most common schemes for defining the logical
structure ofa directory? [R] (MAY/JUNE 2012)
The most common schemes for defining the logical structure of directory
a. Single-Level Directory
b. Two-level Directory
c. Tree-Structured Directories
d. Acyclic-Graph Directories
e. General Graph Directory
264. Define UFD and MFD. [R]
In the two-level directory structure, each user has her own user file directory (UFD).Each
UFD has a similar structure, but lists only the files of a single user. When a job startsthe
system's master file directory (MFD) is searched. The MFD is indexed by the user name
or account number, and each entry points to the UFD for that user.
265. What is a path name? [R]
A pathname is the path from the root through all subdirectories to a specified file.
In a two-level directory structure a user name and a file name define a path name.
266. What are the various layers of a file system? [R]
The file system is composed of many different levels. Each level in the design uses the
feature of the lower levels to create new features for use by higher levels.
Application programs
b. Linked scheme
c. Multilevel scheme
d. Combined scheme
275. What is garbage collection? (MAY /JUNE 2012 ) [R]
i. Garbage Collection (GC) is a form of automatic memory management. The
garbage collector, or just collector, attempts to reclaim garbage, or memory
occupied by objects that are no longer in use by the program.
276. Mention the objectives of File Management System. (APR/MAY 2010) [R]
i. The system that an operating system or program uses to organize and keep
track offiles. For example, a hierarchical file system is one that uses
directories to organize files into a tree structure.
277. What is the content of a typical file control block? (APR/MAY 2011,
APR/MAY 2010) [R]
File permissions
write)
File owner, group, ACL
File size
i. File Control Block (FCB) is a file system structure in which the state of an
openfile is maintained.
278. What are the two types of system directories? (MAY/JUNE 2012) [R}
Device directory, describing physical properties of files.
i. File directory, giving logical properties of the files.
279. What is meant by polling?(MAY/JUNE 2014) [R]
Polling is the process where the computer waits for an external device to check for its
readiness. The computer does not do anything else than checking the status of the device
Polling is often used with low-level hardware. Example: when a printer connected via a
parallel port the computer waits until the next character has been received by the printer.
These processes can be as minute as only reading 1 Byte. Polling is the continuous (or
frequent) checking by a controlling device or process of other devices, processes, queues,
etc.
280. State any three disadvantages of placing functionality in a device controller,
rather than in the kernel. (MAY/JUNE 2014) [R]
Three advantages:-
a. Three disadvantages:
Bugs are harder to fix - a new firmware version or new hardware is needed
Improving algorithms likewise require a hardware update rather than just kernel or
device driver update
Embedded algorithms could conflict with application‘s use of the device, causing
decreased performance.
281. How free-space is managed using bit vector implementation?[An]
The free-space list is implemented as a bit map or bit vector. Each block is represented
by 1 bit. If the block is free, the bit is 1; if the block is allocated, the bit is 0.
282. List the attributes of a file(MAY/JUNE 2014)[R]
Name, Identifier, Type, Location, Size, Protection, Time, Date and User
authentication.
283. What are the information contained in a boot control block and partition
control block? (MAY/JUNE 2014) [R]
Boot control block:
b. Rotational latency
c. Command processing time
d. Settle time
297. Give the importance of Swap space Management. [R] (NOV/DEC 2012,
APR/MAY2010, NOV/DEC 2010)
Swap-space management: Swap-space management is low- level task of the operating
system. The main goal for the design and implementation of swap space is to provide the
best throughput for the virtual memory system.
Swap-space use: The operating system needs to release sufficient main memory tobring
in a process that is ready to execute. Operating system uses this swap space in variousways.
Paging systems may simply store pages that have been pushed out of main memory.UNIX
operating system allows the use of multiple swap spaces. These swap space are usually put
on separate disks, so the load placed on the I/O system by paging and swappingcan be spread
over the systems I/O devices.
Swap-space location: Swap space can reside in two places:
Separate disk partition
Normal file system
298. Write three basic functions which are provided by the hardware clocks and
timers. (APRIL/MAY 2011) [R]
a. OSTickInit()
b. OSTimeSet()
c. OSTimeGet()
299. What are the advantages of Linked allocation? [R]
The advantages are
a. No external fragmentation.
b. Size of the file does not need to be declared.
300. Define FAT(NOV/DEC 2014) [R]
FAT is a much older file-system format that is understood by many systems besides
Windows, such as the software running on cameras. A disadvantage is that the FAT file
system does not restrict file access to authorized users. The only solution for securing
data with FAT is to run an application to encrypt the data before storing it onthe file
system.
301. What is Relative block number? (NOV/DEC 2014) [R]
Relative block number is an index relative to the beginning of a file. Thus the 1strelative
block of the file is 0, the next is 1, and so on.
302. What is double buffering? (NOV/DEC 2014) [R]
OS can use various kinds of buffering:
Single buffering — OS assigns a system buffer to the user request
Double buffering — process consumes from one buffer while system fills the next
Circular buffers — most useful for burst I/O
303. Draw the diagram for interrupt driven I/O cycle? (NOV/DEC 2014) [Ap]
In the C-Scan all the Processes are Arranged by using Some Circular List. Circular Listis
that in which there is no start and end point of the list means the End of the List is the
Starting Point of the list. In the C-Scan Scheduling the CPU will search for the Process
from Start to end and if an End has Found then this again start from the Starting Process.
308. Why it is important to scale up system –bus and device speeds as CPU speed
increases? (NOV/DEC 2016)[An]
Consider a system which performs 50% I/O and 50% computers. Doubling the CPU
Performance on this system would increase the total system performance by only 50%.
Doubling both system aspects would increase performance by 100%.Generally,it is
important to remove the current system bottleneck and to increase overall system
performance rather than blindly increasing the performance of individual system
components.
309. Suppose that the disk rotates at 7200 rpm. What is the average rotational
latency of the disk drive? (APR/MAY 2017) [E]
a. Average disk access time=average seek time+ average rotational delay +
transfertime + controller overhead.
i.
b. The controller calculates the ECC and finds that the sector is bad. It reports this
finding to the OS.
c. The next time that the system is rebooted ,a special command is run to tell the
SCSI controller to replace the bad sector with a spare.
d. After that, whenever the system requests logical block, the request is translated
into the replacement sector‘s address by the controller.
314. What is the advantage of bit vector approach in free space management ? [R]
(APR/MAY 2018)
Advantages of bit vector approach:
a. Relatively simple
b. Efficient to find the first free blocks or n consecutive free blocks on the disk
315. Write short notes on file system mounting. (APR/MAY 2019)
The mount procedure is straightforward. The operating system is given the name ofthe
device and the mount point—the location within the file structure where the file systemis to
be attached. Some operating systems require that a file system type be provided, while
others inspect the structures of the device and determine the type of filesystem. Typically,
a mount point is an empty directory.
316. What is SSD? (APR/MAY 2019)
The highest level, the operating system may maintain a cache of file-system data inmain
memory. In addition, electronic RAM disks (also known as solid-state disks) may be used
for high-speed storage that is accessed through the file-system interface.
UNIT V
320. Which layer of iOS contains fundamental system services for apps?
The Core Services layer contains the fundamental system services that all applications use,
The Core Services layer provides an abstraction over the services provided in the CoreOS
layer. It provides fundamental access to iOS services and consists of the following
components:
Collections
Address Book
Networking
File Access
SQLite
Core Location
Net Services
Threading
Preferences
URL Utilities