Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Mar 2010 12:20:44 -0700
From:      Xin LI <delphij@delphij.net>
To:        freebsd-rc@freebsd.org
Subject:   Re: mountd and reload
Message-ID:  <4BB0FD8C.6070000@delphij.net>
In-Reply-To: <4BAE67FA.6070609@FreeBSD.org>
References:  <201003261410.35830.jhb@freebsd.org>	<a78074951003261218h39d6f021u7376ee67b5d74437@mail.gmail.com> <4BAE67FA.6070609@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 2010/03/27 13:18, Doug Barton wrote:
> On 03/26/10 12:18, Xin LI wrote:
>> On Fri, Mar 26, 2010 at 11:10 AM, John Baldwin <jhb@freebsd.org> wrote:
>>> FYI, it would be nice if someone could fix it so that /etc/rc.d/mountd reload
>>> works when nfs_server_enable="YES" is set in /etc/rc.conf but
>>> mountd_enable="YES" is not explicitly set.
> 
>> How would you think about something like this (hackish, though...  I
>> think we should perhaps make a 'rcvars' list):
> 
> I am opposed to it. We already have a mechanism for starting things that
> don't have _enable set.
> 
> OTOH I agree that there is a more general problem that our rc.d system
> should be smarter about what dependent services need to be enabled for a
> given service but that problem should be solved generally. One-off hacks
> like this will create a lot of drama and confusion that I would really
> prefer to avoid.

I think what we really want is to explicitly say, e.g. nfsd_enable is
considered the same as if mountd_enable set to "YES" regardless whether
we got a "NO" from the default rc.conf.

e.g. in the past we do:

 - in nfsd script:
   if enabled="YES" then forcestart mountd

Now we do:

 - in nfsd script: start when nfsd_enable="YES"
 - in mountd script: start when either mountd_enable="YES" or
nfsd_enabled="YES"

And, make sure that these scripts are properly ordered when necessary.

Cheers,
- -- 
Xin LI <delphij@delphij.net>	http://www.delphij.net/
FreeBSD - The Power to Serve!	       Live free or die
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (FreeBSD)

iQEcBAEBAgAGBQJLsP2MAAoJEATO+BI/yjfB4oIH/i3RSGWbKilSs4cvlFELVy8R
eWE/6j2OOGzKLACC0kpoHx41AMNSiA9+4VN/P9QjSsLzsMBprXn/r057SrFr4eza
WO4lbmfTYuuQlF4XP+UNQfaQ1t7LXsjlvqpilfd51CJUuxZgVVfuEx5UhG4kJviO
HrgBo7yvhsRozU/7ncCyQhtCzA9bliJ44OzOf+5R0tYn43ochVnIDrL/e4qz19Jy
f2W/lMVgU1HYdsAoKvVKPchPPNir/PVOeqKLdwgSM9rb8P53itFFgl4hh31etFxA
wG4j9qG1meo5jjfLCpouOfVKgI4giweHQLDfqFt3rHw6HFs35l6qPcCMh1xPLok=
=+eVS
-----END PGP SIGNATURE-----



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4BB0FD8C.6070000>