While every effort is taken to avoid errors or omissions in this Publication, any
mistake or omission that may have crept in is not intentional. It may be taken note of
that neither the publisher nor the author will be responsible for any damage or loss of
any kind arising to anyone in any manner on account of such errors and omissions.

Leaser Type Setted by :
Biyani College Printing Department

Operating System Fundamentals

3

Preface

I

am glad to present this book, especially designed to serve the needs of the

students. The book has been written keeping in mind the general weakness in
understanding the fundamental concepts of the topics. The book is self-explanatory and
adopts the “Teach Yourself” style. It is based on question-answer pattern. The language
of book is quite easy and understandable based on scientific approach.
Any further improvement in the contents of the book by making corrections,
omission and inclusion is keen to be achieved based on suggestions from the readers
for which the author shall be obliged.
I acknowledge special thanks to Mr. Rajeev Biyani, Chairman & Dr. Sanjay Biyani,
Director (Acad.) Biyani Group of Colleges, who are the backbones and main concept
provider and also have been constant source of motivation throughout this Endeavour.
They played an active role in coordinating the various stages of this Endeavour and
spearheaded the publishing work.
I look forward to receiving valuable suggestions from professors of various
educational institutions, other faculty members and students for improvement of the
quality of the book. The reader may feel free to send in their comments and suggestions
to the under mentioned address.

Ans.: Application Software and System Software : The Application Software is a
software developed to provide solutions to a particular application. These
softwares are usually developed for a specific area, they cannot be used in other
application areas.
For example - Tally for Accounting, MS-Word for Word Processing etc.
While the System Software helps in controlling the internal processing of the
computer, these softwares provide a general programming environment in
which programmers can write applications to suit their needs.
Examples of System Software are - Operating Systems, Language Translators etc.
Q.2

What do you mean by Operating System?

Ans.: Operating System : An Operating System is a program that acts as an
intermediary between a user of a computer and the computer hardware.
The purpose of an Operating System is to provide an environment in which a
user can execute program. An Operating System is an important part of almost
every Computer System.
It is basically a control program that controls the execution of user programs to
prevent errors and improper use of the computer.
Q.3

What is the necessity of an Operating System?

Ans.: Necessity of an Operating System : Computer System performs all the tasks
with the help of hardware and software jointly. To use computer in different

10

application areas, a user has to write proper software. A user who is writing a
program or a software need to know about details of hardware, which is a very
difficult task. Therefore there should be an intermediate component between
user and computer hardware.
The execution of all commands given by the user and all instructions given by
various softwares are the responsibility of Operating System.
Operating System provides various services like program execution, I/O
operations, resource allocation etc. for convenience of user or efficient operations
of system itself.
Q.4

Write in brief about the Evolution of Operating System.

Ans.: Evolution of Operating System : The evolution of various types of operating
systems can be briefly described as follows :
(1)

Batch System : This type of Operating System was used in the earlier age.
To speed up processing, jobs with similar needs were batched together
and were run through the computer as a group. The definitive feature of a
batch system is the lack of interaction between the user and the job while
that job is executing. In this execution environment, the CPU is often idle.

(2)

Multiprogramming System : In this type of Operating System, more than
one programmes will reside into main memory. The Operating System
picks and begins to execute one of the jobs in the memory. Eventually, the
job may have to wait for some task, the Operating System simply switches
to and executes another job. When the first job finishes waiting and gets
the CPU back. As long as there is always some job to execute, the CPU
will never be idle.

(3)

Time Sharing System : A Time-Shared Operating System allows the
many users to share the computer simultaneously. A time-shared
Operating System uses CPU scheduling and multiprogramming to
provide each user with a small portion of a time-shared computer.

(4)

Real Time Operating System : Real Time Operating System is a special
purpose Operating System, used when there are rigid time requirements
on the operation of a processor or the flow of data.

Operating System Fundamentals

Q.5

11

(5)

Process Control System : Process Controls are dedicated Systems. They
are dedicated to single application. Thus there is no need to manage
sharing among concurrent application programs.

(6)

Distributed System : A Distributed System is an interconnection of two or
more nodes, but the processors do not share memory. These Systems are
also called as loosely Coupled Systems.

Explain the various factors which should keep in mind while designing the
Operating System.

Ans.: When we are designing an Operating System, we need to keep in mind certain
important factors. The few important factors are :
(i)

Performance

(ii)

Protection and Security

(iii)

Correctness

(iv)

Maintainability

(v)

Application integration

(vi)

Portability

(vii)

Interoperability

□□□

12

Multiple choice Question
Q1. The operating system which the IBM –PC uses:
A. CP/M
B. MS-DOS
C. UNIX
D. AT-DOS
Q2.Most operating system are designed to run with a specific:
A. Type of processor
B. Manufacturer’s printer
C. Brand of computer
D. Style of keyboard
Q3.A technique that can be used when a very long program exceeds the storages
capacity of memory is called:
A. Windowing
B. Time sharing
C. Linkage editing
D. Virtual memory
Q4.An operating system designed for uase on both PC’s at home andon serversin
business is:
A. Windows XP
B. Windows ME
C. Windows NT
D. Windows CE

Ans.: Process Definition : In general, a process is a program in execution. The
execution of a process progresses in a sequential fashion. Thus a process is an
active entity with a program counter, specifying the next instruction to be
executed and a set of associated resources.
Q.2

Explain the different States of Process with example.
OR
Describe about the Life Cycle of a Process.

Ans.: Process States : The various stages through which a process passes is called its
Life Cycle and this Life Cycle of a process can be divided in to several stages
called as “Process States”. When a process starts execution, it goes through one
state to another state. Each process may be in one of the following states :

Q.3

(i)

New

(ii)

Ready

(iv)

Waiting

(v)

Terminated

(iii)

Running

Explain the Process Control Block (PCB) with diagram.

Ans.: Process Control Block (PCB) : To control the various processes the Operating
System maintains a table called the Process Table. The Process Table contains
one entry per process. These entries are referred to as “Process Control Block”.
It contains many pieces of information related with a specific process including

Ans.: Process Address Space : When we write programs, very frequently we use
defined libraries (programs). When we execute a program then an executable
program is prepared by linking the modules. The procedure for linking the
modules are defined in a linear address space in which all parameters of
computation are referred.
Thus Address Space is a set of locations used by process to reference. The
Address Space defines all logical entities used by process and specifies addresses
by which they are referred.
Q.5

What do you understand by Process Hierarchy?

Ans.: Process Hierarchy : Operating System needs some way to create and kill
processes. When a process is created, it creates another process which in turn
creates some more processes and so on. Thus it forms a Process Hierarchy or
Process Tree. In this hierarchy a child process can have only one parent process
where as a parent process can have multiple child processes.

Ans.: CPU Scheduling : CPU Scheduling is the basis of multi Programmed Operating
System. By switching the CPU among the processes, the operating system can
make the computer more productive. The main objective of Scheduling is to
increase CPU utilization and higher throughput.
Q.2

What is the difference between CPU Bound and I/O Bound Processes?

Ans.: I/O Bound Processes : An I/O Bound Process is one that spends more of its time
in doing I/O then it spends on doing computation.
CPU bound Processes : CPU Bound Processes needs very little I/O, but requires
heavy computation.
Q.3

What are the different types of Scheduling Queues?

Ans.: The Scheduling Queues in the Systems are :
(1)

Job Queue : As processes enters in the System, they are put into a job
queue.

(2)

Ready Queue : The processes that are residing in the main memory and
are ready and waiting to execute are kept in the ready queue.

Ans : Non-Preemptive Scheduling Mechanism : A Non-Preemptive Scheduling
Mechanism selects a process to run and lets it run, until it blocks or until it
voluntarily releases the CPU.
Preemptive Scheduling Mechanism : In this category, suspension or preemption
is allowed based on priority.
Q.7

Explain various Non-preemptive Scheduling Mechanisms.

Ans.: Non-Preemptive Scheduling Mechanisms are of four types :-

20

Q.8

(1)

First Come First Served (FCFS) Scheduling : With this scheme, the
process that requests the CPU first is allocated the CPU first.

(2)

Shortest-Job First (SJF) Scheduling : In this scheme, job requiring the
minimal CPU time is selected first for CPU allocation.

(3)

Priority Scheduling : In this scheme a priority is associated with each
process and the CPU is allocated to the process with the highest priority.

(4)

Deadline Scheduling : With this scheduling algorithm the process with
earliest deadline is given the highest priority for execution.

Explain various Preemptive Scheduling Mechanisms.

Ans.: Preemptive Scheduling mechanisms are of three types :(1)

Round-Robin Scheduling : In this algorithm, a small time slice is
assigned to each process. The CPU scheduler goes around the ready
queue, allocating the CPU to each process for a time interval of one time
quantum.

(2)

Two Queue Scheduling : In this approach, the processes are classified
into two different groups. One queue is allocated to CPU bound processes
and other is allocated to I/O bound processes.

(3)

Multilevel Queue Scheduling :
A Multilevel Queue Scheduling
Algorithm partition the ready queue in to separate queues and each queue
has its own scheduling algorithms.

Q2. Which of the following is not an example of Operating System?
a. Windows 95
b. DOS
c. UNIX
d. MS Word
Q3. Operating System is required to managea. Hardware
b. various resources
c. memory
d. All
Q4. Factors important for designing of Operating systems are
a. Maintainability
b. Portability
c. security
d. All above
Q5. Which one is a sequential storage device::
A. Hard disk
B. Magnetic disk
C. Magnetic tape
D. None of the above
Q6. System in which different part of a single program can run concurrently is:
A. Real time
B. Multitasking

21

22

C. Multithreading
D. None of the above
Q7. Which of the following is not an operating system?
A. WINDOWS
B. UNIX
C. PASCAL
D. MS-DOS
Q8. Which of the following is also known as “Light weight process”?
A. Function
B. Application module
C. Kernel
D. Thread
Q9. The………. Is a computer program that runs when you first start the computer;
A. FAT
B. Record
C. Boot record
D. Root directory
Q10. Thrashing is related to :
A. Cache Memory
B. Main Memory
C. Secondary memory
D. Virtual memory

Operating System Fundamentals

23

CHAPTER-4
C

Basic Synchronization Principles
Q.1

Explain the concept of Synchronization.

Ans.: Synchronization : The concept of Synchronization is concerned with cooperating processes that share some resources. Co-operating processes must
synchronize with each other when they use shared resources. Thus we can view
the Synchronization as a set of constraints on the ordering of events.
Q.2

What do you mean by Co-operating Processes?

Ans.: Co-operating Processes : The concurrent processes executing in the Operating
System may be either Independent Processes or Co-operating Processes.
A process is Co-operating if it can affect or is affected by the other processes
executing in the System.
That means any process that shares data with other processes is a Co-operating
Process.
Q.3

Write about Semaphores and its usages.

Ans.: Semaphores : A Semaphore is a protected variable whose value can be accessed
and altered only by operations P and V.
A Semaphore Mechanism basically consists of the two primitive operations
SIGNAL and WAIT.

24

The Semaphore variable can assume only positive integer value. The integer
value of the Semaphore in the wait and signal operations must be executed
indivisible.
That is, when one process modifies the Semaphore value, no other process can
simultaneously modify that same Semaphore value.
Usage :

Q.4

(i)

Semaphores can be used to deal with n process critical section problem.
As the n processes shares the semaphores, mutex (standing for mutual
exclusion), is initialized to 1.

(ii)

Semaphores can also be used to solve various synchronization problems.

What do you mean by AND Synchronization?

Ans.: AND Synchronization : In case of AND Synchronization, a single abstract P
operation could not be used to obtain all required resources at once or none of
them at all. The operation would block the calling process whenever any of the
resource could not be obtained.
Q.5

Explain the concept of Inter-Process Communication.

Ans.: Inter-Process Communication : Cooperating processes can communicate in a
shared-memory environment. Cooperating processes communicate with each
other via an Inter-Process-Communication (IPC) facility. IPC provides a
mechanism to allow processes to communicate and to synchronize their actions.
Inter-Process Communication is best provided by a Message System. Message
System can be defined in many different ways. An IPC facility provides at least
the two operations - send(message) and receive(message).
Q.6

What is the difference
Communication?

between

Direct

and

Indirect

Inter-Process

Ans.: Direct Communication : In the Direct Communication, each process that wants
to communicate must explicitly name the recipient or sender of the
communication. In this scheme, the send and receive primitives are defined as
follows :

Operating System Fundamentals

25

Send (P, message) - Send a message to process P.
Receive (Q, message) - Receive a message from process Q.
Indirect Communication : With Indirect Communication, the messages are sent
to and received from mailboxes. A mailbox can be viewed abstractly as, an object
into which messages can be placed by processes and from which messages can
be removed. The send and receive primitives are defined as follows :
Send (A, message) - Send a message to mailbox A.
Received (A, message) - Receive a message from mailbox A.

Ans.: Deadlock : In a multiprogramming environment, several processes may compete
for a finite number of resources. A process requests resources; if the resources are
not available at that time, the process enters a wait state. It may happen that
waiting processes will never again change state, because the resources they have
requested are held by other waiting processes. Then this is called Deadlock
Situation.
Q.2

What are the necessary conditions to Produce a Deadlock?

Ans.: Necessary Conditions for Deadlock : A Deadlock Situation can arise if the
following four conditions hold simultaneously in a system :
(1)

Mutual exclusion : At least one resource must be held in a non-sharable
mode; that is, only one process at a time can use the resource.

(2)

Hold and wait : There must exist a process that is holding at least one
resource and is waiting to acquire additional resources that are currently
being held by other processes.

(3)

No preemption : Resources cannot be preempted; that is, a resource can
be released only voluntarily by the process holding it, after that process
has completed its task.

(4)

Circular wait : There must exist a set {P0, P1, . . . , Pn} of waiting processes
such that P0 is waiting for a resource that is held by P1, P1 is waiting for a

30

resource that is held by P2, . . ., Pn-1 is waiting for a resource that is held by
Pn, and Pn is waiting for a resource that is held by P0.
Q.3

What are the methods of Handling a Deadlock?

Ans.: Methods of Handling Deadlocks : There are three different methods for dealing
with the Deadlock problem :
We can use a protocol to ensure that the system will never enter a
Deadlock state.
We can allow the system to enter a Deadlock state and then recover.
We can ignore the problem all together, and pretend that Deadlocks never
occur in the System.
Q.4

Write the methods to Prevent a Deadlock Situation.

Ans.: Methods to Prevent a Deadlock Situation : For a Deadlock to occur, each of the
four necessary-conditions must hold. By ensuring that at least one of these
conditions cannot hold, we can prevent the occurrence of a Deadlock.
(1)

Mutual Exclusion : The mutual-exclusion condition must hold for nonsharable resources. Sharable resources, on the other hand, do not require
mutually exclusive access, and thus cannot be involved in a Deadlock.

(2)

Hold and Wait : Whenever a process requests a resource, it does not hold
any other resource. An alternative protocol allows a process to request
resources only when the process has none.

(3)

No Preemption : If a process that is holding some resources requests
another resource that cannot be immediately allocated to it, then all
resources currently being held are released implicitly. Then the preempted
resources are added to the list of resources for which the process is
waiting.

(4)

Circular Wait : Circular-Wait condition never holds to impose a total
ordering of all resource types, and to require that each process requests
resources in an increasing order of enumeration.

Operating System Fundamentals

Q.5

31

How can a Deadlock Situation be avoided?

Ans.: Deadlock Avoidance : Avoiding Deadlocks is to require additional information
about how resources are to be requested. A Deadlock-Avoidance algorithm
dynamically examines the resource-allocation state to ensure that there can never
be a circular wait condition. The resource allocation state is defined by the
number of available and allocated resources, and the maximum demands of the
processes. There are various methods used for the purpose of Deadlock
Avoidance :

Q.6

(1)

Safe State : A state is safe if the System can allocate resources to each
process (up to its maximum) in some order and still avoid a Deadlock.
More formally, a System is in a safe state only if there exists a safe
sequence. If no such sequence exists, then the System state is said to be
unsafe.

(2)

Resource-Allocation Graph Algorithm : Suppose that process
Pi requests resource Rj. The request can be granted only
if converting the request edge Pi
Rj to an assignment edge
Rj
Pi does not result in the formation of a cycle in the ResourceAllocation Graph.

(3)

Banker's Algorithm : This Resource-Allocation Graph Algorithm is
applicable to a Resource-Allocation System with multiple instances of
each resource type. This algorithm is commonly known as the Banker's
Algorithm.

Write the methods for Detecting a Deadlock.

Ans.: Deadlock Detection : If a system does not employ either a Deadlock-Prevention
or a Deadlock Avoidance Algorithm, then a Deadlock Situation may occur. In
this environment An algorithm that examines the state of the system to determine whether a
Deadlock has occurred.
An algorithm to recover from the Deadlock.
Single Instance of Each Resource Type : If all resources have only a single
instance, then we can define a Deadlock Detection Algorithm that uses a variant
of the Resource-Allocation Graph, called a Wait-For Graph. We obtain this graph

32

from the Resource-Allocation Graph by removing the nodes of type resource and
collapsing the appropriate edges.
Several Instances of a Resource Type : The Wait-For Graph Scheme is not
applicable to a Resource-Allocation System with multiple instances of each
resource type.
The algorithms used are :
Available
Allocation
Request
Q.7

