[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: /etc/rc?.d question



Run states 0 and 6 are both characterized by complete shutdown of all
services.  And since the script name is just a way to find the file(s)
of interest (and _all_ files are "of interest" for 0/6) and it is the
argument that actually causes the action, it doesn't matter what name is
used so long as all scripts get the "stop" action argument.  This is why
it works.

As to the "policy" governing this, the logical assumption, based on what
I've read in the Debian policy document and the README in /etc/init.d,
would be that all the scripts in these two directories should be named
as K* files.

I don't have access to a Linux system right now to look, but I'd take a
peek at the rc0 and rc6 scripts and see how they access the files in
their respective directories.  It might provide more insight into the
why.

Bob

Christian Pernegger wrote:
> 
> On Mon, Sep 11, 2000 at 11:19:23PM +0000, Miquel van Smoorenburg wrote:
> 
> > >I uncommented the debug line in /etc/init.d/rc and noticed that
> > >all scrips in rc6.d / rc0.d were called with "stop" on shutdown
> > >_regardless of prefix_. Now I'm totally confused.
> >
> > Why don't you simply read the documentation?
> >
> > There is a README in /etc/init.d for a reason, you know ..
> 
> I fully understand that you as the Grand Master of the Debian init system
> might be annoyed by such a question, but why reply, then?
> 
> That said, I usually appreciate RTFM pointers - in this case however I have
> read the FM in question. (policy manual, sec 3.3)
> 
> All I could find was that "update-rc.d" by default stops stuff in 0/6,
> = creates a K* symlink. (That it does...)
> 
> However, this does not explain why all the _existing_ S??something scripts
> in 0/6 are called with stop. (The manual states repeatedly that S* scripts
> will be called with start.)
> 
> I'd be grateful if you could take the time to clarify this - a pointer'd
> do nicely.
> 
> Regards
> 
> Christian
> 
>   ------------------------------------------------------------------------
>    Part 1.2Type: application/pgp-signature



Reply to: