0% found this document useful (0 votes)
3 views26 pages

OS Question Bank

The document is an electronic question bank for Operating Systems, designed for the 5th semester of Information Technology at Yeshwantrao Chavan College of Engineering. It contains a comprehensive list of questions covering various topics such as definitions, comparisons, system calls, scheduling algorithms, and process management, along with their respective marks, difficulty levels, and types. The questions are structured to assess students' understanding of operating system concepts and their applications.

Uploaded by

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

OS Question Bank

The document is an electronic question bank for Operating Systems, designed for the 5th semester of Information Technology at Yeshwantrao Chavan College of Engineering. It contains a comprehensive list of questions covering various topics such as definitions, comparisons, system calls, scheduling algorithms, and process management, along with their respective marks, difficulty levels, and types. The questions are structured to assess students' understanding of operating system concepts and their applications.

Uploaded by

nishuuu8901
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 26

Yeshwantrao Chavan College of Engineering

(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)


Hingna Road, Wanadongri, Nagpur.
Department of Information Technology
Semester: 5th
Electronic Question Bank for
Operating Systems
S Uni Time Marks Length Difficulty CO Type
N t Text of question require allotted -iness level Mapp (D/N)
No d (Min) ed

1. I. Define operating system. List different resources of a 9 4 Short Easy CO- D


1. computer system. Write the function of OS as a 1
manager of these resources in general.

2. Give differences between Time Sharing & Real Time 9 4 Short Difficult CO- D
systems with respect to following points: 1
i) Objective ii) CPU scheduling iii) Virtual
memory support iv) Application

3. Differentiate between multiprogramming & 4 2 Short Moderat CO- D


multiprocessing. e 1

4. State whether the following statements are true or 18 8 mediu Moderat CO- D
false & give a brief justification: m e 1
i. Kernel of the OS is ordinarily run with
interrupts disabled.
ii. Increasing the degree of multiprogramming
always improves CPU utilization.
iii. It is always possible to support
multiprogramming without support of time sharing.
However, it is impractical to support time sharing
without using multi-programming.
iv. Multiprogramming systems improves
systems throughput by overlapping CPU and I/O
activities of various processes.

5. Enlist and explain any five important services 18 8 long Easy CO- D
provided by an Operating System. 1

6. What is the main difficulty that a programmer must 4 2 short Very CO- D
overcome in writing an operating system for a real- difficult 1
time environment?

7. How does the distinction between kernel mode and 6 3 short Difficult CO- D
user mode function as a rudimentary form of 1
protection (security) system?

8. What are system calls. How are they different from 13 6 Mediu Moderat CO- D
API? List various system calls for process control m e 1
and explain any two of them.

9. With neat schematic explain how the transition from 9 4 Short Moderat CO- D
user to kernel mode takes place in OS while e 1
executing a system call.

10. Differentiate between a program and a process. 4 2 Short Easy CO- D


Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
S Uni Time Marks Length Difficulty CO Type
N t Text of question require allotted -iness level Mapp (D/N)
No d (Min) ed

11. Which of the following instructions should be 18 8 long Moderat CO- D


privileged and which should be non-privileged and e 1
why?
a. Set value of timer.
b. Read the clock.
c. Clear memory.
d. Issue a trap instruction.
e. Turn off interrupts.
f. Modify entries in device-status table.
g. Switch from user to kernel mode.
h. Access I/O device.

12. Consider the following code fragment: 6 3 short Difficult CO- D


1
#include <stdio.h>
#include <stdlib.h>
void main()
{
int a =100;
if(fork()==0)
{
a=a+5;
printf("%d %d \n",a,&a );
}
else
{
a=a-5;
printf("%d %d \n",a,&a );
}
}

If the fork() is successful then what values are printed


by the parent process and the child process ? justify
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
S Uni Time Marks Length Difficulty CO Type
N t Text of question require allotted -iness level Mapp (D/N)
No d (Min) ed

your answer.

13. What are the five major activities of an operating 6 3 short Easy CO- D
system in regard to process management? 1

14. What is the main advantage of the layered approach 4 2 short Moderat CO- D
to Operating system design? e 1

15. How does DMA increase system concurrency? How 4 2 short Very CO- D
does it complicate hardware design? difficult 1

16. Differentiate between block and character devices. 4 2 short CO- D


1

17. Name the four registers that an I/O port typically 9 4 short Moderat CO- D
consists of and state use of each. e 1

18. Differentiate between blocking and non-blocking I/O. 4 2 short Moderat CO- D
e 1

19. What are system 'calls? List the steps showing how 9 4 short Difficult CO- D
an operating system makesthe use of system calls for 1
following operation
'Program to read data from one file and copy them to
another file'

20. Give a major difference between each of the 18 8 mediu Difficult CO- D
following m 1
a. Multiprogramming and
multiprocessing
b. Privileged and non-privileged
instruction
c. process and a thread
d. Symmetric and Asymmetric
Processing
21. What are system calls? List various system calls for 13 6 mediu Easy CO- D
memory management and explain any three of them m 1
in brief, by giving their syntax.

22. State whether the following statements are true or 18 8 mediu Moderat CO- D
false. justify your answers. m e 1
a. Privileged instructions can be run in a non–
supervisory mode.
b. Overlap of I/0 and CPU activities is an
essential aspect of multiprogramming
systems.
c. Goal of the time-sharing system is equitable
sharing of system among competing
processes.
d. Real time systems need to provide quick
event response time.
23. Differentiate between interrupt and polling w.r.t. 4 2 short Moderat CO- D
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
S Uni Time Marks Length Difficulty CO Type
N t Text of question require allotted -iness level Mapp (D/N)
No d (Min) ed

CPU and device interface communication. e 1

24. What are protection rings? How are they useful to 4 2 short Difficult CO- D
Operating System designers? 1

25. Why do some systems store the operating system in 4 2 short Difficult CO- D
firmware, and others on disk? 1

26. How could a system be designed to allow a choice of 4 2 short Difficult CO- D
operating systems to boot from? What would the 1
bootstrap program need to do?

27. How Buffering can improve the performance of a 4 2 short Moderat CO- D
Computer system? e 1

28. What are the primary differences between Network 4 2 short Moderat CO- D
Operating System and Distributed Operating System? e 1

29. Differentiate between hard and soft Real Time 2 1 short Moderat CO- D
Systems. e 1

30. Define Operating System. Enlist at least five types of 15 7 mediu Moderat CO- D
Operating Systems and explain any three of them in m e 1
brief. (Hint: Batch, Time Sharing, Real Time,
Network, Distributed)

31. With the help of neat schematic explain how the 6 3 short Difficult CO- D
operating system uses the DMA hardware. 1

32. Differentiate between spooling and buffering. 4 2 short Moderat CO- D


e 1
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.

1. II. Consider the following set of processes with the length 18 8 long Difficul CO-2 N
of the CPU burst time given in millisecond. The t
processes are assumed to have been arrived in the
order P1, P2, P3, P4, P5 all at time 0. Consider the
following algorithms:
i) Round Robin with Time slice=10ms
ii) Priority (a smaller number implies higher
priority).
iii) Shortest Remaining Time Next,

The CPU workload is given as follows

Process CPU Priority


time Burst

P1 10 3
P2 1 1
P3 2 3
P4 1 4
P5 5 2

Then perform the following for each of the three


algorithms.
a) Draw Gant charts illustrating the execution of these
processes
b) Find average waiting time for the given workload.
c) Find average turnaround time for each process.
Which algorithm gives minimum average wait time for
all processes?

2. What is a scheduler? With the help of appropriate 15 7 mediu Modera CO-2 D


diagram, explain the different types(levels) of m te
scheduling in brief?

3. Differentiate between a program and a process. 4 2 short Easy CO-2 D

4. Explain the structure and importance of process control 6 3 short Easy CO-2 D
block.

5. Draw state transition diagram for a process and explain 13 6 mediu Modera CO-2 D
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
the transitions. m te

6. Real Time systems provide good Event Response 4 2 Difficul CO-2 D


Time. Justify. t

7. State whether the following statements are true or false 13 6 mediu Difficul CO-2 D
& give a brief justification m t
i. Real-time systems generally use preemptive
CPU scheduling.
ii. SJF scheduling algorithm is a sort of priority
algorithm.
iii. Too large a time slice in RR algorithm results
in FCFS scheduling.

8. Many CPU-scheduling algorithms are parameterized. 9 4 short Difficul CO-2 D


For example, the RR algorithm requires a parameter to t
indicate the time slice. Multilevel feedback queues
require parameters to define the number of queues, the
scheduling algorithms for each queue, the criteria used
to move processes between queues, and so on. These
algorithms are thus really sets of algorithms (for
example, the set of RR algorithms for all time slices,
and so on). One set of algorithms may include another
(for example, the FCFS algorithm is the RR algorithm
with an infinite time quantum). State in one line each,
the relation that holds between the following pairs of
sets of algorithms?
i) Priority and SJF
ii) Multilevel feedback queues and FCFS
iii) Priority and FCFS
iv) RR and SJF

9. Define a process and a Process Control Block(PCB) 15 7 mediu easy CO-2 D


and explain in brief, at least five attributes of PCB. m

10. Explain the difference in the degree to which the 6 3 short difficult CO-2 D
following scheduling algorithms discriminate in favor
of short processes: - FCFS , RR , Multilevel feedback
queue.

11. What advantage is there in having different time- 4 2 short difficult CO-2 D
quantum sizes on different levels of a multilevel
queuing system?

12. Provide two programming examples in which 4 2 short easy CO-2 D


multithreading provides better performance than a
single-threaded solution.

13. What resources are used when a thread is created? 4 2 short moderat CO-2 D
How do they differ from those used when a process is e
created?
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
14. Suppose that a scheduling algorithm (at the level of 4 2 short difficult CO-2 D
short-term CPU scheduling) favors those processes
that have used the least processor time in the recent
past. Why will this algorithm favor I/O-bound
programs and yet not permanently starve CPU-bound
programs?

15. Define the difference between preemptive and non- 9 4 short easy CO-2 D
preemptive scheduling. Give two examples of each
type.

16. Differentiate between a process and a thread. 6 3 short difficult CO-2 D