What are the methods of recovery from deadlock?

Ans.: Recovery from Deadlock : When a Detection Algorithm determines that a
Deadlock exists, several alternatives exist for recovery.
One possibility is to inform the operator that a Deadlock has occurred, and to let
the operator deal with the Deadlock manually.
The other possibility is to let the System recover from the Deadlock
automatically.
There are two options for breaking a Deadlock. One solution is simply to abort
one or more processes to break the circular wait. The second option is to
preempt some resources from one or more of the Deadlocked processes.

□□□

Operating System Fundamentals

33

Multiple Choice Question
Q1. The major security threats are
A. Unauthorized use of service
B. Unauthorized disclosure of information
C. Unauthorized alteration of information
D. All of the above
Q2. Remote Procedure Call (RPC) is
A. Communication in centralized system
B. Communication in distributed system
C. Both (a) and (b) both
D. None of the above
Q3. A file can have following states:A. closed
B. opened
C. achieved
D. All above

Q4. The operation performed on directory is
A. creation
B. deletion
C. open
D. all
Q5. DBMS is used because of
A. consistency
B. data independency
C. controlled redundancy
D. all
Q6.Multimedia application can involves
a. audio
b. video
c. text
Q7. The advantage of distributed system isa. more computing power
b. Reliability
c. Resource sharing
d. All

d. all

34

Q8. RPC stands for
a. Remote Programming center
c. Right Program Call

b. Remote Procedure Call
d. None

Q9.In the batch processing system the task are submitted in:
A. one by one
B. similar task in batches
C. different task in batches
D. none of the above
Q10.Which type of file organization aresupported by magnetic tape:
A. Random file
B. Contiguous sequential file
C. Indexed sequential file
D. All of the above

Operating System Fundamentals

35

CHAPTER-6
C

Device Management
Q.1

Explain the concept of Device Management.

Ans.: Device Management : One of the main function of Operating System is to
control all the I/O (Input/Output) devices of computer.
The I/O System or Device Manager is a part of the Operating System which is
related with management of I/O devices.
The I/O System of an Operating System is responsible for the task of attending
to the individual requirements of I/O devices and providing for their efficient
and reliable operations.
In order to manage the I/O devices, the Operating System creates a Device
Status Table. This table contains the information such as which device is free
and which one is busy.
Q.2

Define General Device Characteristics.

Ans.: General Device Characteristics : Generally, most I/O devices share two
important characteristics, that largely define the I/O problems, which are
asynchronous operations and the speed gap.
The I/O devices operate asynchronously from the processor because the
processor, I/O data arrival and transfer time are generally unpredictable.

36

The speed gap incompatibility between any two I/O devices can also arise
because of the difference in the electrical characteristics of two devices. The
timing difference between devices may also arise because of the difference in
data transfer speed.
Q.3

Define various Schemes to Transfer Data between CPU and I/O Devices.

Ans.: Data Transfer Schemes between CPU and I/O Devices : A computer having
multiple devices may have time incompatibility problem. Hence some schemes
are used for transferring data between CPU and I/O devices.
These schemes fall into two categories :

Q.4

(i)

Programmed Data Transfer (PDT)

(ii)

Direct Memory Access Transfer (DMA)

Differentiate between Synchronous and Asynchronous Data Transfer.

Ans.: Synchronous Data Transfer :
It is used when the I/O devices and
CPU speed matches. Whenever data is to be collected or delivered to
the device, the user program issue suitable instructions addressing the device. At
the end of the execution of this instruction the transfer get completed.
Asynchronous Data Transfer : When the speed of I/O devices and CPU do not
match then generally Asynchronous Data Transfer method is used. In this
method, CPU issues “get ready” instruction to the device. Then the CPU keeps
waiting until the device is ready. Once the device is ready, CPU issues data
transfer instruction immediately. To see whether the device is ready, CPU needs
to test signals. Thus this is also called as handshaking scheme.
Q.5

What is the use of Device Controller?

Ans.: Device Controller : Each device uses a Device Controller to connect devices to
computer data and address bus. The controller provides a set of physical

Operating System Fundamentals

37

components that CPU instruction can manipulate to perform I/O operations.
Generally Operating System deals with the Controller and not the Device.
Q.6

What is the use of Device Driver?

Ans.: Device drivers : Each I/O device attached to a computer needs some device
specific code for controlling it. This code is called the Device Driver. It is
generally written by the device’s manufacturer and delivered along with the
device. Each Device Driver normally handles one device type or one class of
closely related devices.
Q.7

What is the role of Interrupt in Computer?

Ans.: Interrupts : Interrupt is the ability of the hardware to stop the currently running
program and turn the system’s attention to something else. If a block of data is to
be read from an input device it may take a lot of time between two bytes of data
to be available to processor. During this time interval, microprocessor can do
some other work. The I/O device must then inform the processor, each time that
it is ready with the new bytes of data, rather than the microprocessor waiting for
the data to appear. The microprocessor then discontinues whatever work it is
doing and attends to the required I/O device. It then once again goes back to the
place where it left and continues the original processing.
Q.8

What do you mean by Direct I/O and Memory Mapped I/O?

Ans.: Direct I/O with Polling : Direct I/O refers to the method of doing I/O whereby
the CPU is responsible for determining when the I/O operation has completed
and then for transferring the data between the primary memory and the device
controller data registers.
Memory-Mapped I/O : An I/O device is managed by having software
read/write information from/to the controller’s registers. Each controller has a
few registers that are used for communicating with the CPU. Each control

38

register is assigned a unique memory address to which no memory is assigned.
This system is called Memory-Mapped I/O. In Memory-Mapped System, devices
are associated with logical primary memory addressees rather than having a
specialized device address. Each component of the device that is referenced
using software is assigned a normal memory address.
Q.9

What do you mean by Buffering?

Ans.: Buffering: - A buffer is a memory area that stores data while they are
transferred between two devices or between a device and an application. It is a
technique, which is used in the operating system to bridge the gap between the
slow I/O devices and the fast processor. Buffering attempts to keep both CPU
and I/O devices busy all time.
Q.10 What is DMA? Explain.
Ans.: Direct Memory Access (DMA) : In DMA the controllers are able to read and
write information directly from/to primary memory with no CPU intervention.
When the processor wishes to read or write a block of data, it issues a command
to the DMA module. The DMA module transfers the entire block of data, one
word at a time, directly to or from memory, without going through the
processor. When the transfer is complete, the DMA module sends an interrupt
signal to the processor. Thus, the processor is involved only at the beginning and
end of the transfer.
Q.11 Explain various Disk Scheduling Algorithms in brief.
OR
Explain various I/O Optimization Techniques.
Ans.: I/O optimization Techniques : The various Disk Scheduling Algorithms in order
to minimize total service time and wait time are as follows :

Operating System Fundamentals

39

(1)

First-In-First-Served : The simplest form of scheduling is First-In-FirstOut (FIFS) scheduling, which processes items from the queue in sequential
order .

(2)

Shortest Seek Time First : The SSTF policy is to select the disk I/O
request that requires the least movement of the disk arm from its current
position.

(3)

Scan : In this scheme, the read/write keeps moving from one end to
another end and when it reaches to the other end, the direction of head
movement is reserved and servicing continues.

(4)

C-Scan : The C-SCAN policy restricts scanning to one direction only.
Thus, when the last track has been visited in one direction, the arm is
returned to the opposite end of the disk and the scan begins again.

Ans.: Logical versus Physical Address Space : An address generated by the CPU is
commonly referred to as a Logical Address, whereas an address seen by the
memory unit is commonly referred to as a Physical Address.
The set of all Logical Addresses generated by a program is referred to as a
Logical Address Space; the set of all Physical Addresses corresponding to these
Logical Addresses is referred to as a Physical Address Space.
The user program deals with Logical Addresses. The Memory-Mapping
Hardware converts Logical Addresses into Physical Addresses.
Q.2

Explain various Memory Allocation Techniques in brief.

Ans.: Memory Allocation Techniques : There are various techniques used for Memory
Allocation such as :
(1)

Single-Program Partition Technique : In single user systems, the memory
is usually divided into two partitions, one for the resident operating
system, and the other for the user processes. The Operating System is
normally residing in low memory, and the user processes are executing in
high memory.

(2)

Fixed-Sized Partition Allocation : One of the simplest schemes for
memory allocation is to divide memory into a number of fixed-sized

Operating System Fundamentals

43

partitions. Each partition may contain exactly one process. When a
partition is free, a process is selected from the input queue and is loaded
into the free partition. When the process terminates, the partition becomes
available for another process.
The operating system keeps a table indicating which parts of memory are
available and which are occupied.
(3)

Q.3

