linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Init - how does it work?
@ 2002-09-12 14:27 Johan Brodin
  2002-09-12 16:39 ` Nick LeRoy
  0 siblings, 1 reply; 2+ messages in thread
From: Johan Brodin @ 2002-09-12 14:27 UTC (permalink / raw)
  To: linux-kernel

Hi!

I am new to this list, so I will take one second to present myself.
My name is Johan and I am a 23-year old student at Chalmers university of
technology in Sweden. The reason for joining this list is that I am
currently doing my Master Thesis Project in Computer Science and
Engineering. My thesis is namned "Design of dependable distributed
UNIX-based systems" and one issue that I am looking into is process
supervision.

I tried to configure init to start and respawn processes and this worked
great, no problems at all, but what really would make me happy is if
someone of all you subscribers to this list could explain how this feature
(respawn) works. How is init told that it must respawn the process? and
such things! If someone could find the time to help me out, I would be
very grateful.

Thanks!
/Johan



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Init - how does it work?
  2002-09-12 14:27 Init - how does it work? Johan Brodin
@ 2002-09-12 16:39 ` Nick LeRoy
  0 siblings, 0 replies; 2+ messages in thread
From: Nick LeRoy @ 2002-09-12 16:39 UTC (permalink / raw)
  To: Johan Brodin, linux-kernel

On Thursday 12 September 2002 07:27, Johan Brodin wrote:
> Hi!
>
> I am new to this list, so I will take one second to present myself.
> My name is Johan and I am a 23-year old student at Chalmers university of
> technology in Sweden. The reason for joining this list is that I am
> currently doing my Master Thesis Project in Computer Science and
> Engineering. My thesis is namned "Design of dependable distributed
> UNIX-based systems" and one issue that I am looking into is process
> supervision.
>
> I tried to configure init to start and respawn processes and this worked
> great, no problems at all, but what really would make me happy is if
> someone of all you subscribers to this list could explain how this feature
> (respawn) works. How is init told that it must respawn the process? and
> such things! If someone could find the time to help me out, I would be
> very grateful.

Well, I'd reccomend reading the sources...

But, the short answer is SIGCHLD.  A process can get a SIGCHLD sent to it when 
a child process terminates.  Init maintains a list of child processes; when 
it gets a SIGCHLD, it knows that one of them dies, and restarts it.  
Obviously, this is somewhat oversimplified, but it's in general how to 
occomplish these things.

Hope this helps.  BTW, I'm pretty sure that this is coverred in a lot of 
books.  I'd start with the Stevens book (I don't remember the exact name of 
it off hand, however; something like "Unix systems programming").

-Nick


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-09-12 14:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-09-12 14:27 Init - how does it work? Johan Brodin
2002-09-12 16:39 ` Nick LeRoy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).