17. Consider three processes, all arriving at time zero, with 18 8 long Very CO-2 N
local execution time 10, 20 and 30 units, respectively. difficult
Each process spends the first 20% of execution time
doing I/O, the next 70% of time doing computation,
and the last 10% of time doing I/O again. The
operating system uses a shortest remaining compute
time first (SRTF') scheduling algorithm and schedules
a new process either when the ruining process gets
blocked on I/O or when the running process finishes its
compute burst. Assume that all I/O operations can be
overlapped as much as possible. What percentage of
time does the CPU remain Idle?

18. What resources are used when a thread is created? 4 2 short moderat CO-2 D
How do they differ from those used when a process is e
created?

19. Suppose that the following processes arrive for 13 6 mediu moderat CO-2 N
execution at the times indicated. Each process will run m e
the listed amount of time. In answering the questions,
use non-preemptive scheduling and base all decisions
on the information you have at the time the decision
must be made.
Process Arrival Time Burst Time
P1 0.0 8
P2 0.4 4
P3 1.0 1
a. What is the average turnaround time for these
processes with the FCFS scheduling algorithm?
b. What is the average turnaround time for these
processes with the SJF scheduling algorithm?

20. What is the solution to starvation of processes in case 4 2 short moderat CO-2 D
of SJF and priority scheduling algorithms? e

21. Give two differences between user level and kernel 9 4 short difficult CO-2 D
level threads.

22. Consider the following set of processes with the length 15 7 length Very CO-2 N
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
of the CPU burst time given in millisecond. In the y difficult
priority column, lower number indicates higher
priority.

Proce Arrival CPU Priority


ss Time Burst
time

P1 0 8 3

P2 1 1 1

P3 2 2 3

P4 3 1 4

P5 4 5 2

Draw Gant chart illustrating the execution of these


processes using preemptive priority. What is the
average waiting time and average turnaround time of
this workload? Show the instants at which scheduling
decision is made, and draw state of the ready queue at
those instants.

23. With the help of neat diagram, explain Multi level 13 6 mediu moderat CO-2 D
feedback queue scheduling. State its advantage over m e
MLQ scheduling.

24. The process state transition diagram of an operating 4 2 short Difficul CO-2 D
system is as given below. t

Which of the following must be FALSE about the


above operating system? Justify your answer.

A. It is a multi-programmed operating system

B. It uses preemptive scheduling

C. It uses non-preemptive scheduling


Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
D. It is a multi-user operating system

25. In the following process state transition diagram for a 4 2 short Difficul CO-2 D
uniprocessor system, assume that there are always t
some processes in the ready state.

Now consider the following statements:

A. If a process makes a transition D, it would


result in another process making transition A
immediately.
B. A process in blocked state can make transition
E while another process is in running state.
C. The OS uses preemptive scheduling.
D. The OS uses non-preemptive scheduling.
Which of the above statements are TRUE? Justify your
answer.

26. Let the time taken to switch from user mode to kernel 4 2 short moderat CO-2 D
mode of execution be T1 while time taken to switch e
between two user processes be T2. Which of the
following is correct? Justify your answer.
A. T1 > T2
B. T1 = T2
C. T1 < T2
D. Nothing can be said about the relation between
T1 and T2

27. A process spends 30% of its execution time waiting for 6 3 short Very CO-2 N
completion of I/O operation. If there are 5 processes in difficult
memory at once, then what is the probability that CPU
is busy during life time of these processes? (Assume
all I/O operations are overlapped).

28. Considering the exponential average behaviour used to 4 2 short moderat CO-2 N
predict the next CPU burst. If α = 0.80 and Predicted e
Value of T0= 25 ms and previous (T0 , T1, T2, T3)
runs were as 10, 12, 15, 20. What is the predicted value
of T4 ?
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
29. For the processes listed in the following table, which 6 3 short moderat CO-2 D
of the following scheduling schemes will give the e
lowest average turnaround time? Justify your answer.

Process Arrival Time Processi


ng Time
A 0 3
B 1 6
C 4 4
D 6 2
A. SJF
B. RR with slice=2
C. FCFS
30. Draw the process state transition diagram. Enlist the all 15 7 mediu moderat CO-2 D
the situations in a multiprogramming system, in which m e
a CPU scheduler is invoked. Explain any three in brief.

31. Consider 3 CPU intensive processes, which require 9 4 short difficult CO-2 N
10,20 and 30 time units and arrive at time 0,2 and 6
respectively. How many context switches are needed,
if the operating system implements a shortest
remaining time first scheduling algorithm? Do not
count the context switches at time zero and at the end.

32. Consider a set of n tasks with known runtimes r1,r2, .... 4 2 short difficult CO-2 D
rn to be run on a Uniprocessor machine. Which of the
following processor scheduling algorithms will result
in the maximum throughput?
A round robin
B shortest job first
C Priority
D FCFS
Justify your answer.
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
1. III. Suppose that a disk drive has 200 cylinders numbered 0 8 lengt moderat CO-4 N
to 199. The drive is currently serving a request at hy e
cylinder 100, and the previous request was at cylinder
95. The queue of pending requests in FIFO order is 55,
58,39,18,90,160,150,38,184. Starting from the current
head position, what is the total distance (in cylinders)
that the disk arm moves to satisfy all the pending
requests for each of the following scheduling
algorithms?
i) FCFS ii) SSTF iii) SCAN iv) C-SCAN
iv) LOOK vi) C-Look.