Variable Sized Partition Technique : This technique is more efficient
then fixed-sized partition technique. In this technique, when a job is
loaded into memory, it is allocated the exact memory space required by it
and no more. Hence the partition is created dynamically.

Explain the difference between Internal and External Fragmentation.

Ans.: External and Internal Fragmentation : As processes are loaded and removed
from memory, the free memory space is broken into little pieces. External
Fragmentation exists when enough memory space exists to satisfy a request, but
it is not contiguous; storage is fragmented into a large number of small holes.
Internal Fragmentation means memory that is internal to partition, but is not
being used.
Q.4

What do you mean by Swapping.

Ans.: Swapping : In case of Round Robin CPU-Scheduling or Priority-Based
Scheduling it is required that a process can be swapped temporarily out of
memory to a backing store, and then brought back into memory for continued
execution. This technique is called Swapping. A process is swapped out will be
swapped back into the same memory space that it occupies previously.
Swapping requires a backing store. The backing store is commonly a fast disk.
Q.5

Explain the concept of Virtual Memory.

44

Ans.: Virtual Memory : Virtual Memory is a technique that allows the execution of
process that may not be completely in memory. The main visible advantage of
this scheme is that programs can be larger than physical memory.
Virtual Memory is the separation of user logical memory from physical memory.
This separation allows an extremely large virtual memory to be provided for
Programmers when only a smaller physical memory is available.
Q.6

Explain the Paging Technique in brief.

Ans.: Paging : External Fragmentation is avoided by using Paging. In this physical
memory is broken into blocks of the same size called Pages. When a process is to
be executed, its pages are loaded into any available memory frames.
Every address generated by the CPU is divided into any two parts : a Page
Number (P) and a Page Offset (D).
The Page Number is used as an index into a page table. The Page Table contains
the base address of each page in physical memory. The page size like is defined
by the hardware. Paging is a form of dynamic relocation. Every logical address is
bound by the Paging hardware to some physical address.
Q.7

What do you understand by Demand Paging?

Ans.: Demand Paging : A Demand Paging is similar to a Paging System with
Swapping. When we want to execute a process, we swap it into memory. Rather
than swapping the entire process into memory. When a process is to be swapped
in, the pager guesses which pages will be used before the process is swapped out
again instead of swapping in a whole process; the pager brings only those
necessary pages into memory. Thus, it avoids reading into memory pages that
will not be used in anyway, decreasing the swap time and the amount of
physical memory needed.
Q.8

What are the various methods of Page Replacement?

Ans.: Page Replacement Algorithm : There are many different Page Replacement
Algorithms. Some are :

Operating System Fundamentals

45

(1)

FIFO Algorithm : The Simplest Page-Replacement Algorithm is a FIFO
Algorithm. A FIFO Replacement Algorithm associates with each page the
time when that page was brought into memory. When a page must be
replaced, the oldest page is chosen.

(2)

Optimal Algorithm : An Optimal Page-Replacement Algorithm has the
lowest page-fault rate of all Algorithms. It is simply replacing the page
that will not be used for the longest period of time.

(3)

LRU Algorithm : The LRU replaces the page that has not been used for
the longest period of time. LRU replacement associates with each page
the time of that page's last use. When a page must be replaced, LRU
chooses that page that has not been used for the longest period of time.

□□□

46

Multiple Choice Questions
Q1. To bring program again from disk into the main memory is called:
A. Swapping in
B. Swapping out
C. A and B both
D. None of the above

Q5. Default file system of Windows 2003:
A. Ext3
B. NTFS
C. CDFS
D. RAID
Q6.Which of the following is a non-preemptive CPU scheduling policy:
A. Shortest job first
B. First come first served
C. Shortest remaining time
D. Both A & B
Q7. Banker’s algorithm is used for deadlock:
A. Avoidance
B. Detection
C. Prevention
D. Banking transaction on computer
Q8.Which of the following is a place replacement strategy?
A. FIFO
B. Second Chance
C. Clock Page
D. None of the above

47

48

Q9. In paging, can the total address spaceexceed the size of the physical memory?
A. Yes
B. No
C. Sometimes
D. Depends on process
Q10. Interleaved execution of more than one programs at a time is known as:
A. Multiprogramming
B. Multitasking
C. Multiprocessing
D. GUI

Ans.: Low Level Files : A File is a named collection of related information that is
stored on the secondary storage. The logical extension of storage blocks starts at
byte stream files. Each byte in the stream is addressable and has an index. These
indexes are used to make reference to byte in the file.
Structured files : The Structured Files are represented on the storage media as a
collection of blocks.
Database Management System : In Database Environment, common data are
available and used by multiple users. The Software that is used to manage the
data base is called as DBMS.
Multimedia Storage : The Multimedia Documents are highly Structured Files,
which contain information in the form of characters, numbers, graphics, pictures,
audio etc.
Q.2

Define the Strategies of Contiguous, Linked and Indexed Allocation in File
System.

Ans.: (i)

Contiguous Allocation : The Contiguous Allocation method requires each
file to occupy a set of contiguous blocks on the disk. Disk addresses define
a linear ordering on the disk. The directory entry for each file indicates the

Operating System Fundamentals

51

address of the starting block and the length of the area allocated for this
file. Accessing a file that has been allocated contiguously is easy.

Q.3

(ii)

Linked Allocation : With Link Allocation, each file is a linked list of disk
blocks; the disk blocks may be scattered anywhere on the disk and any
free block on the free-space list can be used to satisfy a request ,there is no
need to declare the size of a file when that file is created. A file can
continue to grow as long as there are free blocks.

(iii)

Indexed Allocation : The problem with Linked Allocation is that, the
pointers to the blocks are scattered with the blocks themselves all over the
disk and need to be retrieved in order, while in Indexed Allocation all the
pointers bring together into one location: the index block. These types of
allocations support direct access.

What is the use of Directories?

Ans.: Directories : The Directories are treated as files which keep track of all other files.
The Directory contain information about the files such as location and owner of
the file etc. the Directory is itself a file, owned by the Operating System and
accessible by various file management routines.
Q.4

Explain the various types of Directory Systems.

Ans- Type of directories : Directories can be organized in following ways :
(1)

Single-Level Directory : In a Single-Level Directory System, all the files
are placed in one directory. This is a very common Single-User OS. Even
with a single-user, as the number of files increases, it becomes difficult to
remember the names of all the files in order to create only files with
unique names.

(2)

Two-Level Directory : In the Two-Level Directory System, the system
maintains a master block that has one entry for each user. This master
block contains the addresses of the directory of the users.

52

(3)

Tree-Structured Directories : In the Tree-Structured Directories, the
Directories themselves are Files. This leads to the possibility of having
sub-directories that can contain files and sub-subdirectories.
(i)

Acyclic-Graph Directories : The Acyclic Directory Structure is an
extension of the Tree-Structured Directory Structure. In the
Acyclic Structure, a directory or file under directory can be owned
by several users. Thus an Acyclic Graph Structure allows
directories to have shared subdirectories and files.

(ii)

Q.5

General Graph Directory : One problem with using an Acyclic
Graph Structure is ensuring that there is no cycle. However to
avoid traversing shared sectors of an Acyclic Graph twice, we can
allow cycles to exist. If cycles are allowed to exist in the directory,
we generally, want to avoid searching any component twice, for
reason of correctness and performance.

Write the methods of sharing information across the network.

Ans.: Sharing Information Across the Network : The most common application of
network is to allow process on one machine to access main memory or secondary
memory on another machine. This facility needs to be provided by Operating
System. To read from/write to primary memory and secondary memory of a
remote machine connected in a network we can use Implicit File Copying
System. Similarly, information can be shared among machines by explicitly
copying files from one machine to another machine across the network.
Q.6

Write a note on Remote Disk System.

Ans.: Remote Disk System : In the past the hard disks were costly and were not
comfortable with the office environment and thus the requirement of diskless
machine was generated which could be connected to the server with high
capacity of hard disk. Using Disk Management, you can remotely manage disks

Operating System Fundamentals

53

on another computer in your network. To manage disks that are connected to
remote computers, you must be a member of the Backup Operators Group or
Administrators Group on both the Local and Remote Computers. The types of
volumes and disks you can create depend on the Operating System running on
the Remote Computer, not the Local Computer.
Q.7

Write a note on Remote File System.

Ans.: Remote File System : To reduce networks delay and provide same interface to
the application program as the Local File System, we can use Remote File System
in place of Remote Disk System. The Remote File System is divided in to Client
Part and Server Part. The Client Part contains the details related to operations
required to communicate with Server Part.
Q.8

What do you mean by File Level Caching?

Ans.: File Level Caching : This scheme allows automatic copying of the entire files
from servers to client and once the operation at client is over, the file is closed
and then the file is returned back to the server.
Q.9

