0% found this document useful (0 votes)
3 views

Operating System

The document contains a series of questions and answers related to operating systems, including definitions of key terms, explanations of concepts like deadlock, demand paging, and process management, as well as details on system programs and disk scheduling. It also covers topics such as fragmentation, I/O hardware, and synchronization problems. Additionally, it discusses methods for deadlock recovery and includes calculations for scheduling algorithms.

Uploaded by

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

Operating System

The document contains a series of questions and answers related to operating systems, including definitions of key terms, explanations of concepts like deadlock, demand paging, and process management, as well as details on system programs and disk scheduling. It also covers topics such as fragmentation, I/O hardware, and synchronization problems. Additionally, it discusses methods for deadlock recovery and includes calculations for scheduling algorithms.

Uploaded by

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

Q1) Attempt any Eight of the following.

[2×8=16]
a) Define the term operating system.
An Operating System (OS) is system software that manages computer
hardware and software resources and provides common services for
computer programs.
b) Define system program.
A system program is software designed to provide a platform for other
software. Examples include operating systems, compilers, and device
drivers.
c) Which scheduler controls the degree of multiprogramming?
The Long-Term Scheduler (Job Scheduler) controls the degree of
multiprogramming by deciding how many processes should be in
memory at a time.
d) What is Turn-Around Time?
Turnaround Time (TAT) is the total time taken by a process from
submission to completion.
Formula:
TAT = Completion Time - Arrival Time
e) What is meant by Deadlock?
A deadlock is a situation where two or more processes are unable to
proceed because each is waiting for a resource held by the other.
f) What is demand paging?
Demand paging is a memory management scheme in which pages are
loaded into memory only when they are needed, reducing memory
usage.
g) List any four attributes of files.
1. File Name – Name of the file.
2. File Type – Type of the file (e.g., .txt, .exe).
3. File Size – Size of the file in bytes.
4. File Permissions – Access rights (read, write, execute).
h) What do you mean by seek time in Disk Scheduling?
Seek time is the time taken by the disk arm to move the read/write
head to the correct track where the required data is stored.
i) What does FIFO and MFU stand for?
• FIFO (First In First Out) – Oldest page in memory is replaced first.
• MFU (Most Frequently Used) – Page with the highest frequency
of access is replaced first.
j) Define Rollback.
Rollback is a mechanism used to revert a system to a previous safe state
in case of failure, ensuring consistency.

Q2) Attempt any four of the following. [4×4=16]


a) List and explain services provided by the operating system.
1. Process Management – Handles process creation, scheduling, and
termination.
2. Memory Management – Allocates and deallocates memory space.
3. File Management – Manages file creation, deletion, and access.
4. Device Management – Controls hardware devices via drivers.
5. Security & Access Control – Protects system from unauthorized
access.
6. Error Detection & Handling – Detects and responds to errors.
b) Explain Process Control Block (PCB) with diagram.
PCB is a data structure that contains information about a process.
Contents of PCB:
• Process ID
• Process State
• Program Counter
• CPU Registers
• Memory Limits
• I/O Status
(Diagram should be included)
c) Explain ‘Dining Philosopher’ Synchronization problem.
A classical synchronization problem where five philosophers sit at a
table with five chopsticks, and they need to pick up two chopsticks to
eat, leading to possible deadlock.
d) What is fragmentation? Explain its types in detail.
Fragmentation is a condition where free memory is wasted.
1. Internal Fragmentation – Memory is allocated in fixed blocks,
leading to unused space within a block.
2. External Fragmentation – Free memory is divided into small holes
scattered across memory.
e) Describe I/O Hardware with its type of I/O devices.
I/O hardware consists of input and output devices that facilitate
communication between the computer and the user.
Types:
1. Input Devices – Keyboard, Mouse, Scanner
2. Output Devices – Monitor, Printer, Speaker
3. Storage Devices – Hard Disk, SSD, Flash Drive

Q3) Attempt any four of the following. [4×4=16]


a) Explain various types of system programs.
1. File Management Programs – Handle file creation, deletion (e.g.,
Windows Explorer).
2. Text Editors – Allow editing of text (e.g., Notepad).
3. Compilers and Interpreters – Convert source code to executable
format.
4. Device Drivers – Enable communication between OS and
hardware.
b) Explain Indexed Allocation in detail.
Indexed allocation stores file pointers in an index block rather than
scattering them across memory. This avoids fragmentation issues.
c) Disk Scheduling - SSTF Calculation
Applying Shortest Seek Time First (SSTF) scheduling to the given
request queue:
Request queue: 15, 27, 137, 18, 150, 65, 194
Current head position: 128
(Solution involves calculating shortest distance and total head
movement.)
d) List any two types of Multiprocessor.
1. Symmetric Multiprocessing (SMP) – All processors share memory
and OS equally.
2. Asymmetric Multiprocessing (AMP) – One processor controls
system, others follow instructions.
e) Preemptive SJF Scheduling Calculation
(Solution involves calculating waiting time and turnaround time for each
process and finding averages.)

Q4) Attempt any four of the following. [4×4=16]


a) Banker's Algorithm for Deadlock Detection
Given Allocation, Max, and Available matrices, determine if the system
is in a safe state.
(Solution involves step-by-step checking of available resources and
process execution order.)
b) Explain different methods for recovery from deadlock.
1. Process Termination – Kill one or more processes.
2. Resource Preemption – Take resources from one process and
allocate to another.
3. Rollback – Revert to a safe state.
c) Page Replacement - FIFO & LRU Calculation
Given reference string: 4, 7, 6, 1, 7, 6, 1, 2, 7, 2 with 3 frames
(Solution involves tracking page faults using FIFO and LRU methods.)
d) Advantages and Disadvantages of Linked Allocation
Advantages:
1. No external fragmentation.
2. Efficient use of disk space.
Disadvantages:
1. Slow access time (requires sequential traversal).
2. Extra storage needed for pointers.
e) Define Logical and Physical Address.
• Logical Address – Address generated by the CPU (virtual address).
• Physical Address – Actual address in memory after translation by
MMU.

Q5) Write short note on any Two of the following. [2×3=6]


a) What is Interrupt?
An interrupt is a signal from hardware or software that temporarily
stops the execution of a program to handle a special event.
b) What is a Medium-Term Scheduler?
A scheduler that temporarily removes processes from memory
(swapping) to improve CPU performance.
c) Explain Semaphores and Its Types.
Semaphores are synchronization tools used to control access to shared
resources.
Types:
1. Binary Semaphore – Can be 0 or 1 (mutex locks).
2. Counting Semaphore – Can have multiple values, used for
resource pools.

You might also like