2. Discuss various disk space allocation methods in brief 8 lengt moderat CO-4 D
and state advantages and disadvantages of each method. hy e

3. State whether the following statements are true or false 2 short difficult CO-4 D
with justification. each

i) Direct access to a file requires the file to


be made of fixed length logical records.
ii) In acyclic graph directory structure a
file may have multiple absolute paths.
iii) Internal fragmentation during allocation of
disk space to files cannot be avoided.
iv) Requests for the disk service can be
influenced by the file allocation method.
v) FAT allocation scheme can result in a
significant number of disk head seeks,
unless FAT is cached.
vi) A tree directory structure facilitates sharing
of files or directories.
4. Calculate the internal fragmentation (wastage of disk 2 short moderat CO-4 N
space) in bytes when a file of size 1234 bytes is stored e
in a file system with a disk block size of 512 bytes.

5. Consider a system that supports the strategies of 3 short difficult CO-4 D


contiguous, linked, and indexed allocation. What
strategy is best suited for each of the following file
type? Justify your answers.
i) The file is usually accessed sequentially, and the
file is relatively small.
ii) The file is large and usually accessed sequentially.
iii) The file is large and usually accessed randomly.

6. Suppose the head of a moving head disk with 200 6 medi moderat CO-4 N
tracks, numbered 0 to 199 is currently serving a request um e
at track 143 and has just finished a request at track 125.
If the queue of request is kept in the FIFO order
86,147,91,177,94,150,100,175,130. What is the total
head movement to satisfy these requests for the
following disk scheduling algorithms?
i) FCFS ii) SSTF iii) SCAN iv) C-SCAN iv)
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
LOOK vi) C-Look.

7. How is file sharing supported in acyclic graph 3 short difficult CO-4 D


directories? Explain with an example

8. Consider a file currently consisting of 100 blocks. 6 medi Very CO-4 N


Assume that the file control block (and the index block, um difficult
in the case of indexed allocation) is already in memory.
Calculate how many disk I/O operations are required for
contiguous, linked, and indexed (single-level) allocation
strategies, if, for one block, the following conditions
hold. In the contiguous-allocation case, assume that
there is no room to grow in the beginning, but there is
room to grow in the end. Assume that the block
information to be added is stored in memory.
a. The block is added at the beginning.
b. The block is added in the middle.
c. The block is added at the end.
d. The block is removed from the beginning.
e. The block is removed from the middle.
f. The block is removed from the end.

9. Why must the bitmap for file allocation be kept on mass 2 short difficult CO-4 D
storage, rather than in main memory?

10. Define the following terms with respect to disk drives 6 medi easy CO-4 D
um
i) Seek time ii) Rotational latency iii) disk
bandwidth iv) cylinder v) sector

11. With the help of neat schematic explain the working of 4 medi moderat CO-4 D
FAT (File Allocation Table) scheme of linked um e
allocation. Show used, unused and EOF entries in the
table.

12. Explain any two free-space management schemes. State 6 medi moderat CO-4 D
the advantages and disadvantages of each scheme. um e

13. State and explain different file access methods with neat 8 lengt moderat CO-4 D
diagrams. hy e

14. What is a file? Enlist typical file Attributes and 3 Short easy CO-4 D
operations.

15. What is the internal fragmentation for a file with 10 2 Short easy CO-4 D
logical records stored on it? The system is having 512
bytes disk block size and 130 bytes logical record size.

16. Disk requests come to disk driver for cylinders 4 short easy CO-4 N
10,22,20,2,40,6 and 38, in that order at a time when the
disk drive is reading from cylinder 20. The seek time is
6 ms per cylinder. Compute the total seek time if the
disk arm scheduling algorithm is First come first served
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
17. Consider a typical disk that rotates at 15000 rotations 4 Short difficult CO-4 N
per minute (RPM) and has a transfer rate of 50×10 6
bytes/sec. If the average seek time of the disk is twice
the average rotational delay and the controller’s transfer
time is 10 times the disk transfer time. What is the
average time (in milliseconds) to read or write a 512
byte sector of the disk ?

18. A disk has 200 tracks (numbered 0 through 199). At a 4 Short moderat CO-4 N
given time, it was servicing the request of reading data e
from track 120, and at the previous request, service was
for track 90. The pending requests (in order of their
arrival) are for track numbers.
30 70 115 130 110 80 20 25.
How many times will the head change its direction for
SSTF (Shortest Seek Time First) and FCFS (First Come
Fist Serve) scheduling policies?

19. Suppose the head of moving head disk with 200 tracks 8 lengt moderat CO-4 N
numbered 0 to 199 is currently serving the request at hy e
track 143 and the previous request serviced was at track
0. If queue of requests is kept in FIFO order 84, 147,
91, 150, 102, 17 130, then compute total head
movement to satisfy the requests for the following disk
scheduling algorithms.
(I) FCFS
(II) SS'I'F
(III) SCAN
(IV) LOOK

