1.
What is OS, types, function:
An Operating System (OS) is system software that manages computer hardware, software
resources, and provides common services for computer programs. Types include: Batch OS,
Time-Sharing OS, Distributed OS, Network OS, Real-Time OS. Functions: process management,
memory management, file system management, device management, security, and user interface.
2. Structure of OS, Kernel, System Call:
The OS structure includes layers such as user interface, system libraries, and the kernel. The kernel
is the core part managing system resources. System calls are interfaces between user programs
and the OS kernel for operations like file handling, process control, etc.
3. Process, Process States, PCB, Programs vs Process, Thread vs Process:
A process is an executing instance of a program. Process states: new, ready, running, waiting,
terminated. PCB (Process Control Block) stores process information. Programs are passive;
processes are active. Threads are lightweight processes that share resources.
4. IPC, Preemptive vs Non-Preemptive Scheduling:
IPC (Inter-Process Communication) allows processes to communicate and synchronize. Preemptive
scheduling allows the OS to suspend a process; non-preemptive doesn't. Preemptive is better for
responsive systems.
5. Race Condition, CPU Scheduling Criteria:
Race condition occurs when multiple processes access shared data concurrently and the result
depends on timing. CPU scheduling criteria: CPU utilization, throughput, turnaround time, waiting
time, response time.
6. CPU Scheduling Algorithms and Problems:
Algorithms include FCFS (First Come First Serve), SJF (Shortest Job First), Priority Scheduling,
Round Robin, Multilevel Queue. Problems include starvation and convoy effect.
7. Semaphore, Critical Section, Monitor:
Semaphore is a signaling mechanism to control access to a resource. Critical section is a code
segment that accesses shared resources. Monitor is a high-level synchronization construct that
controls access to critical sections.
8. Reader-Writer Problem, Dining Philosopher Problem:
Reader-writer problem ensures multiple readers can read at the same time but writers need
exclusive access. Dining Philosopher problem is a synchronization problem involving resource
sharing to avoid deadlock.
9. Deadlock, Conditions, Banker's Algorithm, Safety Algorithm:
Deadlock occurs when processes wait indefinitely for resources. Conditions: mutual exclusion, hold
and wait, no preemption, circular wait. Banker's algorithm is used to avoid deadlock by allocating
resources safely.
10. Page Replacement Problem:
Occurs in virtual memory management when a page needs to be replaced. Algorithms: FIFO, LRU,
Optimal. Goal is to minimize page faults.
11. Paging, Disk Scheduling (SSTF, SCAN, FCFS):
Paging is a memory management scheme eliminating fragmentation by dividing memory into fixed
pages. Disk Scheduling: FCFS (first come first serve), SSTF (shortest seek time first), SCAN
(elevator algorithm).
12. RAID, Paging, Segmentation, Memory Allocation (FF, BF, WF), Fragmentation, Demand
Paging, Cryptography:
RAID (Redundant Array of Independent Disks) improves performance/redundancy. Segmentation
divides memory into segments. Memory allocation: FF (first fit), BF (best fit), WF (worst fit).
Fragmentation: internal and external. Demand paging loads pages into memory only when needed.
Cryptography secures data through encryption/decryption.