bin/55346: /bin/sh eats memory and CPU infinitely

Eugene Grosbein eugen at kuzbass.ru
Thu Aug 14 20:15:19 PDT 2003


Doug White wrote:

> > It seems /bin/sh in 4.8-STABLE has problem with SIGCHLD processing.
> > In short, it often fails to process it correctly, zombies float
> > around, jobs are not marked as finished in jobtab[] that fills memory
> > and takes much CPU to be processed.
> >
> > Run this one-liner using /bin/sh and see hundreds of zombies:
> >
> > #!/bin/sh
> > while :; do : & done
> 
> Considering that with this script you are forkbombing your machine as
> root, I think this falls into the "doctor it hurts when I shoot my foot"
> category.

Perhaps. Anyway, debug shows that jobtab[] in /bin/sh grows indefinitely
in some scenarios and the reason should be SIGCHLD processing problem.

Eugene


More information about the freebsd-stable mailing list