<s>
A	O
child	B-Operating_System
process	I-Operating_System
in	O
computing	O
is	O
a	O
process	B-Operating_System
created	O
by	O
another	O
process	B-Operating_System
(	O
the	O
parent	B-Operating_System
process	I-Operating_System
)	O
.	O
</s>
<s>
This	O
technique	O
pertains	O
to	O
multitasking	B-Operating_System
operating	I-Operating_System
systems	I-Operating_System
,	O
and	O
is	O
sometimes	O
called	O
a	O
subprocess	B-Operating_System
or	O
traditionally	O
a	O
subtask	O
.	O
</s>
<s>
There	O
are	O
two	O
major	O
procedures	O
for	O
creating	O
a	O
child	B-Operating_System
process	I-Operating_System
:	O
the	O
fork	B-Language
system	I-Language
call	I-Language
(	O
preferred	O
in	O
Unix-like	B-Operating_System
systems	I-Operating_System
and	O
the	O
POSIX	O
standard	O
)	O
and	O
the	O
spawn	B-Language
(	O
preferred	O
in	O
the	O
modern	O
(	O
NT	O
)	O
kernel	B-Operating_System
of	O
Microsoft	B-Application
Windows	I-Application
,	O
as	O
well	O
as	O
in	O
some	O
historical	O
operating	O
systems	O
)	O
.	O
</s>
<s>
Child	O
processes	O
date	O
to	O
the	O
late	O
1960s	O
,	O
with	O
an	O
early	O
form	O
in	O
later	O
revisions	O
of	O
the	O
Multiprogramming	O
with	O
a	O
Fixed	O
number	O
of	O
Tasks	O
Version	O
II	O
(	O
MFT-II	O
)	O
form	O
of	O
the	O
IBM	O
OS/360	B-Application
operating	O
system	O
,	O
which	O
introduced	O
sub-tasking	O
(	O
see	O
task	B-General_Concept
)	O
.	O
</s>
<s>
The	O
current	O
form	O
in	O
Unix	B-Application
draws	O
on	O
Multics	B-Application
(	O
1969	O
)	O
,	O
while	O
the	O
Windows	O
NT	O
form	O
draws	O
on	O
OpenVMS	B-Operating_System
(	O
1978	O
)	O
,	O
from	O
RSX-11	B-Application
(	O
1972	O
)	O
.	O
</s>
<s>
A	O
child	B-Operating_System
process	I-Operating_System
inherits	O
most	O
of	O
its	O
attributes	O
,	O
such	O
as	O
file	B-Application
descriptors	I-Application
,	O
from	O
its	O
parent	O
.	O
</s>
<s>
In	O
Unix	B-Application
,	O
a	O
child	B-Operating_System
process	I-Operating_System
is	O
typically	O
created	O
as	O
a	O
copy	O
of	O
the	O
parent	O
,	O
using	O
the	O
fork	B-Language
system	I-Language
call	I-Language
.	O
</s>
<s>
The	O
child	B-Operating_System
process	I-Operating_System
can	O
then	O
overlay	O
itself	O
with	O
a	O
different	O
program	O
(	O
using	O
)	O
as	O
required	O
.	O
</s>
<s>
Each	O
process	B-Operating_System
may	O
create	O
many	O
child	O
processes	O
but	O
will	O
have	O
at	O
most	O
one	O
parent	B-Operating_System
process	I-Operating_System
;	O
if	O
a	O
process	B-Operating_System
does	O
not	O
have	O
a	O
parent	O
this	O
usually	O
indicates	O
that	O
it	O
was	O
created	O
directly	O
by	O
the	O
kernel	B-Operating_System
.	O
</s>
<s>
In	O
some	O
systems	O
,	O
including	O
Linux-based	O
systems	O
,	O
the	O
very	O
first	O
process	B-Operating_System
(	O
called	O
init	B-Operating_System
)	O
is	O
started	O
by	O
the	O
kernel	B-Operating_System
at	O
booting	B-Operating_System
time	O
and	O
never	O
terminates	B-Operating_System
(	O
see	O
Linux	B-Application
startup	I-Application
process	I-Application
)	O
;	O
other	O
parentless	O
processes	O
may	O
be	O
launched	O
to	O
carry	O
out	O
various	O
daemon	B-Operating_System
tasks	O
in	O
userspace	B-Operating_System
.	O
</s>
<s>
Another	O
way	O
for	O
a	O
process	B-Operating_System
to	O
end	O
up	O
without	O
a	O
parent	O
is	O
if	O
its	O
parent	O
dies	O
,	O
leaving	O
an	O
orphan	B-Operating_System
process	I-Operating_System
;	O
but	O
in	O
this	O
case	O
it	O
will	O
shortly	O
be	O
adopted	O
by	O
init	B-Operating_System
.	O
</s>
<s>
The	O
SIGCHLD	B-Operating_System
signal	B-General_Concept
is	O
sent	O
to	O
the	O
parent	O
of	O
a	O
child	B-Operating_System
process	I-Operating_System
when	O
it	O
exits	O
,	O
is	O
interrupted	O
,	O
or	O
resumes	O
after	O
being	O
interrupted	O
.	O
</s>
<s>
By	O
default	O
the	O
signal	B-General_Concept
is	O
simply	O
ignored	O
.	O
</s>
<s>
When	O
a	O
child	B-Operating_System
process	I-Operating_System
terminates	B-Operating_System
,	O
some	O
information	O
is	O
returned	O
to	O
the	O
parent	B-Operating_System
process	I-Operating_System
.	O
</s>
<s>
When	O
a	O
child	B-Operating_System
process	I-Operating_System
terminates	B-Operating_System
before	O
the	O
parent	O
has	O
called	O
wait	B-Operating_System
,	O
the	O
kernel	B-Operating_System
retains	O
some	O
information	O
about	O
the	O
process	B-Operating_System
,	O
such	O
as	O
its	O
exit	B-Operating_System
status	I-Operating_System
,	O
to	O
enable	O
its	O
parent	O
to	O
call	O
wait	B-Operating_System
later	O
.	O
</s>
<s>
Because	O
the	O
child	O
is	O
still	O
consuming	O
system	O
resources	O
but	O
not	O
executing	O
it	O
is	O
known	O
as	O
a	O
zombie	B-Operating_System
process	I-Operating_System
.	O
</s>
<s>
The	O
wait	B-Operating_System
system	O
call	O
is	O
commonly	O
invoked	O
in	O
the	O
SIGCHLD	B-Operating_System
handler	O
.	O
</s>
<s>
POSIX.1-2001	O
allows	O
a	O
parent	B-Operating_System
process	I-Operating_System
to	O
elect	O
for	O
the	O
kernel	B-Operating_System
to	O
automatically	O
reap	B-Operating_System
child	O
processes	O
that	O
terminate	B-Operating_System
by	O
explicitly	O
setting	O
the	O
disposition	O
of	O
SIGCHLD	B-Operating_System
to	O
SIG_IGN	O
(	O
although	O
ignore	O
is	O
the	O
default	O
,	O
automatic	O
reaping	O
only	O
occurs	O
if	O
the	O
disposition	O
is	O
set	O
to	O
ignore	O
explicitly	O
)	O
,	O
or	O
by	O
setting	O
the	O
SA_NOCLDWAIT	O
flag	O
for	O
the	O
SIGCHLD	B-Operating_System
signal	B-General_Concept
.	O
</s>
<s>
Linux	B-Operating_System
2.6	I-Operating_System
kernels	B-Operating_System
adhere	O
to	O
this	O
behavior	O
,	O
and	O
FreeBSD	O
supports	O
both	O
of	O
these	O
methods	O
since	O
version	O
5.0	O
.	O
</s>
<s>
However	O
,	O
because	O
of	O
historical	O
differences	O
between	O
System	B-Operating_System
V	I-Operating_System
and	O
BSD	B-Operating_System
behaviors	O
with	O
regard	O
to	O
ignoring	O
SIGCHLD	B-Operating_System
,	O
calling	O
wait	B-Operating_System
remains	O
the	O
most	O
portable	O
paradigm	O
for	O
cleaning	O
up	O
after	O
forked	O
child	O
processes	O
.	O
</s>
