Process - Operating Systems - Lecture Slides | CISC 361, Study notes of Operating Systems

Material Type: Notes; Class: Operating Systems; Subject: Computer/Information Sciences; University: University of Delaware; Term: Spring 2009;

Typology: Study notes

Pre 2010

Uploaded on 09/02/2009

koofers-user-hx0
koofers-user-hx0 🇺🇸

9 documents

1 / 9

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Processes
A process is a running program.
The cpu can be used by one process
while another is waiting on I/O.
Multiprogramming – can switch from
one program to another (interleave
them). To user seems like more than
one program running at a time on
a single cpu. With a multiprocessor
can run more than one at a time.
pf3
pf4
pf5
pf8
pf9

Partial preview of the text

Download Process - Operating Systems - Lecture Slides | CISC 361 and more Study notes Operating Systems in PDF only on Docsity!

Processes

A process is a running program. The cpu can be used by one process while another is waiting on I/O. Multiprogramming – can switch from one program to another (interleave them). To user seems like more than one program running at a time on a single cpu. With a multiprocessor can run more than one at a time.

Processes

A process is an executing program with values for program counter, registers and variables. Also owns resources. Example: 3 processes A, B, C A B C Time

Process Switching

During a process switch the state of the current process must be saved. Then the new process can be given time on the cpu – context switch. The process that was taken off the cpu can be loaded back on some time later. Must save program counter, contents of registers, etc. to do so. Takes some amount of time.

Processes

OS Must have a way to create and terminate processes. Start off with initial process (init, pid 1). Then create more processes to form a tree. How to create a process

  • allocate resources
  • create process table entry fork(2), ps command, pid, parent pid

Process Hierarchy - SVR

0 - sched 1 - init inetd sshd tcsh Use ps and ptree commands

Process Termination

Normal voluntary exit Error voluntary exit involuntary fatal error killed by another process free up resources remove process table entry How many processes can a system support?