Q.10 Write the difference between Viruses and Worms.
Ans.: Viruses and Worms : A Computer Virus is a code that attached itself to other
programs in order to alter their behavior, in an harmful way. Viruses normally

54

cause direct harm to the system. While a Computer Worm is a program written
in such a way that is spread to other computers over a network and it also
consumed the network resources to a very large extent. But it does not harm any
other computer program or data.
Q.11 Define various Security Design Principles.
Ans.: Security Design Principles :
Mechanisms are :

The General Design Principles for Protection

(i)

Public Design

(ii)

Least Privilege

(iii)

Explicit Demand

(iv)

Continuous Verification

(v)

Simple Design

(vi)

User Acceptance

(vii)

Multiple Conditions

Q.12 What is the goal of Authentication?
Ans.: Authentication : Authentication is a process of verifying whether a person is a
legitimate user or not. The primary goal of Authentication is to allow access to
legitimate system users and to deny access to unauthorized parties. The
password is the most commonly used authentication scheme which is also easy
to implement.
Q.13 Define various Protection Mechanisms used for Protecting Files.
Ans.: Protection Mechanisms : There are a number of mechanisms that are employed
to protect the system resources. For various objects, the Operating System allows
different Access Rights for different subjects. An Access Control Matrix (ACM)
has to be stored by Operating Systems in order to decide to which user to grant
what access rights for which file. Basically there are three methods used for
storing the ACM :
(i)

Access Control List

(ii)

Capability List

(iii)

Combined Scheme

Operating System Fundamentals

55

Q.14 What do you mean by Encryption?
Ans.: Encryption : In technical terms, the process of encoding messages is called as
Encryption. In it the original text is called as Plain Text but when it is encrypted,
it is called Cipher Text. The recipient understands the meaning and decodes the
message to extract to correct meaning out of it. This process is called Decryption.

□□□

56

Multiple Choice Question
Q1. SIGNAL and WAIT operation are related to
A. Multiprogramming
B. Semaphores
C. Pre-emptive scheduling of processes
D. None of the above
Q2. Messages are very much required for
A. synchronization
B. inter process communication
C. both (a) and (b)
D. None
Q3. IPC stands for:
A. Inter- Process communication
B. Intra-Process communication
C. In-Program cooperation
D. None
Q4. Mutual Exclusion problem occurs between
A. two disjoint processes that do not interact
B. processes that share resources
C. processes that do not use the same resource
D. None
Q5. Which of the following is not a direct function of operating system
A. I/O operation
B. Memory management
C. Resource management
D. DBMS
Q6. Which of the following condition is not responsible for a deadlock to occur?
A. Mutual Exclusion
B. Hold and Wait
C. No-Preemption
D. Semaphore

Operating System Fundamentals

57

Q7. A situation where two or more processes get into a state whereby each is holding a resource
while other is requesting
A. Page Fault
B. Debugging
C. Deadlock
D. I/O management
Q8.If bankers algorithem is to deadlock,Paging is to:
A. Memory management
B. Scheduling
C. Threads
D. None of the above
Q9. In UNIX,the command to terminate execution of a program is:
A. Kill
B. Fork
C. Stop
D. End
Q10. An operating system works as:
A. An extended machine
B. A resource manager
C. A & b both
D. None of the above

58

CHAPTER-9
C

Distributed Systems
Q.1

Define Distributed Systems.

Ans.: Distributed Systems : Distributed Computing deals with hardware and software
systems containing more than one processing element, storage element,
concurrent processes, or multiple programs, running under a loosely or tightly
controlled system. In distributed computing a program is split up into parts that
run simultaneously on multiple computers communicating over a network.
Distributed computing is a form of parallel computing.
Q.2

Ans.: Distributed Process Management : In Distributed Computing, the network
provides an opportunity for the computation to be divided into logical units, so
that each logical unit operates independently and simultaneously to achieve
higher degree of computation in the computers in the networks.
To support Distributed
management are required :

Ans.: Message Passing System : In Computer Science, message passing is a form of
communication used in parallel computing, object-oriented programming, and
inter-process communication. Communication is made by the sending of
messages to recipients. The most common model used for distributed message
passing is referred to as client-server model. A client process requires some
service and sends a message containing a request for service to a server process.
The server process honors the request and sends a reply.
Q.5

Explain RPC.

Ans.: RPC : Many Distributed Systems have been based on explicit message exchange
between processes. When a process on machine A calls a procedure on machine
B, the calling process on A is suspended, and execution of the called procedure
takes place on B. Information can be transported from the caller to the callee in
the parameters and can come back in the procedure result. No message passing
at all is visible to the programmer. This method is known as Remote Procedure
Call, or often just RPC.
Q.6

How the Memory is Managed in Distributed Environment?

Ans.: Memory Management in Distributed Environment : There was an abstract
model of memory management in Distributed Systems. With this model we can

60

express communication, allocation and garbage collection, but otherwise hide
many of the lower-level details of an actual implementation. In Distributed
Memory Management, OS support for management of remote disk and remote
files is also required. The distributed memory can be implemented using either
of the architecture i.e.- by Multi-Computer or Network of machine.
Q.7

Explain the Security Requirements of Distributed Systems.

Ans.: Security Requirements of Distributed Systems : In Distributed Systems,
Network Services are also involved. Hence the major Security Threats
are :
(1)

Leakage of the contents of a message between two processes.

(2)

Modification of the contents of a message.

(3)

Impersonation of a user by an unauthorized user.

□□□

Operating System Fundamentals

Multiple choice Question
Q1. The operating system which the IBM –PC uses:
E. CP/M
F. MS-DOS
G. UNIX
H. AT-DOS
Q2.Most operating system are designed to run with a specific:
E. Type of processor
F. Manufacturer’s printer
G. Brand of computer
H. Style of keyboard
Q3.A technique that can be used when a very long program exceeds the storages
capacity of memory is called:
E. Windowing
F. Time sharing
G. Linkage editing
H. Virtual memory
Q4.An operating system designed for uase on both PC’s at home andon serversin
business is:
E. Windows XP
F. Windows ME
G. Windows NT
H. Windows CE

OPERATING SYSTEM FUNDAMETNALS
OBJECTIVE PART- I
Year - 2011
Time allowed : One Hour
Maximum Marks : 20
The question paper contains 40 multiple choice questions with four choices and student will
have to pick the correct one (each carrying ½ mark).
1.

In time sharing system the basic aim is:
(a)
To allow users to interact with the computer system at the same time
(b)
To allow many users to interact using punched cards
(c)
To share memory among the users
(d)
Multiprocessing system

( )

Which of the following is true?
(a)
MS-DOS does not support multiprogramming
(b)
MS-DOS supports multiprogramming to some extent
(c)
MS-DOS supports multiprogramming
(d)
None of the above

( )

In distributed system:
(a)
Each system has separate clock
(b)
Each system shares memory and clock
(c)
Each system has separate memory and clock
(d)
All of the above

( )

Operating System Fundamentals

65

5.

The ……………….is small program that runs when you first start the computer.
(a)
FAT
(b)
Folder
(c)
Boot Record
(d)
Root Directory
( )

6.

CPU bound job will have more:
(a)
IO burst
(c)
Both (a) and (b)

7.

8.

(b)
(d)

CPU burst
Neither (a) nor (b)

( )

Long term scheduler is also called as:
(a)
Memory schedular
(b)
CPU schedulear
(c)
Job schedular
(d)
None of the above

Semaphores are used to solve the problem of:
(a)
Race condition
(b)
Process synchronization
(c)
Mutual exclusion
(d)
None of the above
The part of an operating system which permanently resides in main memory is:
(a)
Kernel
(b)
Job scheduling module
(c)
Translator

( )

Operating System Fundamentals

(d)
21.

22.

23.

24.

25.

26.

27.

None of the above

67

( )

Part of the program or a process where a shared resource is accessed, is called:
(a)
Race condition
(b)
Segment offset
(c)
Critical section
(d)
Mutual code

( )

In UNIX deadlock is handled considering:
(a)
Ignore the problem
(b)
By resource pre-emption
(c)
Solve the problem
(d)
None of the above

Disk scheduling involves deciding:
(a)
Which disk should be accessed next?
(b)
The order in which disk access requests must be serviced
(c)
The physical location where files should be accessed in the disk
(d)
None of the above

( )

Buffering is a technique used in office management:
(a)
to bridge the gap between show I/O devices and fast processor
(b)
to bridge the gap between cost of I/O devices and processor
(c)
to bridge the gap between I/O
(d)
none of the above

( )

Asynchronous data transfer is used when:
(a)
I/O devices and CPU speed matches
(b)
I/O devices are very show than CPU
(c)
I/O devices are very fast than CPU
(d)
None of the above

