When you run a program in your shell, a process is created. This new process is called a child process of the shell.
The originating process (the shell from which you ran the command) is called the parent process of the child.
When you run a new shell, you are creating a child process under the originating shell.
Examine the SlideShow below to see an example of new processes being created as shells are run from the command line.
lists all of the processes you are currently running. The
displays a full list of information.
This information includes the PID of the parent process, which is referred to as the PPID in the
Look at the sample
command below. It reflects the processes created in the SlideShow above. Connecting lines are included in the command below to point out the relationship between the PID and PPID numbers.
These lines are not normally part of the output, they are just used here for clarification.
In the listing above, the /bin/ksh process (PID 3723) was started from the /bin/sh process (PID 3707), so 3707 is listed as the PPID of 3723.
The /bin/csh process (PID 3725) was started from the /bin/ksh process (PID 3723), so 3725 is listed as the PPID of 3725.
The next lesson examines three different techniques for running a shell script.