20. Why do some systems keep track of the type of a file, 2 short easy CO-4 D
while others leave it to the user or simply do not
implement multiple file types? Which system is
“better?”

21. One problem with contiguous allocation is that the user 4 short Very CO-4 D
must preallocate enough space for each file. If the file difficult
grows to be larger than the space allocated for it, special
actions must be taken. One solution to this problem is to
define a file structure consisting of an initial contiguous
area (of a specified size). If this area is filled, the
operating system automatically defines an overflow
area that is linked to the initial contiguous area. If the
overflow area is filled, another overflow area is
allocated. Compare this implementation of a file with
the standard contiguous and linked implementations.

22. Consider a system that supports the strategies of 3 Short difficult CO-4 D
contiguous, linked, and indexed allocation. What
criteria should be used in deciding which strategy is
best utilized for a particular file?
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
23. What is file control Block ? Explain its components in 2 Short easy CO-4 D
detail.

24. What do you mean by free space management in disks? 7 Lengt moderat CO-4 D
State any four methods to handle free space. Discuss hy e
any two of them in detail.

25. What is sector queuing? What is the advantage of it ? 3 Short difficult CO-4 D

26. Define the following terms w. r. t. magnetic disk 5 medi moderat CO-4 D
drives :- um e
(i) Cylinder.
(ii) Seek time.
(iii) Rotational latency.
(iv) Disk Bandwidth.
(v) Sector

27. Discuss different variations of SCAN algorithms. Also 7 Lengt moderat CO-4 D
explain how the disadvantages of each of these hy e
algorithms in eliminated in its next version.

28. A hard disk has 63 sectors per track, 10 platters each 4 short difficult CO-4 N
with 2 recording surfaces and 1000 cylinders. The
address of a sector is given as a triplet (c, h, s) , where c
is the cylinder number, h is the surface number and s is
the sector number. Thus, the 0th sector is addressed as
(0,0,0), the 1st sector as (0,0,1), and so on. Find the
sector number for the address (400,16,29) .

29. A hard disk with a transfer rate of 10 Mbytes/second is 4 short Very CO-4 N
constantly transferring data to memory using DMA. difficult
The processor runs at 600 MHz and takes 300 and 900
clock cycles to initiate and complete DMA transfer
respectively. If the size of the transfer is 20 Kbytes,
what is the percentage of processor time consumed for
the transfer operation?

30. Consider a storage disk with 4 platters (numbered as 0, 5 medi difficult CO-4 N
1, 2 and 3), 200 cylinders (numbered as 0, 1, … , 199), um
and 256 sectors per track (numbered as 0, 1, … , 255).
The following 6 disk requests of the form [sector
number, cylinder number, platter number] are received
by the disk controller at the same time: [120, 72, 2] ,
[180, 134, 1] , [60, 20, 0] , [212, 86, 3] , [56, 116, 2] ,
[118, 16, 1]. Currently the head is positioned at sector
number 100 of cylinder 80 and is moving towards
higher cylinder numbers. The average power dissipation
in moving the head over 100 cylinders is 20 milliwatts
and for reversing the direction of the head movement
once is 15 milliwatts. Power dissipation associated with
rotational latency and switching of head between
different platters is negligible. Find the total power
consumption in milliwatts to satisfy all of the above
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
disk requests using the Shortest Seek Time First disk
scheduling algorithm.

31. Free disk space can be used to keep track of using a free 2 Short Very CO-4 D
list or a bit vector. Disk addresses require b bits. For a difficult
disk with B blocks of size S bits, of which F are free,
state the condition under which the free list uses less
space than the bit vector.
A. Fd/S < B/S
B. Fd/S > B/S
C. Fd/S = B/S
D. Fd/S < B*S
E. None
Justify your answer.

32. In a file allocation system, which of the following 2 Short difficult CO-4 D
allocation scheme(s) can be used if no external
fragmentation is allowed ?
1. Contiguous 2. Linked 3. Indexed
A. 1 and 3 only
B. 2 only
C. 3 only
D. 2 and 3 only
Justify your answer.
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
1. IV. Given memory partitions of 100 KB, 500KB, 200KB, 15 7 medi moderat CO-5 N
300KB and 600KB (in order), how would each of the um e
first fit, best fit and worst fit algorithms places
processes of 212 KB, 417 KB, 112 KB and 426KB (in
order)? Which algorithm makes the most efficient use
of memory? Also show the free list after each
allocation.

2. Differentiate between Static and Dynamic Partitioning 4 2 short easy CO-5 D


of main memory.

3. With the help of neat schematic explain the 11 5 medi easy CO-5 D
segmentation scheme of memory management. um

4. Consider a paging system with the page table stored in 9 4 short medium CO-5 N
memory.
i) If a memory reference takes 100ns, how long does a
paged memory reference take?
ii) If we add associative registers (TLB), and 98% of all
page table references are found in associative registers,
what is the effective memory access time? Assume that
searching a page table in the associative registers takes
20ns.