( )

In first fit memory allocation scheme, the available space is:
(a)
Stored by location
(b)
Stored by size
(c)
Stored by time
(d)
Stored by cost

( )

68

28.

In real time operating system, which of the following is the most suitable scheduling
scheme:
(a)
Round-Robin
(b)
Fist Come First Served
(c)
Pre-emptive scheduling
(d)
Random scheduling
( )

The fist-fit and worst-fit algorithm can be used for:
(a)
Contiguous allocation of memory
(b)
Linked allocation of memory
(c)
Indexed allocation of memory
(d)
All of the above

( )

Fork (Label) instruction procedures are:
(a)
Two concurrent executions in the program
(b)
Two non-concurrent executions in the program
(c)
Both (a) and (b) are true
(d)
Neither (a) nor (b) is true

( )

Command interpreter is a:
(a)
System program for interface between user and operating system
(b)
System program for interface between user and hardware
(c)
Application program for interface between user and hardware
(d)
None of the above

Which of the following is well suited for batch processing?
(a)
Process control
(b)
Preparing mailing addresses
(c)
Preparing pay slips of employees
(d)
Video game control
( )

35.

A kilobyte corresponds to:
(a)
1024 bytes
(c)
1000 bits

(b)
(d)

1000 bytes
1024 bits

( )

Operating System Fundamentals

69

36.

Some computer systems support dual mode operation-the user mode and the supervisor
or monitor mode. These refer to the modes:
(a)
By which user programs handle their data
(b)
By which the operating system executes user programs
(c)
In which the processor and the associated hardware operate
(d)
Of memory access
( )

37.

Example of I/O bound job is:
(a)
Printing of pay slips of a large organisation
(b)
Arithmetic calculations
(c)
Simulation program
(d)
All of the above

( )

Which scheduler has the highest frequency?
(a)
Short term scheduler
(b)
Long term scheduler
(c)
Medium term scheduler
(d)
All the above have same

The incompatibility between two I/O devices arise because of difference is:
(a)
Data format
(b)
Timing for data transfer
(c)
Electrical character of two devices
(d)
All of the above

( )

38.

39.

40.

Answer Key
1. ( )
2. ( )

3. ( )

4. ( )

5. ( )

6. ( )

7. ( )

8. ( )

9. ( )

10. ( )

11. ( )

12. ( )

13. ( )

14. ( )

15. ( )

16. ( )

17. ( )

18. ( )

19. ( )

20. ( )

21. ( )

22. ( )

23. ( )

24. ( )

25. ( )

26. ( )

27. ( )

28. ( )

29. ( )

30. ( )

31. ( )

32. ( )

33. ( )

34. ( )

35. ( )

36. ( )

37. ( )

38. ( )

39. ( )

40. ( )

___________

70

DESCRIPTIVE PART-II
Year- 2011
Time allowed : 2 Hours
Maximum Marks : 30
Attempt any four questions out of the six. All questions carry 7½ marks each.
„Operating system works as a resource manager.‟ Justify the above statement.
Explain the various factors one shall keep in mind while designing the operating
system.

Q.1

(a)
(b)

Q.2

Given the following jobs to execute with one processor:
Process
Burst Time
Priority
P1
70
2
P2
20
4
P3
10
3
P4
15
5
P5
40
1
The jobs are assumed to arrive at the same time. Using priority scheduling execute the
following :
(i)
Create a Gantt chart illustrating the execution of these processes.
(ii)
What is the turnaround time for process?
(iii) What is the average waiting time for the process?

Q.3

(b)

What are the major criteria for selection of best algorithm for CPU utilization?

(a)

What is time sharing? How is it achieved? Explain.

Operating System Fundamentals

71

OPERATING SYSTEM FUNDAMETNALS
OBJECTIVE PART- I
Year - 2010
Time allowed : One Hour
Maximum Marks : 20
The question paper contains 40 multiple choice questions with four choices and student will
have to pick the correct one (each carrying ½ mark).
1.

2.

3.

4.

5.

Operating system is :
(a)
hardware
(b)
software
(c)
application program
(d)
none of the above

If Banker's algorithm is to deadlock, then paging is to:
(a)
memory management
(b)
scheduling
(c)
threads
(d)
none of the above

( )

Cache memory :
(a)
has greater capacity then RAM
(b)
is faster to access then CPU register
(c)
is permanent storage
(d)
is faster to access than DRAM

( )

Which of the following is true?
(a)
Overlays are used to increase the size of physical memory
(b)
Overlays are used to increased the logical address space
(c)
When overlays are used, the size of a process is not limited to the size of
physical memory

72

(d)

Overlays are used whenever the physical address spaces is smaller than the
logical address space
( )

6.

In real time operating system, which of the following is the most suitable scheduling
scheme?
(a)
round robin
(b)
first come first served
(c)
pre emptive scheduling
(d)
random scheduling
( )

Disk scheduling involves deciding:
(a)
Which disk should be accessed next
(b)
The order in which disk access requests must be serviced
(c)
The physical location where files should be accessed into the disk
(d)
None of the above

( )

Mutual exclusion problem occurs between:
(a)
Processes that share resources
(b)
two disjoint processes that do not interact
(c)
processes that do not use of same resources
(d)
Three Column cash book

( )

74

20.

Buffering is a technique used in a office management:
(a)
to bridge the gap between slow I/I devices and fast processor
(b)
to bridge the gap between cost of I/O devices and processor
(c)
to bridge the gap between I/O devices and processor
(d)
none of the above

( )

21.

While reading or writing on disks, the time taken to move the arm to the proper cylinder
is known as:
(a)
Rotational delay
(b)
access time
(c)
translational delay
(d)
seek time
( )

22.

Which of the following are single user operating system?
(a)
MS DOS
(b)
UNIX
(c)
XENIX
(d)
OS/2

( )

Which of the following services is not supported by the operating system?
(a)
Protection
(b)
Compilation
(c)
Accounting
(d)
I/O Operation

Wild-card specifies:
(a)
provide an easy way of finding groups of related files
(b)
are only used when printing the contents to files
(c)
can be used when writing a file
(d)
allow several when writing a file

Encryption:
(a)
is one common method of protecting information transmitted over unreliable
linkds
(b)
in crypted network information is accessed by unauthorized person
(c)
both A & B
(d)
none of the above
( )

76

35.

36.

37.

Window NT:
(a)
is a security model based on the notion of user accounts.
(b)
creates a security access token that includes the security ID for users
(c)
operates with client server mode!
(d)
all of the above

Which of the following is a type of utility to reduce the size of files to increase the
amount of available disk space?
(a)
File Compression Utility
(b)
Troubleshooting Utility
(c)
Anti Virus Utility
(d)
Uninstall utility
( )

39.

DBMS is preferred because of:
(a)
Consistency
(b)
Data independency
(c)
Random file system
(d)
All of the above

What is real time operating system? How does it differ from generally used OS?
What is distributed operating system? Where it is used? State application diagram?

Q.2

Consider the following set of processes, with the length of the CPU burst time given in
milliseconds:
Process
Burst Time
Priority
P1
10
3
P2
1
1
P3
2
3
P4
1
4
P5
5
2
The processes are assumed to have arrived in the order P1, P2, P3, P4 and P5 all at time to:
(a)
Draw Gantt Charts illustrating the execution of these processes using FCFS, SJF
and round Robin Scheduling (quantum = 2)
(b)
What is the turn around time for each process in above there algorithms?
(c)
What is the waiting time for each process in above three algorithms?
(d)
Compare with priority scheduling in terms of waiting time and turn around time.

Q.3

(a)
(b)

Q.4

(a)
(b)

Q.5

(a)
(b)

What is the main advantage of multi programming? Why was time sharing not
widespread on second generation of computers?
Distinguish between a 'program' and a 'process'. Describes process life cycle with
the help of a process state diagram.
What is a deadlock? Which is better 'dead-lock prevention' or 'deadlock removal'?
Explain.
Compare CPU scheduling and disk scheduling.
What is file management? How is it done by an operating system?
Discuss the concept of 'semaphore' illustrate the application of semaphore in
'producer- consumer' or nay other problem.

OPERATING SYSTEM FUNDAMETNALS
OBJECTIVE PART- I
Year - 2009
Time allowed : One Hour
Maximum Marks : 20
The question paper contains 40 multiple choice questions with four choices and student will
have to pick the correct one (each carrying ½ mark).
1.

Different ways of creating and deleting process are:
(a)
JOINT
(b)
QUIT
(c)
FORK
(d)
All of the none

( )

The two important characteristics of I/O devices are:
(a)
Asynchronous operations
(b)
Speed gap
(c)
Both (a) and (b)
(d)
None of the above

( )

13.

