mark at endpoint.com
Wed Nov 7 10:20:43 EST 2007
> Can anyone tell me what PreForkSingleFork does? The docs don't
> explain it and I can't follow the code.
Standard PreFork uses the typical double-fork method in UNIX for
generating daemons so as to avoid zombies (or more specifically needing
to deal with them). However, forking IC daemons is relatively expensive.
For most (if not all) sane, modern Unixen, you can avoid the relative
expense of double forking by setting SIGCHLD to IGNORE in the master,
which accomplishes roughly the same goal. It states, essentially, that
the parent is not interested in the result of the child's process, so
don't zombify my kids waiting for me to check on them.
If you're running PreFork, you should always try PreForkSingleFork too
to start. Only turn off PreForkSingleFork if something pathological
happens (the most likely outcome being a slew of zombies piling up that
are never reaped). Using it successfully creates the absolute minimal
number of forks necessary.
End Point Corporation
More information about the interchange-users