Process-state-transition-diagram.png

Flow:

  1. Process enters the system, placed in a job queue.
  2. Processes residing in the main memory ready and waiting to be executed are kept in the ready queue.
  3. Once in a running state, the process can be interrupted, put on wait, or exited.

Process States

A state is the current activity of that process.

Each process may be in one of the following states:

New - The process is being created.

Ready - The process is waiting to be assigned to a processor.

Running - When instructions are being executed.

Waiting - The process is waiting for some event to occur. (Such as I/O completion or signal reception)

Terminated - The process has finished execution.

Process Transitions:

Zombie Process

A zombie process, also known as a defunct process, is a process that has completed execution but still has an entry in the process table. This happens when a child process has finished its execution, but its parent process hasn't yet read its exit status.

They're identified by the 'Z' state in process status outputs.