Definition Batch Processing
A process is
fundamentally a container that holds all the Job 1
information needed to run
program
a
.
Job 2
Job 3
new terminated Job Y
admitted J
exit
interrupt
# First In First Out
W
ready
-running
scheduler
Job 1 Job 2 Job 3 Job Y
Executed
-
1/0 or event
- dispatch I/0 or
completition event wait
Application o
on the CPU !
Shortest Job Next
waiting *
Operating System Job Y Job 1 Job 2 Job 3
Example With 1/0 points
int a , b; JobY Job 1 Job 2 Job 3
Y
scanf ("God" &a) ;
in put
Scanf (" %d" , & b) ; #
W
3
·
int s = a + b
; compute
Printf (" % d In" s) ; , youtput
With voluntary "yield' points as well
Job Y Job 1 Job 2 Job 3
*
How a system boots
up ?
Process Control Block
Process
1 init
systemd/launched a demon process
ID
Resource
Parent ID &
Info 2
Resource
·
Priority
T
2 #
-
Info 1
daemon process
PPID
adopts orphan
PID 3 ↑ xterm
killed
Registers S
Memory
bash 7 Block 2
8
Memory
fork creates a
D
9 child process Resources Block 1
Memory Memory
*
Block 3
Orphans
-
If parent before its children the children Next PCB
a
expires ,
are adopted' by init.
- to next PCB
Zombies
Childprocesses whichhavterminatedbutthis habenobsonbyRirroradot a