Process Management 1 (UNIX - LINUX History-Basic Shell Commands Ps-Process Definition)
Process Management 1 (UNIX - LINUX History-Basic Shell Commands Ps-Process Definition)
Process Management in OS
Figures/Tables utilized from the standard books or other sources has been
acknowledged in the respective slides
• Context of a Process
• Process control creation, termination, etc. (system calls : fork, exit, wait)
• Deadlock Handling
• Data access synchronization primitives : Shared memory, Semaphores (POSIX semaphores), monitors
• Process Definition
History of UNIX & LINUX
1969: UNIX V1 written in PDP 7 assembler language; memory swapping
• When a new process is started, the next unused number in sequence is chosen and the numbers restart at 2 so that pids
wrap around
• After booting the 1st kernel process pid (0) is created; it is known as the swapper process; which then creates several other
kernel processes and the 1st user level process init, pid (1)
• The init process is the grandparent of all other processes. All other processes are directly started by init or by other
processes created by init
• Each process (except init) is created by some other process called its parent process and the newly created process is called
its child process. A process hierarchy exist; if the parent terminates before child then init process becomes the parent of the
orphan child process
• The init process creates the terminal process (getty) after a user login
• $ls –l - utility for listing the contents files and subdirectories of a directory
Process Definition…..
• An instance of program in execution
• Is an abstract entity which helps to explain, understand, and control a program execution
• It is an entity that is manifested by the existence of Process Control Block (PCB) in OS; generally includes
the current activity (program counter), contents of the processor’s registers, process stack, data and the
code(the program), etc.
• Concurrent Processes – simultaneous existence of multiple processes with full or partial overlap in time
• Interacting Processes – if concurrent processes interact (direct- sending signal or indirect - shared memory)
P1:
P2:
P3:
Blocked for I/O or
ready for running
Time
P1, P2, P3 are concurrent processes and P1 & P2 are concurrent as well as interacting processes