5. State whether the following statements are true or false 4 2 medi difficult CO-5 D
& give a brief justification each um
i. Paging systems reduce effective memory
bandwidth by a factor of 1/2.
ii. Internal fragmentation of main memory cannot be
eliminated completely by any memory
management technique.
iii. Real time systems have little or no support for
virtual memory.
iv. Worst fit algorithm doesn't make a sense as an
algorithm for allocation of memory partitions in
static partitioning.
v. Table fragmentation is maximum in combined
systems (paged segmentation).
vi. Translation lookaside buffer (TLB) memory
improves effective memory access time of the
main memory.
6. Give two differences between logical and physical 4 2 short easy CO-5 D
addresses

7. Assume that you have a page-reference string for a 4 2 short difficult CO-5 D
process with m frames (initially all empty). The page-
reference string has length p; n distinct page numbers
occur in it. Answer these questions for any page-
replacement algorithms:
i) What is a lower bound on the number of page faults?
ii) What is an upper bound on the number of page
faults?
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
8. When do page faults occur? With the help of neat 11 5 medi moderat CO-5 D
diagram describe the actions taken by the OS when um e
page fault occurs.

9. Draw a diagram showing segmentation hardware. 11 5 medi moderat CO-5 D


Explain how address translation from (logical to um e
physical) is done in segmentation.

10. What are the different types of main memory 9 4 short moderat CO-5 D
fragmentation? Under what circumstances does each e
occur?

11. What is Belady’s Anomaly? Prove that the following 11 5 medi moderat CO-5 N
memory reference string suffers from Belady’s um e
Anomaly with FIFO algorithm:
A, B, C, D, A, B, E, A, B, C, D, E. (Note: Take the
number of frames =3 and then 4).

12. With the help of neat schematic explain the address 11 5 medi moderat CO-5 D
translation in pure segmentation. um e

13. State the advantages of pure segmentation scheme over 6 3 short moderat CO-5 D
pure paging scheme. e

14. Consider a paging system with TLB to store frequently 9 4 medi moderat CO-5 N
used entries in the page table. The system has 90% hit um e
ratio, 20 nano-seconds time to search the associative
registers, 700 nano-seconds time to access memory.
Find the effective memory access time for this paging
system.

15. How many page faults will occur for the following 13 6 medi moderat CO-5 N
reference string using FIFO, LRU and optimal page um e
replacement algorithms? Assume NO. of page frames=
3 and the page reference string as : 1, 2, 3 ,4, 2, 1 ,5 ,6 ,
2 , 1 ,2, 3 ,7,6 , 3 ,2, 1

16. With the help of suitable example, describe a 9 4 medi difficult CO-5 D
mechanism by which one segment could belong to the um
address space of two different processes.

17. Consider following segment table: 6 3 short moderat CO-5 D


e

What are the logical addresses for following physical


addresses?
i) 2345 ii) 100

Segme Base Length


nt

0 219 600
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
1 2300 14

2 90 100

3 13127 580

4 1952 96

18. Why are page sizes always powers of 2? 6 3 short difficult CO-5 D

19. Consider the following page-replacement algorithms. 4 2 short difficult CO-5 D


Rank these algorithms on a four-point scale from “bad
(Rank 4 )” to “perfect( Rank 1)” according to their
page-fault rate. Separate those algorithms that suffer
from Belady’s anomaly from those that do not.

i) LRU ii) FIFO iii) Optimal


iv) CLOCK

Rank Algorithm Suffer from


Belady’s
anomaly
(YES/NO)

20. What is meant by Virtual Memory? Explain with neat 18 8 long moderat CO-5 D
diagrams the mechanism of virtual memory e
management using Demand Paging.

21. Consider a logical address space of 8 pages of 1024 6 3 Short moderat CO-5 D
words mapped into memory of 32 frames. e
i. How many bits are there in the logical address?
ii. How many bits are there in physical address?
iii. What is the linear address (in decimal) of physical
memory for the item stored at logical address given by
(3,100) if page 3 is stored in frame 17?

22. State the advantages of pure segmentation scheme over 6 3 Short moderat CO-5 D
pure paging scheme. e

23. Given memory of 1024KB with partitions (initially all 6 3 short moderat CO-5 N
free) of 100 KB, 424KB, 200KB, 300KB (in order), e
then what will be the free list after application of the
worst fit algorithm on the processes of sizes 24 KB, 430
KB, 120 KB and 320KB (in order)?

24. Given memory of 2200 KB with free partitions of 200 6 3 short moderat CO-5 N
KB, 600KB, 300KB, 400KB and 700KB (in order), e
then what will be the free list after application of the
best fit algorithm on the processes of sizes 222 KB, 427
KB, 122 KB and 436KB (in order)?
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
25. Find the number of page faults for the following 13 6 medi moderat CO-5 N
memory reference string using a) FIFO, b) LRU and c) um e
Optimal algorithms, with number of page frames
allocated =4.
String: 1,1,2,3,3,3,4,1,2,2,5,1,2,3,4,5,5.

26. The page trace of a running application is given in hex 13 6 medi moderat CO-5 N
as 144, 0A1, 144, 263, 144, 168, 144, 0A1, 179, 0A1, um e
0A2, 263. Assuming that the process is initially
unloaded find the number of page faults for a) FIFO, b)
LRU and c) Optimal algorithms, with 3 page frames.

