-
Every process belongs to a process group.
-
A process group has a group id.
-
The group id is typically the same as the process id of one of the processes in the group.
- By default, the process group of a child process is the same as that of its parent (but this can be changed).
Example:
- Process with pid = 1400 has group id also = 1400.
- Process with pid = 1400 forks 2 children with pids 1401 and 1405.
- Process 1401 forks one child with pid = 1407.
What are the group ids?
Process id | Group id |
---|---|
1400 | 1400 |
1401 | |
1405 | |
1407 |