Os Architecture
Os Architecture
Here's a more detailed explanation of the topics you mentioned for your Operating System
with Linux internal exam. I've kept it clear and exam-friendly:
🔷 2. OS Architecture
Different types of OS architectures define how the system is organized internally:
1. Monolithic Kernel
• All OS services run in kernel space (e.g., memory, I/O, process management).
• Example: Linux
• Fast but harder to maintain/debug.
2. Microkernel
• Only essential services (like IPC and scheduling) are in the kernel; others are in user
space.
• More secure and modular but may be slower.
• Example: Minix
3. Layered Architecture
• OS is built in layers; each layer uses services of the lower one.
• Easy to debug and maintain.
4. Modular Architecture
• Loadable kernel modules provide flexibility.
• Combines monolithic performance with microkernel flexibility.
🔷 4. Booting Process
The steps your computer follows when it turns on:
1. Power ON: Hardware receives power.
2. POST: Power-On Self-Test checks basic hardware.
3. Bootloader (e.g., GRUB): Loaded from MBR; loads the OS kernel.
4. Kernel Loading: Initializes system and hardware.
5. Init/Systemd: Starts background services and user interface.
🔷 6. Multiprogramming
• Multiple programs are loaded into memory.
• CPU switches between them when one is waiting (e.g., for I/O).
• Increases CPU utilization and system efficiency.
🔷 7. Multitasking
• The OS allows execution of multiple tasks (programs) at the same time.
• Two types:
• Preemptive: OS decides when to switch tasks (used in modern OS).
• Non-Preemptive: Task runs until it completes or voluntarily gives up CPU.
🔷 8. Multithreading
• A single process can have multiple threads (lightweight processes).
• Threads share the same memory but run independently.
• Helps in better CPU utilization and faster processing (e.g., in browsers, games).
🔷 9. OS Classifications
Classification Description
Users submit jobs to the computer operator; jobs run one after another
Simple Batch System
without interaction.
Multiprogrammed Batch OS keeps several jobs in memory; CPU switches among them to keep
System busy.
Users interact with the system simultaneously; each gets a short time
Time Sharing System
slice.
Parallel OS Multiple processors work together to execute jobs faster.
OS manages a group of computers, appearing to users as a single
Distributed OS
system. Useful in cloud systems and networks.
Let me know if you’d like a PDF version, Hindi explanation, or some practice questions!
Great! Here’s a detailed and student-friendly explanation of Unit-2: Process Management for
your Operating Systems with Linux internal exam:
🔷 1. Process Management
🔹 What is a Process?
A process is a program in execution. It is an active entity, unlike a program which is a passive set
of instructions.
Each process has:
• Program code
• Program counter (PC)
• Stack
• Data section
• Process Control Block (PCB) — contains information about the process (state, ID, registers,
etc.)
🔷 2. Process States and Transitions
A process goes through the following states during its lifetime:
📊 Process States:
1. New – Process is being created.
2. Ready – Process is waiting to be assigned to CPU.
3. Running – Instructions are being executed.
4. Waiting (Blocked) – Waiting for I/O or event.
5. Terminated – Process has finished execution.
🔁 State Transitions:
• New → Ready: After creation
• Ready → Running: CPU scheduler picks the process
• Running → Waiting: Process requests I/O
• Waiting → Ready: I/O complete, process is ready again
• Running → Ready: Preempted by OS (e.g., time slice over)
• Running → Terminated: Process finishes execution
📌 Diagram available on request!
🔹 Benefits:
• Faster context switching than processes
• Efficient CPU utilization
• Threads share memory, files, etc., reducing overhead
🔹 Types of Threads:
• User-level Threads: Managed by user-level libraries.
• Kernel-level Threads: Managed directly by the OS.
✅ Summary:
• A process is a running program; it has multiple states.
• CPU Scheduling Algorithms decide the order of execution.
• Threads are lightweight units inside a process, used for parallel tasks.
Would you like a diagram of process states, or a table comparing the scheduling algorithms in
PDF or image form?