Re: RE: [vox-tech] Good distro for beginner?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: RE: [vox-tech] Good distro for beginner?
On Sat, 7 Apr 2001, Peter Jay Salzman wrote:
> On Sat 07 Apr 01, 10:44 AM, jdnewmil@dcn.davis.ca.us said:
> > On Sat, 7 Apr 2001, Deja User wrote:
> >
> > > I know this is vague, but a colleague of mine is vexed regarding a
> > > "init command is respawning too rapidly" error. Any ideas? If not,
> > > that's fine. I've seen this before also, but never found out what
> > > would cause this type of error. The question seems to be "too rapidly"
> > > for what? UA
> >
> > Sounds like they put an ampersand at the end of an inittab line. init
> > monitors the processes it starts, and the ampersand disonnects from the
> > invoked process immediately, and init thinks it needs to start it
> > again. Voila! processes spawning like rabbits.
>
> jeff, shouldn't init only do this when it receives a SIGCHLD signal?
Gads, I knew a half-baked answer wouldn't cut it. :)
To spawn a new process, process A (running program "grandma"; aka "init")
forks, so there are two copies of grandma in processes A and B.
Then B execs the new program which clears out the existing program in
process B, replacing it with program ma ("bash"). If program ma forks
into processes B and C (as "bash" will do if given an ampersand), and
C execs program "child" (getty), then there are three processes involved.
At this point, program "ma" (bash) has done its job, so it exits, and
process A gets SIGCHLD, even though program "child" (getty) is still
running. Then "grandma" goes into action again.
If you DON'T use the ampersand, then process B running the shell will not
fork, and will simply replace itself with getty.
And so, the saga of Eve begetting mankind is echoed in Linux. :)
---------------------------------------------------------------------------
Jeff Newmiller The ..... ..... Go Live...
DCN:<jdnewmil@dcn.davis.ca.us> Basics: ##.#. ##.#. Live Go...
Work:<JeffN@endecon.com> Live: OO#.. Dead: OO#.. Playing
Research Engineer (Solar/Batteries O.O#. #.O#. with
/Software/Embedded Controllers) .OO#. .OO#. rocks...2k
---------------------------------------------------------------------------
|