Overlay is:
(a)
A part of an operating system
(b)
A single memory location
(c)
A single contiguous memory that was used in olden days for running large
program
(d)
Overloading the system with many user files
( )

14.

An assembly language program is typically:
(a)
Non protable
(b)
Shorter than equivalent HLL program

Operating System Fundamentals

(c)
(d)
15.

16.

17.

18.

19.

20.

21.

22.

81

Harder to read than machine code program
Slower to execute than complied HLL program

What is resource allocation graph? Describe its various entities. Also draw separate
resource. Allocation graphs showing a deadlock and a cycle but no deadlock.

Q.6

Differentiate any three:
(a) Program and process
(b) Memory mapped I/G and Direct memory access
(c) Linked allocation and indexed allocation of disk block
(d) Real time system and Embedded system
________

86

OPERATING SYSTEM FUNDAMETNALS
OBJECTIVE PART- I
Year - 2008
Time allowed : One Hour
Maximum Marks : 20
The question paper contains 40 multiple choice questions with four choices and student will
have to pick the correct one (each carrying ½ mark).
1.

Trojan-horse programs:
(a)
Are legitimate program that allow unauthorized access
(b)
Are hacker programs that do not show up on system
(c)
Really do not usually work
(d)
Usually are immediately discovered

( )

A file is:
(a)
An abstract type
(b)
Logical storage unit
(c)
File is usually volatile
(d)
All of the above

The most common system security method is:
(a)
Password
(b)
Key card system
(c)
Mantrap
(d)
None of the above

( )

Mutual exclusion problem occur between:
(a)
Two disjoint processes that do not interact
(b)
Processes that do not use the same resource
(c)
Processes that do not use the same resource
(d)
None of the above

( )

The garbage collector:
(a)
Is critical for efficient virtual memory system
(b)
Prevents fragmentation from occurring
(c)
Is mostly used with fixed partitions
(d)
Collects fragmented areas of memory

( )

Page fault occur when:
(a)
The page is corrupted by application software
(b)
The page is in main memory
(c)
The page is not in main memory
(d)
None of the above

DESCRIPTIVE PART - II
Year 2008
Time allowed : 2 Hours
Maximum Marks : 30
Attempt any four questions out of the six. All questions carry 7½ marks each.
Q.1

Differentiate any three:
(i)
Process and Thread
(ii)
Spooling and Buffering
(iii) Paging and Segmentation
(iv)
Real time system and Embedded system

Q.2

(a)
(b)

Q.3

(a)
(b)

Q.4

(a)
(b)

Q.5

(a)
(b)

Q.6

(a)
(b)

What is an operating system and how is it related to computer hardware? Describe
the function also.
What is the difference between kernel mode and User mode? Why is the
difference important to an operating system
What is a race condition? Give an example of a race condition that could possibly
occur when buying airplane tickets for two people to go on a trip together.
What are schedulers? Describe three different types of schedulers.
Describe the deadlock with example. Why deadlock occur? Discuss various
methods used for deadlock avoidance.
Can a system be is a state that is neither deadlock nor safe? If yes, give examples?
What is the device management? Explain the various techniques used for device
management?
Write short note on semaphores.
What do you mean by file management.
What is distribution processing? Where is it useful? What are main defects of
password for multiuser system entry?

_______

Operating System Fundamentals

93

OPERATING SYSTEM FUNDAMETNALS
OBJECTIVE PART- I
Year - 2007
Time allowed : One Hour
Maximum Marks : 20
The question paper contains 40 multiple choice questions with four choices and student will
have to pick the correct one (each carrying ½ mark).
1.

Which of the following is not a solution to mutual exclusion implementation?
(a)
Strict alternation
(b)
Paterson's solution

96

(c)
(d)
22.

TSL instruction
None of the above

WS clock policy algorithm:
(a)
Is a scheduling mechanism
(b)
Is a page replacement mechanism
(c)
Is a disk scheduling mechanism
(d)
None of the above

( )

( )

23.

In context of deadlock, a state in which there is at least one sequence of resource
allocations to processes that does not result in a deadlock is called:
(a)
Safe state
(b)
Unsafe state
(c)
Deadlock avoidance
(d)
Critical state
( )

24.

Which of the following is non-preemptive CPU scheduling policy?
(a)
Shortest job first
(b)
First come first served
(c)
Shortest remaining time
(d)
Both A and B

( )

Multiprogramming was not implemented :
(a)
For optimal utilization of resources
(b)
For higher throughout
(c)
For quick response time
(d)
For large storage area access

( )

Banker's algorithm is used for deadlock:
(a)
Avoidance
(b) Detection
(c)
For quick response time
(d) Banking transactions on computer

If a process is denied access to the resource indefinitely, it is called:
(a)
Thrashing
(b)
Competition
(c)
Starvation
(d)
None of the above

( )

25.

26.

27.

28.

Operating System Fundamentals

29.

30.

31.

32.

33.

34.

35.

36.

37.

97

Frequent page faults due to insufficient number of page frame is termed:
(a)
Trashing
(b)
Competition
(c)
Starvation
(d)
None of the above

( )

Part of the program or a process where a shared resource is accessed is called:
(a)
Race condition
(b)
Segment offset
(c)
Critical section
(d)
Mutual code

( )

PCB stands for:
(a)
Program Control Block
(c)
Process Control Block

( )

(b)
(d)

Process code block
Process control bus

Degree of multiprogramming means:
(a)
Number of process running concurrently on the system
(b)
Number of process running versus terminating per unit time
(c)
Number of process executed since the system start up
(d)
None of the above

Which of the following is not a direct function of operating system:
(a)
I/O operation
(b)
Memory management
(c)
Resources management
(d)
DBMS

( )

Which of the following is also known as a "light weight process"?
(a)
Function
(b)
Application Module
(c)
Kernel
(d)
Thread

( )

Cache memory:
(a)
Has greater capacity than RAM
(b)
Is faster to access than CPU register
(c)
Is permanent storage
(d)
Is faster than DRAM

( )

LAN speeds are measured in:
(a)
bps

(b)

kpbs

98

(c)
38.

39.

40.

mbps

(d)

gbps

( )

In UNIX, the command to terminate execution of a process is:
(a)
Fork
(b)
Slop
(c)
End
(d)
kill

( )

Which of the following is freely available over the internet?
(a)
MS dos
(b)
Linux
(c)
Windows 95
(d)
Macintosh

( )

Most operating system are designed to run with a specific:
(a)
Type of processor
(b)
Manufacturer's printer
(c)
Brand of computer
(d)
Style of key board

( )

Answer Key
1. (d)
2. (b)

3. (a)

4. (d)

5. (d)

6. (c)

7. (d)

8. (b)

9. ( )

10. (d)

11. (d)

12. (a)

13. (c)

14. (a)

15. (c)

16. (a)

17. (b)

18. (a)

19. (a)

20. (b)

21. (c)

22. (b)

23. (a)

24. (d)

25. (d)

26. (a)

27. (a)

28. (c)

29. (a)

30. (c)

31. (c)

32. (c)

33. (c)

34. (d)

35. (d)

36. (d)

37. (c)

38. (d)

39. (b)

40. (a)

______________

Operating System Fundamentals

99

DESCRIPTIVE PART - II
Year 2007
Time allowed : 2 Hours
Maximum Marks : 30
Attempt any four questions out of the six. All questions carry 7½ marks each.

Q.1

(a)
(b)

Discuss the role of operating system as a Resource Manager.
What are the difference between a trap and an interrupt?

Q.2

(a)
(b)

What is a race condition? Why does it occur?
Discuss the procedure-consumers problem (or bounded buffer problem) in context
of race condition?

Q.3

What are threads? Differentiate between user level threads and kernel level threads.
Under what circumstances is one type better than the other?

Q.4

What is a Resource Allocation Graph? Describe its various entities. Also draw separate
Resource Allocation Graphs showing a deadlock and a cycle but no deadlock.

Q.5

Discuss the major program and system threats, in context of computer systems.

Q.6

(a) What is the difference between memory mapped I/O and Direct Memory Access?
(b) Name major files attributes and operations.
or
What is virtual memory? Discuss the tow key techniques of vitual memory
implementation-paging and segmentation.

_________

100

OPERATING SYSTEM FUNDAMETNALS
OBJECTIVE PART- I
Year - 2006
Time allowed : One Hour
Maximum Marks : 20
The question paper contains 40 multiple choice questions with four choices and student will
have to pick the correct one (each carrying ½ mark).
1.

2.

PCB stands for:
(a)
Program Control Block
(c)
Program Control Bus

(b)
(d)

Process Control Bus
Process Control Block

Which of the following is not a page replacement strategy?
(a)
FIFO
(b)
Second chance
(c)
Clock page
(d)
None of the above

( )

( )

3.