27. Consider the following page reference string 4, 3, 2, 1 13 6 medi difficult CO-5 N
4, 3, 5, 4, 3, 2, 1, 5. Assuming three page frames, how um
many page faults would occur for LRU and OPTIMAL
algorithms. Why optimal algorithm gives least number
of page faults? Explain.

28. Consider a CPU which generates 32 bit Logical 6 3 Short medium CO-5 N
address, with a page size of 4 KB, and let physical
memory size be 256 MB. Find :—
i) Number of bits to represent page offset and page
number
ii) Total number of frames
iii) Length of Physical Address (in Bits)
iv) Number of bits to represent page offset and frame
number
v) Maximum size of Logical address space
vi) Maximum size of Physical address space.

29. Explain through a diagram, the principles of address 18 8 long difficult CO-5 D
translation in combined segmentation and paging. What
is the drawback of this translation scheme?

30. With the help of suitable example, describe a 13 6 long difficult CO-5 D
mechanism by which one segment could belong to the
address space of two different processes.

31. Define page fault and explain why does it occur? 4 2 Short easy CO-5 D

32. Discuss a technique to reduce the effective memory- 11 5 medi moderat CO-5 D
access time in a paged system using translation look um e
aside Buffer (TLB).

33. Enlist different types of fragmentations that occur in 18 8 long moderat CO-5 D
various memory management schemes. Explain how e
each of these fragmentations can be
removed/minimized by memory management schemes.

34. What is the effect of allowing two entries in a page 6 3 short Very CO-5 D
table to point to the same page frame in memory? difficult
Explain how this effect could be used to decrease the
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
amount of time needed to copy a large amount of
memory from one place to another. What effect would
updating some byte on the one page have on the other
page?

35. Consider the two-dimensional array A: 11 5 medi Very CO-5 N


um difficult
int A[][] = new int[100][100];
where A[0][0] is at location 200, in a paged memory
system with pages of size 200. A small process is in
page 0 (locations 0 to 199) for manipulating the matrix;
thus, every instruction fetch will be from page 0.
For three page frames, how many page faults are
generated by the following array-initialization loops,
using LRU replacement, and assuming page frame 1
has the process in it, and the other two are initially
empty?
a. for (int j = 0; j < 100; j++)
for (int i = 0; i < 100; i++)
A[i][j] = 0;
b. for (int i = 0; i < 100; i++)
for (int j = 0; j < 100; j++)
A[i][j] = 0;

36. Consider a demand-paged computer system where the 13 6 medi Very CO-5 N
degree of multiprogramming is currently fixed at four. um difficult
The system was recently measured to determine
utilization of CPU and the paging disk. The results are
one of the following alternatives. For each case, what is
happening? Can the degree of multiprogramming be
increased to increase the CPU utilization? Is the paging
helping?
a. CPU utilization 13 percent; disk utilization 97
percent
b. CPU utilization 87 percent; disk utilization 3 percent
c. CPU utilization 13 percent; disk utilization 3 percent

37. Which of the following programming techniques and 15 7 medi Very CO-5 D
structures are “good” for a demand-paged environment? um difficult
Which are “not good”? Explain your answers.
a. Stack
b. Hashed symbol table
c. Sequential search
d. Binary search
e. Pure code
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
f. Vector operations
g. Indirection

38. You have devised a new page-replacement algorithm 6 3 short Very CO-5 D
that you think may be optimal. In some unusual test difficult
cases, Belady’s anomaly occurs. Is the new algorithm
optimal? Explain your answer.

39. Explain the advantages and disadvantages of segmented 9 4 short CO-5 D


and paged implementation of virtual memory. difficult
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
1. V. List and compare various methods of implementing an access 1 8 lengt modera CO-6 D
matrix. 8 hy te

2. Why is it difficult to protect a system in which users are 4 2 short difficult CO-6 D
allowed to do their own I/O?

3. Explain how protection could be achieved using access list and 9 4 medi modera CO-6 D
capability list. um te

4. Explain access matrix with copy, owner and control type of 9 4 medi modera CO-6 D
operation. um te

5. What are the goals of protection? 4 2 Short easy CO-6 D

6. What are the security problems? 4 2 Short easy CO-6 D

7. Capability lists are usually kept within the address space of the 6 3 short difficult CO-6 D
user. How does the system ensure that the user cannot modify
the contents of the list?

8. What are the main difference between capability lists and 6 3 Short modera CO-6 D
access lists? te

9. What protection problems may arise if a shared stack is used for 6 3 short difficult CO-6 D
parameter passing?

10. In a ring-protection system, level 0 has the greatest access to 4 2 short difficult CO-6 D
objects, and level n (greater than zero) has fewer access rights.
The access rights of a program at a particular level in the ring
structure are considered as a set of capabilities. What is the
relationship between the capabilities of a domain at level j and a
domain at level i to an object (for j > i)?

11. Differentiate between protection and security. 4 2 short easy CO-6 D

12. Consider a computing environment where process is given the 4 2 short difficult CO-6 D
privilege of accessing an object only 'n' times. Suggest a scheme
for implementing this policy.

13. What is stack overflow? Explain how this condition may 1 5 Medi difficult CO-6 D
compromise the security of the computer system. How can 1 um
stack overflow attack be avoided?

