Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 30 Jan 1999 10:06:51 -0700
From:      Wes =?iso-8859-1?Q?Peters=D4?==?iso-8859-1?Q?=40=21=EA?= =?iso-8859-1?Q?=80?==?iso-8859-1?Q?=EA?==?iso-8859-1?Q?=80=DD=E7?= =?iso-8859-1?Q?=805=EA?==?iso-8859-1?Q?=C0?==?iso-8859-1?Q?=EA?=  <wes@softweyr.com>
To:        "Daniel C. Sobral" <dcs@newsguy.com>
Cc:        Brandon Gillespie <brandon@roguetrader.com>, Robert Withrow <witr@rwwa.com>, freebsd-hackers@FreeBSD.ORG
Subject:   Re: more modular rc/init/uninit system...
Message-ID:  <36B33C2B.CDB07CCB@softweyr.com>
References:  <36B1739E.1A22A983@urc.ac.ru> <199901291406.JAA27108@spooky.rwwa.com> <19990129115122.A25989@cold.org> <36B2CD01.69CFEFA8@newsguy.com>

next in thread | previous in thread | raw e-mail | index | archive | help
"Daniel C. Sobral" wrote:
> 
> Brandon Gillespie wrote:
> >
> > Following the idea of just modularizing the executable part of
> > /etc/rc*, there are two options: 1) make Yet Another Standard, or
> > 2. follow an existing and widely accepted standard, at least loosely.
> >
> > I believe 2. to be the better option, and thus suggested putting the
> > scripts in /sbin/init.d and /sbin/rc.d (symlinked to init.d).
> > Furthermore, as I stated in the web page the scripts *should not be
> > changed*  The only role they play is _order_.  Whether something runs
> > or not is managed by the config script.  Because of this the admin
> > should really _never_ have to touch the symlinks (unless they are
> > making something new).
> 
> SYSV way is confusing. More than that, SYSV is a *hack*. While it
> may do whatever it was supposed to do, it's deficiencies make clear
> that it was, at best, a good first try. I don't see why we have to
> stick to a hack just because it was the first implementation tried.

The idea of ordering the startup and shutdown is a good one, but the
way it was solved in SYSV is really goofy.  Good ole USL strikes
again.  ;^)

> FreeBSD's way is good, though it simply does not try to solve some
> of the problems SYSV way tries to. If we are going to change the
> *GOOD WAY* we do things now, we better change to *ANOTHER GOOD WAY*.
> SYSV way is, thus, not acceptable.

Agreed.  If we're going to hack this, we should hack it better, not
just different.  I like the idea of modularizing the different parts
of the rc files so you can re-run just one, or shutdown and startup
up subsystems all by themselves.

> > I do like the dependancy and register parts, however.
> 
> The problem with dependencies is that you need to build a graph, so
> you know how to shutdown a service, while correctly shuting down
> everything that depended on it (which the service is most likely to
> *not* know -- take, for instance, the networking stack).

And wouldn't you know it, we already have a tool for managing 
dependency graphs.  ;^)

How about a Makefile, with "startup" and "shutdown" targets, and
individual "start" and "stop" targets for each subsystem?  The 
configuration settings would remain in rc.conf and rc.conf.local,
where they belong, and each "subsystem" startup moved to an
individual script.  /etc/rc would bring the system up just far 
enough for make to function, and then cd /etc; make startup.  You
could start a particular subsystem, or shut it down, with i.e.
"make start.nfsserver" or "make stop.nfsserver".

Good?  Bad?  Indifferent?

-- 
       "Where am I, and what am I doing in this handbasket?"

Wes Peters                                                 Softweyr LLC
http://www.softweyr.com/~softweyr                      wes@softweyr.com

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?36B33C2B.CDB07CCB>