Operating System — Complete Study Notes
Simple, exam-focused notes for SSC, Banking (IBPS/SBI/RBI), Railway (RRB), UPSC, and other government exams. Built for fast learning and last-minute revision.
1 OS Basics & Definition
The single most common starting topic in every computer-awareness section.
Definition
An Operating System (OS) is system software that acts as an interface between the user and computer hardware. It manages all hardware and software resources and lets the user run programs. Without an OS, a computer cannot function.
- OS is the first program loaded into memory after booting and the last to close at shutdown.
- It is also called a resource manager or master control program.
- It runs in kernel mode (privileged), while user apps run in user mode.
Common Examples (memorise the maker)
| OS | Made By | Used In | Type |
|---|---|---|---|
| Windows | Microsoft | PCs / Laptops | GUI, Desktop |
| Linux | Linus Torvalds (open source) | Servers, supercomputers | Open-source, Multi-user |
| macOS / iOS / iPadOS | Apple | Mac, iPhone, iPad | Unix-based |
| Android | Smartphones | Linux-kernel based, Mobile | |
| UNIX | Bell Labs | Servers, workstations | Multi-user |
| MS-DOS | Microsoft | Old PCs | CLI, Single-user |
| Chrome OS | Chromebooks | Linux-based, Cloud |
Exam Tip The most-used desktop OS is Windows; the most-used mobile OS in the world is Android; servers/supercomputers mostly run Linux/Unix. These three facts appear repeatedly.
2 Functions of an Operating System
| Function | What it does | Example |
|---|---|---|
| Process Management | Creates, schedules & ends running programs | Chrome + Word open together |
| Memory Management | Allocates & frees RAM for programs | Gives memory to each app |
| File Management | Stores, names, organises files/folders | Create, copy, delete, rename |
| Device (I/O) Management | Controls input/output via drivers | Keyboard, printer, mouse |
| Security & Protection | Controls access & protects data | Passwords, permissions |
| User Interface | Lets user interact | GUI icons / CLI commands |
| Error Detection | Finds & reports problems | “Not responding” message |
| Resource Allocation | Shares CPU, memory & devices fairly | CPU time-sharing |
Remember A quick way to recall functions: “PMFDS-URE” → Process, Memory, File, Device, Security, User-interface, Resource-allocation, Error-handling.
3 Components: Kernel & Shell
Kernel The core / heart of the OS. It directly controls hardware, CPU, memory and devices. It always stays in memory.
Shell The interface between the user and the kernel. It takes user commands and passes them to the kernel (e.g. command interpreter in Linux/DOS).
Types of Kernel (frequently asked)
| Kernel Type | Idea | Example |
|---|---|---|
| Monolithic | Whole OS runs in kernel space; fast but large | Linux, UNIX |
| Microkernel | Only basics in kernel; services in user space; stable & secure but slower | QNX, Minix, L4 |
| Hybrid | Mix of both | Windows NT, macOS (XNU) |
Exam Tip Other key terms: Bootloader (loads OS into memory), Device Driver (software that controls a hardware device), System Call (the way a program requests a service from the OS, e.g. fork(), read(), write()).
4 Types of Operating Systems
| Type | Meaning | Example |
|---|---|---|
| Batch OS | Similar jobs grouped & run in batches; no user interaction | Old payroll / bank processing |
| Time-Sharing OS | Many users share CPU using small time slices | Mainframes, Multics |
| Real-Time OS (RTOS) | Gives output within a strict time limit | Flight control, missiles, ATMs, medical devices |
| Distributed OS | Many connected computers act as one system | LOCUS, cloud systems |
| Multi-user OS | Many users use one system together | UNIX, Linux |
| Multiprocessing OS | Uses two or more CPUs together | Servers, modern PCs |
| Mobile OS | OS for smartphones/tablets | Android, iOS |
| Network OS | Manages computers on a network | Windows Server, Novell NetWare |
| Embedded OS | Runs inside dedicated small devices | VxWorks, washing machines, smart TVs |
Common Trap RTOS is the one with guaranteed/immediate response — used in flight control, ATMs and medical equipment. Don’t confuse it with Distributed OS (multiple computers as one).
5 Process Management & Threads
Process A program in execution (a running program). A thread is the smallest unit of execution — a lightweight part of a process.
Process States
NEW → READY → RUNNING → TERMINATED
↑ │
└──────────┘ (back to READY when time slice ends)
RUNNING → WAITING/BLOCKED (for I/O) → READY
- PCB (Process Control Block): stores all info about a process (ID, state, registers, priority).
- Context switching: CPU saves one process’s state and loads another’s.
- fork(): system call used to create a new (child) process.
- Daemon: a background process (e.g. antivirus scan, print service).
Multi- terms (very frequently confused)
| Term | Meaning | Example |
|---|---|---|
| Multitasking | One CPU runs many tasks (by switching fast) | Music + browsing |
| Multiprocessing | Many CPUs work at the same time | Quad-core processor |
| Multithreading | Many threads run inside one program | Download + scroll in a browser |
| Multiprogramming | Many programs kept in memory to keep CPU busy | Improves CPU utilisation |
6 CPU Scheduling Algorithms
Scheduling decides which process gets the CPU next. Done by the scheduler; the dispatcher actually hands over the CPU.
| Algorithm | Rule | Preemptive? | Key Point |
|---|---|---|---|
| FCFS | First Come First Served | No | Simple; suffers “convoy effect” |
| SJF | Shortest Job First | No | Lowest average waiting time; risk of starvation |
| SRTF | Shortest Remaining Time First | Yes | Preemptive version of SJF |
| Round Robin | Each process gets a fixed time quantum | Yes | Best for time-sharing / interactive systems |
| Priority | Highest priority runs first | Both | Starvation solved by “aging” |
Exam Tip Preemptive: Round Robin, SRTF, Preemptive-Priority. Non-preemptive: FCFS, basic SJF. A Gantt chart is used to show scheduling order.
7 Synchronization & Deadlock
- Critical Section: code that accesses a shared resource.
- Race Condition: output depends on the timing/order of processes accessing shared data.
- Mutual Exclusion: only one process uses a resource at a time.
- Semaphore / Mutex: tools used to achieve synchronization.
- Starvation: a process waits indefinitely for the CPU/resource.
Deadlock A situation where two or more processes wait for each other forever, so none can proceed.
4 Necessary Conditions for Deadlock (Coffman conditions)
| Condition | Meaning |
|---|---|
| Mutual Exclusion | Resource can be used by only one process at a time |
| Hold and Wait | Process holds one resource & waits for another |
| No Preemption | Resource cannot be forcibly taken away |
| Circular Wait | Processes form a circular chain of waiting |
Remember All four conditions must hold for a deadlock. Banker’s Algorithm is used for deadlock avoidance.
8 Memory Management
Memory Hierarchy (fast → slow)
Registers → Cache → RAM → SSD → Hard Disk
(fastest, smallest, costliest) ........ (slowest, largest, cheapest)
- RAM – volatile, temporary, primary memory. ROM – non-volatile, permanent (stores BIOS).
- Cache – very fast memory between CPU and RAM for frequently-used data.
- Virtual Memory – uses part of the hard disk as extra RAM (swap / page file).
Paging vs Segmentation
Paging
- Memory split into fixed-size pages/frames
- Causes internal fragmentation
- Uses a page table
Segmentation
- Memory split into variable-size logical segments (code, data, stack)
- Causes external fragmentation
- Matches programmer’s view
Key Memory Terms
| Term | Meaning |
|---|---|
| Page Fault | Required page is not in RAM → must be loaded from disk |
| Thrashing | Too much paging/swapping → CPU utilisation drops sharply |
| TLB | Translation Lookaside Buffer — speeds up address translation |
| MMU | Memory Management Unit — converts virtual→physical address |
| Demand Paging | Load a page only when it is actually needed |
| Belady’s Anomaly | More frames → more page faults (occurs in FIFO) |
Page Replacement Algorithms
FIFO → removes the oldest loaded page (can show Belady's anomaly)
LRU → removes the Least Recently Used page
Optimal → removes the page not needed for the longest future time
(lowest faults — but only theoretical)
9 File & Device Management
File System Basics
| Term | Meaning |
|---|---|
| File | Named collection of related data |
| Directory / Folder | Container that stores files |
| Path | Address of a file (absolute = from root; relative = from current folder) |
| File Extension | Type of file: .exe, .docx, .txt, .jpg |
| FAT / NTFS | Windows file systems (NTFS = New Technology File System) |
| ext4 | Common Linux file system |
Exam Tip File allocation methods: Contiguous, Linked, Indexed. Directory structures: Single-level, Two-level, Tree, Acyclic-graph.
Device (I/O) Management
| Term | Meaning |
|---|---|
| Device Driver | Software that lets the OS control a hardware device |
| Spooling | Simultaneous Peripheral Operations On-Line — queues jobs (esp. printing) |
| Buffering | Temporary storage to match speeds of CPU and device |
| DMA | Direct Memory Access — data transfer without using the CPU |
| Interrupt | Signal that tells the CPU to pause and attend a device |
| RAID | Redundant Array of Independent Disks — reliability/speed |
Remember Disk scheduling algorithms: FCFS, SSTF (Shortest Seek Time First), SCAN (elevator), C-SCAN, LOOK.
10 Booting (BIOS / UEFI)
Power ON → BIOS/UEFI → POST (self-test) → Bootloader → OS loaded into RAM → Ready
| Term | Meaning |
|---|---|
| BIOS | Basic Input Output System — firmware that starts the PC (stored in ROM) |
| UEFI | Modern replacement for BIOS (faster, supports large disks) |
| POST | Power-On Self-Test — checks hardware at startup |
| Bootloader | Loads the OS into memory (e.g. GRUB in Linux) |
| Cold Boot | Starting the computer from power-off |
| Warm Boot | Restarting an already-on computer (Ctrl+Alt+Del) |
11 OS Security & Protection
A high-value area as exams increasingly add computer-security questions.
- Authentication — verifying identity (password, OTP, biometric, smart card).
- Authorization — deciding what an authenticated user is allowed to do.
- Access Control — file permissions Read / Write / Execute (rwx); uses ACL (Access Control List).
- Encryption — scrambling data so only authorised users can read it.
- Firewall — filters network traffic to block unauthorised access.
- User mode vs Kernel mode — protects core OS from faulty/malicious programs.
- Sandboxing — running apps in an isolated space.
Common OS-Level Threats (quick definitions)
| Threat | Meaning |
|---|---|
| Virus | Malicious code that attaches to files & spreads when run |
| Worm | Self-replicating malware that spreads on its own (no host file) |
| Trojan | Harmful program disguised as useful software |
| Ransomware | Locks/encrypts files & demands payment |
| Spyware | Secretly collects user information |
| Privilege Escalation | Gaining higher access rights than allowed |
Common Trap A virus needs a host file and human action to spread; a worm spreads by itself over a network. This difference is frequently asked.
12 Important Full Forms
| Abbr. | Full Form | Abbr. | Full Form |
|---|---|---|---|
| OS | Operating System | BIOS | Basic Input Output System |
| GUI | Graphical User Interface | UEFI | Unified Extensible Firmware Interface |
| CLI | Command Line Interface | POST | Power-On Self-Test |
| RAM | Random Access Memory | ROM | Read Only Memory |
| FCFS | First Come First Served | SJF | Shortest Job First |
| RR | Round Robin | RTOS | Real-Time Operating System |
| PCB | Process Control Block | DMA | Direct Memory Access |
| TLB | Translation Lookaside Buffer | MMU | Memory Management Unit |
| FAT | File Allocation Table | NTFS | New Technology File System |
| SSTF | Shortest Seek Time First | RAID | Redundant Array of Independent Disks |
| SPOOL | Simultaneous Peripheral Operations On-Line | ACL | Access Control List |
| IPC | Inter-Process Communication | GRUB | GRand Unified Bootloader |
13 Inventors & History Facts
| Fact | Answer |
|---|---|
| UNIX developed at | Bell Labs — by Ken Thompson & Dennis Ritchie (≈1969) |
| Linux created by | Linus Torvalds (1991) |
| Windows created by | Microsoft — first version (Windows 1.0) in 1985 |
| C language created by | Dennis Ritchie |
| macOS / iOS made by | Apple |
| Android made by | Google (now Open Handset Alliance) |
| Most OSes are written in | C language |
14 Comparison Charts
GUI
- Uses icons, windows, mouse
- Easy for beginners
- Examples: Windows, Android
CLI
- Uses typed commands
- Fast & powerful for experts
- Examples: MS-DOS, Linux terminal
RAM
- Volatile (data lost on power-off)
- Read + Write
- Temporary working memory
ROM
- Non-volatile (permanent)
- Mostly read-only
- Stores BIOS / firmware
Process
- Running program
- Has its own memory
- Heavyweight
Thread
- Part of a process
- Shares process memory
- Lightweight
🧠 Solved MCQs — Based on Exam Trends
Curated, high-frequency questions with answers + one-line explanations. Click “Show Answer” to self-test.
Set A · Basics & Types
1. An Operating System is a type of:
- A) Application Software
- B) System Software
- C) Firmware
- D) Utility Software
Show Answer
B) System Software. The OS manages hardware/software resources, unlike application software (e.g. MS Word) which performs user tasks.
2. Which of the following is NOT an operating system?
- A) Linux
- B) Windows
- C) Android
- D) Oracle
Show Answer
D) Oracle. Oracle is a database management system (DBMS), not an OS.
3. The core component of an OS is called:
- A) Shell
- B) Kernel
- C) Application
- D) Processor
Show Answer
B) Kernel. The kernel is the heart of the OS that controls hardware. The shell is the user interface to the kernel.
4. Android OS is based on:
- A) UNIX
- B) Windows
- C) Linux kernel
- D) Macintosh
Show Answer
C) Linux kernel. Android is built on a modified Linux kernel and is owned by Google.
5. Which OS is an example of open-source software?
- A) Windows
- B) macOS
- C) Linux
- D) iOS
Show Answer
C) Linux. Linux source code is freely available and modifiable.
6. The program that loads the OS into memory during startup is the:
- A) Compiler
- B) BIOS
- C) Bootloader
- D) Kernel
Show Answer
C) Bootloader. BIOS/UEFI starts the machine, then the bootloader loads the OS into RAM.
7. UNIX was originally developed by:
- A) Microsoft
- B) Bell Labs
- C) IBM
- D) Intel
Show Answer
B) Bell Labs — by Ken Thompson and Dennis Ritchie.
8. Restarting a computer without turning off the power is called:
- A) Hard boot
- B) Warm boot
- C) Cold boot
- D) Power boot
Show Answer
B) Warm boot. Cold boot = starting from power-off; warm boot = restart of a running system.
9. The OS used in ATM machines and flight control is usually:
- A) Batch OS
- B) Real-Time OS
- C) Distributed OS
- D) Multi-user OS
Show Answer
B) Real-Time OS. RTOS guarantees response within a strict time limit.
10. Which is NOT a function of an OS?
- A) Memory management
- B) Process management
- C) File handling
- D) Weather forecasting
Show Answer
D) Weather forecasting. It is an application task, not an OS function.
Set B · Process & Scheduling
11. A process in the “ready” state means it is:
- A) Waiting for I/O
- B) Currently executing
- C) Waiting to be assigned the CPU
- D) Completed
Show Answer
C) Waiting to be assigned the CPU. It is loaded and ready, just waiting for CPU time.
12. The scheduling method used in time-sharing systems is:
- A) FCFS
- B) Round Robin
- C) SJF
- D) LIFO
Show Answer
B) Round Robin. Each process gets a fixed time quantum — ideal for interactive systems.
13. Switching the CPU from one process to another is called:
- A) Swapping
- B) Paging
- C) Context switching
- D) Spooling
Show Answer
C) Context switching. The state of the current process is saved and the next process’s state is loaded.
14. The system call used to create a new process is:
- A) init()
- B) fork()
- C) create()
- D) load()
Show Answer
B) fork(). It creates a child process in UNIX/Linux.
15. Banker’s Algorithm is used for:
- A) Booting
- B) Deadlock avoidance
- C) Page replacement
- D) Process creation
Show Answer
B) Deadlock avoidance. It checks whether allocating resources keeps the system in a “safe state”.
16. Which is NOT one of the four conditions for deadlock?
- A) Mutual exclusion
- B) Hold and wait
- C) Circular wait
- D) Fast switching
Show Answer
D) Fast switching. The four Coffman conditions are mutual exclusion, hold & wait, no preemption, and circular wait.
17. When a process waits indefinitely for resources, it is called:
- A) Deadlock
- B) Starvation
- C) Thrashing
- D) Buffering
Show Answer
B) Starvation. It is solved using “aging” (gradually raising waiting processes’ priority).
18. Multiple CPUs working together is called:
- A) Multithreading
- B) Multiprocessing
- C) Multitasking
- D) Multiprogramming
Show Answer
B) Multiprocessing. Two or more processors execute simultaneously.
Set C · Memory Management
19. The fastest memory among these is:
- A) Hard disk
- B) RAM
- C) Cache
- D) Pen drive
Show Answer
C) Cache. Among the options, cache is fastest (CPU registers are faster still, but not listed).
20. Virtual memory means:
- A) Backup memory
- B) Using disk space as extra RAM
- C) Flash memory
- D) Cache memory
Show Answer
B) Using disk space as extra RAM. It lets large programs run with limited physical RAM.
21. Paging divides memory into:
- A) Variable segments
- B) Fixed-size pages/frames
- C) Logical blocks
- D) Sectors
Show Answer
B) Fixed-size pages/frames. Paging causes internal fragmentation; segmentation causes external fragmentation.
22. Thrashing occurs due to:
- A) Too many files
- B) Excessive paging/swapping
- C) A booting error
- D) Disk crash
Show Answer
B) Excessive paging/swapping. The CPU spends more time swapping pages than executing — utilisation drops.
23. A page fault occurs when:
- A) The disk crashes
- B) The required page is not in RAM
- C) The CPU overheats
- D) A program ends
Show Answer
B) The required page is not in RAM. It must then be fetched from disk.
24. Belady’s anomaly is associated with which page replacement algorithm?
- A) LRU
- B) FIFO
- C) Optimal
- D) LFU
Show Answer
B) FIFO. Here, increasing the number of frames can surprisingly increase page faults.
25. TLB stands for:
- A) Table Lookup Buffer
- B) Translation Lookaside Buffer
- C) Time Local Buffer
- D) Transfer Level Buffer
Show Answer
B) Translation Lookaside Buffer. It caches recent address translations to speed up paging.
Set D · File & Device Management
26. NTFS stands for:
- A) Network Table File System
- B) New Technology File System
- C) New Terminal Format System
- D) National Transfer File System
Show Answer
B) New Technology File System — the modern Windows file system supporting permissions & journaling.
27. Spooling is mainly used with:
- A) Monitor
- B) Printer
- C) Scanner
- D) Mouse
Show Answer
B) Printer. Spooling queues print jobs so the CPU need not wait for the slow printer.
28. A device driver is:
- A) A hardware component
- B) Software that controls hardware
- C) A data file
- D) A type of shell
Show Answer
B) Software that controls hardware and lets the OS communicate with a device.
29. The DOS command to list files in a directory is:
- A) LIST
- B) DIR
- C) SHOW
- D) FILES
Show Answer
B) DIR. (In Linux, the equivalent is ls.)
30. DMA stands for:
- A) Direct Memory Address
- B) Direct Memory Access
- C) Dynamic Memory Allocation
- D) Data Memory Activity
Show Answer
B) Direct Memory Access. It transfers data between device and memory without the CPU, freeing it for other work.
31. RAID stands for:
- A) Random Access Input Drive
- B) Redundant Array of Independent Disks
- C) Remote Access Internet Disk
- D) Real-time Array Integrated Device
Show Answer
B) Redundant Array of Independent Disks — used for data reliability and improved performance.
Set E · Security & Misc
32. A firewall protects mainly against:
- A) Hardware failure
- B) Unauthorised network access
- C) Disk corruption
- D) Power cuts
Show Answer
B) Unauthorised network access. It filters incoming/outgoing traffic by rules.
33. Self-replicating malware that spreads without a host file is a:
- A) Virus
- B) Worm
- C) Trojan
- D) Cookie
Show Answer
B) Worm. Unlike a virus, a worm spreads by itself across networks.
34. File permissions Read/Write/Execute are managed using:
- A) Page table
- B) Access Control List (ACL)
- C) Gantt chart
- D) Bootloader
Show Answer
B) Access Control List (ACL). It defines what each user can do with a file.
35. A virtual machine allows:
- A) Running without an OS
- B) Running multiple OSes on one hardware
- C) Running only BIOS
- D) Running RAM only
Show Answer
B) Running multiple OSes on one hardware. A hypervisor creates isolated virtual machines.
🎯 Expected / High-Probability MCQs
Newer and likely-to-appear questions on modern OS and security concepts.
1. UEFI is best described as:
- A) A type of RAM
- B) A modern replacement for BIOS firmware
- C) A scheduling algorithm
- D) A file system
Show Answer
B) A modern replacement for BIOS. UEFI boots faster and supports very large hard disks.
2. Which kernel type is used by the Linux operating system?
- A) Microkernel
- B) Monolithic kernel
- C) Exokernel
- D) No kernel
Show Answer
B) Monolithic kernel. The entire core OS runs in kernel space. (Windows/macOS use hybrid kernels.)
3. Malware that encrypts a user’s files and demands payment is called:
- A) Adware
- B) Spyware
- C) Ransomware
- D) Rootkit
Show Answer
C) Ransomware. A leading modern cyber threat that targets individuals and organisations.
4. Running an application in an isolated environment to limit damage is called:
- A) Spooling
- B) Sandboxing
- C) Paging
- D) Mounting
Show Answer
B) Sandboxing. It contains a program so it cannot affect the rest of the system.
5. Which provides the interface between an application program and the OS?
- A) System call
- B) Compiler
- C) Firewall
- D) Bootloader
Show Answer
A) System call. Programs request OS services (file, memory, process) through system calls.
6. In a multi-core processor, the OS feature that most directly uses extra cores is:
- A) Spooling
- B) Multiprocessing
- C) Demand paging
- D) Defragmentation
Show Answer
B) Multiprocessing. Multiple cores execute different tasks at the same time.
7. Two-factor authentication usually combines a password with:
- A) A second password
- B) An OTP / biometric
- C) A faster CPU
- D) A larger disk
Show Answer
B) An OTP / biometric. It mixes “something you know” with “something you have/are” for stronger security.
8. The elevator algorithm in disk scheduling is also known as:
- A) FCFS
- B) SSTF
- C) SCAN
- D) LRU
Show Answer
C) SCAN. The disk head moves in one direction servicing requests, then reverses — like a lift.
📄 One-Page Quick Revision
| Concept | One-line Recall |
|---|---|
| OS | Interface between user & hardware (system software) |
| Kernel | Heart/core of OS that controls hardware |
| Shell | User’s command interface to the kernel |
| Bootloader | Loads OS into memory at startup |
| Cold / Warm boot | Start from power-off / restart while running |
| RTOS | Guaranteed response time (ATM, flight control) |
| Process / Thread | Running program / lightweight part of a process |
| Round Robin | Time-quantum scheduling for time-sharing |
| Deadlock | Processes wait for each other forever (4 conditions) |
| Banker’s Algorithm | Deadlock avoidance |
| Virtual Memory | Disk used as extra RAM |
| Paging / Segmentation | Fixed pages (internal frag.) / variable segments (external frag.) |
| Thrashing | Excessive swapping; CPU use drops |
| Spooling | Job queue, mainly for printers |
| DMA | Data transfer without CPU |
| Firewall | Blocks unauthorised network access |
| Virus vs Worm | Virus needs host + action; worm spreads itself |
5-Second Memory Hooks
Kernel = Heart · Shell = Speaker · RTOS = Fast & on-time · Deadlock = Stuck forever · Virtual Memory = Disk pretending to be RAM.
✦ Operating System — Complete Study Notes · GyanDesk · Made for quick learning & smart revision ✦
