Subject: Re: Updating /etc...
To: None <ghudson@mit.edu>
From: Mark W. Eichin <eichin@kitten.gen.ma.us>
List: current-users
Date: 12/19/1995 13:04:45
> It evades me why people in the System V world decided that each
> package should have its own startup/shutdown script in /etc. Why does
> all that hair belong in /etc, instead of in the executables for the
> packages themselves?
/etc/rc?.d/S??pkg and K??pkg are a simple mechanism for packages which
need boot time start up (and possibly clean shutdown) to have their
own scripts automatically installed and have a reasonable expectation
of them running at the right time.
A particular example: a BSD installation of a Kerberos server goes
something like
unpack the install kit
update some config files
edit rc.local to add a kerberos start up after your
filesystems have been mounted and the net is up but
*before* portmapper starts (so it doesn't hand port
750 off to lockd or something)
On an SVR4 system, that is replaced with
pkgadd kerberos
(roughly.) The config-file changes (/etc/services is the one that
comes to mind, I'm not talking about the things that need site input
like krb.conf) are handled by a script; the startup and shutdown are
handled by dropping a script in the right directory.
This is independent of runlevels -- it does require some convention
for an ordering of a continuum of scripts, basically there are a
couple of points (20, 50, 70 or something like that, it's in the man
pages) where certain actions are guaranteed to have happenned, like by
70 the net is up (so S76xntpd is in my ntp package.)
Now perhaps I've missed your original point, and /etc is a bad place
for these directories. Quite possible; does /libexec make more sense?
_Mark_ <eichin@kitten.gen.ma.us>
The Herd of Kittens