Subject: rc.d wishes (was Re: admin script for ipfilter)
To: None <tech-userlevel@NetBSD.org>
From: Pavel Cahyna <pavel@NetBSD.org>
List: tech-userlevel
Date: 12/27/2006 18:56:12
On Wed, Dec 27, 2006 at 06:07:17PM +0100, Hubert Feyrer wrote:
> while talking about wishes: I always wanted 'sh /etc/rc.d/foo start' to do just
> that, regardless if i have foo=yes in /etc/rc.conf or not. A possible way to
> implement that would be to only check the variable on bootup, e.g. via a new
> keyword 'bootstart' or even 'boot' instead of 'start'.
There is "onestart" for that.
Me, I wished that the keywords would be used to truly indicate
dependencies, not only the order of execution. So if "foo" depends on
"bar", none is enabled, and I do "/etc/rc.d/foo onestart", bar would be
started too or I would get a warning that it can't be started. (Now this
is approximated by $required_vars, see /etc/rc.d/nfsd, which is
unsatisfying.)
Services in Windows NT apparently work this way...
Pavel