📘 PAPER 5 – OPERATING SYSTEM (UNIT 1 – INTRODUCTION & PROCESS MANAGEMENT) university of allahabad

 

📘 PAPER 5 – OPERATING SYSTEM

🔴 UNIT 1 – INTRODUCTION & PROCESS MANAGEMENT


1️⃣ Introduction to Operating System

✅ What is an Operating System (OS)?

An Operating System is system software that:

  • Acts as an interface between user and hardware

  • Manages computer resources

  • Controls execution of programs


✅ Functions of Operating System

✔ Process management
Memory management
File management
Device management
✔ Security & protection
User interface


✅ Examples of Operating Systems


2️⃣ Types of Operating Systems

🔹 1. Batch Operating System

  • Jobs executed in batches

  • No user interaction

🔹 2. Multiprogramming OS

🔹 3. Time Sharing OS

🔹 4. Real-Time OS

  • Immediate response

  • Used in medical & industrial systems


3️⃣ Structure of Operating System

🔹 Layered Structure

  • Hardware at bottom

  • User interface at top

  • Easy to debug and maintain


4️⃣ Process Concept

✅ Process

A process is a program in execution.


Components of a Process


5️⃣ Process States

🔹 Five States of Process

StateDescription
NewProcess created
ReadyWaiting for CPU
RunningExecuting
WaitingWaiting for I/O
TerminatedFinished

6️⃣ Process Control Block (PCB)

Definition:

PCB stores all information about a process.

Contains:


7️⃣ Process Scheduling

Types of Scheduling:

  1. Long-term scheduler

  2. Short-term scheduler

  3. Medium-term scheduler


8️⃣ CPU Scheduling Algorithms


🔹 1. FCFS (First Come First Serve)

✔ Simple
❌ High waiting time


🔹 2. SJF (Shortest Job First)

✔ Minimum waiting time
Starvation problem


🔹 3. Priority Scheduling

  • Process with highest priority executes first


🔹 4. Round Robin


9️⃣ Process Synchronization

Problem:

When multiple processes access shared data → inconsistency occurs.


🔹 Critical Section Problem

Requirements:

✔ Mutual Exclusion
✔ Progress
✔ Bounded Waiting


🔟 Semaphores

Definition:

Semaphore is a synchronization tool.

Types:

  1. Binary Semaphore

  2. Counting Semaphore


Operations:

wait() signal()

1️⃣1️⃣ Deadlock

Definition:

Deadlock occurs when:

  • Each process waits for a resource held by others


Conditions of Deadlock:

  1. Mutual Exclusion

  2. Hold and Wait

  3. No Preemption

  4. Circular Wait


Deadlock Handling:

✔ Prevention
✔ Avoidance
✔ Detection
✔ Recovery


1️⃣2️⃣ Inter-Process Communication (IPC)

Methods:

  • Pipes

  • Message Queues

  • Shared Memory

  • Signals


📌 EXAM IMPORTANT QUESTIONS (UNIT 1)

✔ Explain process states
✔ Explain CPU scheduling algorithms
✔ Explain semaphore
✔ What is deadlock? Explain conditions
✔ Explain PCB
✔ Difference between process and program

Comments

Popular Posts