Class Notes - Operating Systems
Topic: Process Management
1. Definition:
A process is a program in execution. It is the basic unit of work in a computer system.
2. Process States:
- New: The process is being created.
- Ready: The process is waiting to be assigned to a processor.
- Running: Instructions are being executed.
- Waiting: The process is waiting for some event to occur.
- Terminated: The process has finished execution.
3. Process Control Block (PCB):
Stores information about the process, including:
- Process ID
- Program Counter
- CPU Registers
- Memory Management Information
- Accounting Information
- I/O Status Information
4. Context Switching:
When the CPU switches from one process to another, the state of the current process must be
saved so it can be resumed later. This is known as context switching.
5. Scheduling Algorithms:
- First-Come, First-Served (FCFS)
- Shortest Job Next (SJN)
- Priority Scheduling
- Round Robin (RR)
- Multilevel Queue Scheduling