14. Explain the public key encryption technique. 9 4 medi modera CO-6 D
um te

15. Explain the similarities and differences between viruses and 6 3 Short modera CO-6 D
worms. te

16. What is a Trojan horse? 4 2 short easy CO-6 D

17. Explain the four levels of security measures that must be taken 1 6 medi modera CO-6 D
to protect a computer system. 3 um te

18. Enlist and explain the requirements of computer security. 9 4 medi modera CO-6 D
um te

19. Explain how a password is vulnerable to malicious uses. 9 4 medi modera CO-6 D
um te
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
20. Discuss in brief the threats to security in any computing 1 6 medi modera CO-6 D
environment. 3 um te

21. Explain in brief encryption as a tool for computer security. 6 3 Short modera CO-6 D
te

22. On some systems the user passwords are stored in an encrypted 6 3 Short Very CO-6 D
form using a one-way algorithm, i.e. there is no algorithm for difficult
reversing the encryption process and getting the password back.
Explain how the system will verify user password. Also explain
why one-way algorithm is used for passwords.

23. How can it be detected that your password has been 4 2 short difficult CO-6 D
compromised?

24. Suppose a file containing sensitive data is deleted and its data 4 2 short difficult CO-6 D
blocks are allocated to some other files. Thus it is possible for
some malicious user to access the sensitive data. suggest a
suitable remedy for this problem.

25. State some ways in which in which passwords can be guessed? 4 2 Short modera CO-6 D
te

26. Enlist and explain forms of accidental and malicious security 1 6 lengt modera CO-6 D
violations. 3 hy te

27. What are one time passwords? Explain how a scheme of OTP 4 2 short modera CO-6 D
prevents improper authentication due to password exposure. te

28. What are salted passwords? How does this scheme defend 9 4 medi modera CO-6 D
against dictionary-based attacks? um te

29. How does the principle of least privilege aid in the creation of 9 4 medi modera CO-6 D
protection systems? How can systems that implement the um te
principle of least privilege still have protection failures that lead
to security violations?

30. Define deadlock. State and explain the necessary conditions for 1 5 medi modera CO-6 D
deadlock to occur. 1 um te
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
31. Consider the following snapshot of the system indicating 1 6 medi modera CO-6 N
resource allocation. Presentably available resources are 3 um te
(1,5,2,0).

Complete the table below with comments and answer the


following questions using the banker’s algorithm
i) What is the content of the matrix need?

Proc Allocatio Max Need =Max- Wor Co


ess n Alloc k m
(Ava me
ABCD nt
ABC ilabl
ABCD D e)

AB
CD

P0 0 01 2 0 0 1
2

P1 1 0 0 0 1 7 5
0

P2 1 3 5 4 2 3 5
6

P3 0 6 3 2 0 6 5
2

P4 0 0 1 4 0 6 5
6

ii) Is the system in a safe state?

32. A computer has 6 tape drives, with n process competing for 6 3 Short Very CO-6 D
them. Each process may need two drives. What is the maximum difficult
value of n for which the system is deadlock free? Justify your
answer.

33. Write and explain Banker’s algorithm for deadlock avoidance. 1 7 long modera CO-6 D
5 te
Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
34. How Deadlock prevention technique prevents deadlock in 9 4 short modera CO-6 D
general and by denying circular wait in particular? te
Illustrate with an example.

35. Draw the wait for graph for the following RAG and comment 1 8 long Very CO-6 D
on the system state. 8 difficult

36. Enlist different methods of handling deadlocks. Explain why 9 4 short modera CO-6 D
many modern OS prefer to ignore the deadlock problem. te

37. State and explain resource request algorithm used for deadlock 1 5 Medi modera CO-6 D
avoidance. 1 um te

38. What is a safe state? State and explain banker’s safety algorithm 1 6 Medi modera CO-6 D
with the data structures used in this algorithm. 3 um te

39. In a real computer system, neither the resources available nor 1 6 medi difficult CO-6 D
the demands of processes for resources are consistent over long 3 um
periods (months). Resources break, or the replaced, new
processes come and go, new resources are bought and added to
the system. If deadlock is controlled by the Banker's algorithm,
which of the following changes can be made safely (without
introducing the possibility of deadlock), and under what
circumstances? Justify.
(a) Increase Available (new resources added)
(b) Decrease Available (resource permanently removed from
system)
(c) Increase Max for one process (the process needs more
resources
than allowed, it may want more)
(d) Decrease Max for one process (the process decides it does
not need that many resources)
(e) Increase the number of processes
(f) Decrease the number of processes.

same resource type. Each process can request a maximum of 𝐾


40. Consider a system with 3 processes that share 4 instances of the 6 3 Short Very CO-6 D
difficult

only one at a time. What is the largest value of 𝐾 that will


instances. Resource instances can be requested and released

always avoid deadlock?


Yeshwantrao Chavan College of Engineering
(An Autonomous Institution Affiliated to Rashtrasant Tukadoji Maharaj Nagpur University)
Hingna Road, Wanadongri, Nagpur.
41. Consider a system consisting of four resources of the same 6 3 Short difficult
type that are shared by three processes, each of which
needs at most two resources. Show that the system is
deadlock free.

You might also like