Process state

In a multitasking computer system, processes may occupy a variety of states.

Typically in most desktop computer systems, this admission will be approved automatically.

Modern computers are capable of running many different programs or processes at the same time.

Such critical sections are protected using a synchronization object such as a semaphore or mutex.

A process may be terminated, either from the "running" state by completing its execution or by explicitly being killed.

Two additional states are available for processes in systems that support virtual memory.

In both of these states, processes are "stored" on secondary memory (typically a hard disk).

The various process states, displayed in a state diagram , with arrows indicating possible transitions between states - as can be seen some processes are stored in main memory (yellow), and some are stored in secondary memory (green).