While reading or writing on disks, the time taken to move the arm to the proper cylinder
is known is:
(a)
Rotational delay
(b)
Access time
(c)
Translational delay
(d)
Seek time
( )

4.

Which of the following is a file system?
(a)
Ext 3
(b)
FAT 32
(c)
ISO 9660
(d)
All of the above

"Degree of multiprogramming" means:
(a)
Number of processes running concurrently on the system
(b)
Number of process running versus terminating in a second
(c)
Number of process executed since the system start up
(d)
None of the above

The ability of lead and execute a given program into an arbitrary place in memory is:
(a)
Dynamic Execution of Program
(b)
Program Relocatability
(c)
Segmented Execution of Program
(d)
None of the above
( )

16.

Interleaved execution of more than one programs at a time is known is:
(a)
Multiprogramming
(b)
Multitasking
(c)
Multiprocessing
(d)
Graphical user interface

( )

A CPU scheduling strategy where the process will run to its completion is :
(a)
Throughout
(b)
Real time
(c)
Non-preemptive
(d)
Preemptive

( )

Which of the following is not a direct function of an operating system;
(a)
I/O operation
(b)
Memory management
(c)
Resources management
(d)
DBMS

( )

Which of the following is also known as a "lightweight process"
(a)
Function
(b)
Application Module
(c)
Kernel
(d)
Thread

( )

A GUI is a :
(a)
Hardware
(c)
Kernel

(b)
(d)

Language interpreter
An operating system

( )

A kilo byte corresponds is:
(a)
1024
(c)
1000 bits

(b)
(d)

1000 bytes
1024 bytes

( )

17.

18.

19.

20.

21.

22.

Cache memory:
(a)
Has greater capacity than RAM
(b)
Is faster access than CPU register
(c)
Is permanent storage
(d)
Is faster to access than DRAM

A Complier:
(a)
Converts a HLL program into a machine language program
(b)
Converts a HLL program into a machine language program and executes it
(c)
Converts a machine language program into executable Program

104

(d)
32.

33.

34.

None of the above

( )

Busy waiting is a technique:
(a)
to allow the CPU wait for a busy device
(b)
to allow a busy device wait for the CPU
(c)
To keep an idle device busy
(d)
Improve CPU performance

( )

An assembly language program is typically:
(a)
Non-portable
(b)
Shorter than equivalent HLL program
(c)
Harder to read than a machine code program
(d)
Slower to execute than a complied HLL program

( )

Which of the following is not an example of an operating system?
(a)
Windows
(b)
Adobe/e
(c)
Mac OS
(d)
Linux

( )

35.

This type of boot occurs when the computer is already on, and you restart it without
turning off the power.
(a)
Generic boot
(b)
Live boot
(c)
Warm boot
(d)
Cold boot
( )

36.

Which is of the following is a type of utility to reduce the size of files to increase the
amount of available disk space:
(a)
File compression utility
(b)
Antivirus utility
(c)
Troubleshooting utility
(d)
Uninstall utility
( )

37.

Most operating systems are designed to run with a specific:
(a)
Type of processor
(b)
Manufacturer's printer
(c)
Brand of computer
(d)
Style of keyboard

( )

38.

A technique that can be used when a very long program exceeds the storage capacity of
memory is called:
(a)
Windowing
(b)
Timesharing
(c)
Linkage editing
(d)
Virtual memory
( )

39.

Which of the following operating system software is available for free over the Internet?
(a)
MS DOS
(b)
Linux
(c)
Windows 95
(d)
Virtual Memory
( )

Operating System Fundamentals

40.

105

An operating system designed for use on both PCs at home and on server in business is:
(a)
Windows XP
(b)
Windows Me
(c)
Windows NT
(d)
Windows
( )

Answer Key
1. (d)
2. (d)

3. (d)

4. (a)

5. (a)

6. (b)

7. (a)

8. (c)

9. (a)

10. (a)

11. (a)

12. (c)

13. (a)

14. (b)

15. (b)

16. (a)

17. (a)

18. (d)

19. (d)

20. (c)

21. (a)

22. (b)

23. (b)

24. (c)

25. (b)

26. (d)

27. (c)

28. (a)

29. (b)

30. (a)

31. (a)

32. (b)

33. (a)

34. (b)

35. (c)

36. (a)

37. (a)

38. (d)

39. (b)

40. (a)

_____________

106

DESCRIPTIVE PART - II
Year 2006
Time allowed : 2 Hours
Maximum Marks : 30
Attempt any four questions out of the six. All questions carry 7½ marks each.
Q.1

(a)
(b)

Q.2

(a)
(b)

Q.3

(a)
(b)
(c)

Q.4

(a)

Discuss the evolution of operating system from a simple JCL, program to a
multiprogramming operating system.
Define semaphore; are P-V operations refer to 'SIGNAL' and 'WAIT'
operations?
What is memory fragmentation? Discuss various type of fragmentation and
their causes?
What is thread? Differentiate between kernel level threads and user level
threads.
Discuss round robin strategy of CPU scheduling. Explain the importance of
selection of appropriate time quantum in this strategy.
What are the primary function of a basic disk controller?
Define 'Mutual Exclusion'

(b)

Discuss major security threats to computer based systems, as provided by their
users and providers.
What is a virus in context of computer?

Q.5

(a)
(b)
(c)

Define interrupts, service routine and interrupt vectoring?
What is a "process switch" or context switch"?
Discuss the LRU page replacement policy.

Keywords
BIOS (basic input/output system) - BIOS (basic input/output system) is the program a personal
computer's microprocessor uses to get the computer system started after you turn it on.
CPU bound-A property of a process in which processor use is high, and I/O requests are low.
ASCII- A 7 bit code for representing American English characters and device controls.
Direct Memory Access- The transfer of data between memory and a peripheral directly, without
passing through the CPU.
FIFO scheduling-A scheduling policy which schedules tasks in the same order in which they
enter the ready state.
I/O bound-A property of a process in which processor use is low, and I/O requests are high.
LFU Page Replacement- A strategy which replaces the page which has been used least often.
Round Robin scheduling- A scheduling policy which scheduleses tasks in a fixed circular
order.
SCAN disk scheduling- A disk scheduling strategy which satisfies the pending disk request
which is physically closest to the current position of the access arm in the current direction of
motion, reversing direction when the first and last cylinders are reached.
SRAM- Semiconductor read-write memory in which individual bit cells stable as long as power
is maintained.
Unicode- A 16 bit code for representing characters.
base register- A register which contains a value which is added to virtual memory addresses to
produce a memory address.
batch process- A process which executes without user interaction.
best fit- A placement strategy which selects the smallest space from the free list which is large
enough.

108

binary semaphore- A semaphore that can only have the values 0 and 1.
blocked list- An operating system data structure which contains all of the blocked processes in
the system.
blocked state- A process state entered by a task which is waiting for some event or action to
occur.
born state- The tread state in which a new thread begins life.
Bus- A communication pathway that connects two or more of the major components of a
computer system, including CPU, memory, and device controllers.
busy wait-A situation in which a process, while not blocked, continuously checks for a condition
which will allow it to proceed.
Byte- The smallest addressable part of memory.
Cache- Solid state memory used to buffer and store data temporarily.
Compiler- A translator from a high level language to a low level language.
dead state- The state of a thread after it has been terminated.
demand paging- A paging policy which reads in a page only when it is referenced.
Dispatcher- The operating system component which transitions a process to the running state.
information hiding- A program style which which masks implementation details of a module
from the rest of the code.
interactive process- A process which requires user interaction while executing.

Interpreter- A program expressed in one language which executes programs expressed in
another language.
Interrupt- An asynchronous service request from hardware or software to the CPU.
interrupt handler- A software routine which processes interrupts.

Operating System Fundamentals

109

Join- Thread operation in which the calling thread is blocked until the thread it joins terminates.
Middleware- Software that sits between two or more types of software and translates
information between them.
mutual exclusion- A situation in which at most one process can be engaged in a specified
activity at a time.
noncontiguous memory allocation- Allocation in which the address space is separated into
nonadjacent regions.
Nonpreemptive- Not having the capability of preempting running tasks.
Page-A fixed size block of contiguous memory addresses in a virtual address space which is
managed as a unit.
page fault-An interrupt generated when a program references a page that is not currently
resident.
process control block- An operating system data structure that characterizes a proce
process state- The status of a process as running, ready, blocked, etc.
process table- An operating system data structure which pointers to all of the processes in the
system.
Producer- A process or thread that creates data and places it into a shared object.
Program-A (static) set of instructions which can be used as the basis for a process.
race condition-A situation where the (uncontrolled) ordering of events can affect the outcome of
the situation.
ready list- An operating system data structure which contains all of the ready processes in the
system.
ready state- A process state in which all resources except the processor are available.