Chapter 3: Processes

A running instance of a program is called a process. If you have two terminal windows showing on your screen, then you are probably running the same terminal program twice -- you have two terminal processes. Each terminal window is probably running a shell; each running shell is another process. When you invoke a command from a shell, the corresponding program is executed in a new process; the shell process resumes when that process completes.

Advanced programmers often use multiple cooperating processes in a single application to enable the application to do more than one thing at once, to increase application robustness, and to make use of already-existing programs.

Most of the process manipulation functions described in this chapter are similar to those on other UNIX systems. Most are declared in the header file <unistd.h>; check the man page for each function to be sure.


Download PDF.