From owner-freebsd-rc@FreeBSD.ORG Fri Sep 30 06:55:48 2005 Return-Path: X-Original-To: freebsd-rc@FreeBSD.org Delivered-To: freebsd-rc@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3670716A41F for ; Fri, 30 Sep 2005 06:55:48 +0000 (GMT) (envelope-from dougb@FreeBSD.org) Received: from mail2.fluidhosting.com (mail2.fluidhosting.com [204.14.90.62]) by mx1.FreeBSD.org (Postfix) with SMTP id 6FF1543D48 for ; Fri, 30 Sep 2005 06:55:47 +0000 (GMT) (envelope-from dougb@FreeBSD.org) Received: (qmail 84446 invoked by uid 399); 30 Sep 2005 06:55:46 -0000 Received: from mail1.fluidhosting.com (204.14.90.61) by mail2.fluidhosting.com with SMTP; 30 Sep 2005 06:55:46 -0000 Received: (qmail 11639 invoked by uid 399); 30 Sep 2005 06:55:46 -0000 Received: from localhost (HELO ?192.168.1.102?) (dougb@dougbarton.net@127.0.0.1) by localhost with SMTP; 30 Sep 2005 06:55:46 -0000 Message-ID: <433CE171.8080301@FreeBSD.org> Date: Thu, 29 Sep 2005 23:55:45 -0700 From: Doug Barton Organization: http://www.FreeBSD.org/ User-Agent: Mozilla Thunderbird 1.0.6 (X11/20050929) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Yar Tikhiy References: <20050928164803.GA11556@comp.chem.msu.su> In-Reply-To: <20050928164803.GA11556@comp.chem.msu.su> X-Enigmail-Version: 0.92.1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: arch@freebsd.org, freebsd-rc@FreeBSD.org Subject: Re: Minor issues in our rcNG X-BeenThere: freebsd-rc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-rc@FreeBSD.org List-Id: "Discussion related to /etc/rc.d design and implementation." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 30 Sep 2005 06:55:48 -0000 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Ok, so, this is going to seem like "pick on Yar" night, but it really isn't meant to be. :) We have a list for discussion of issues related to the rc.d system (it's no longer referred to as rcNG), so I'm cc'ing that list, and would ask that you follow up there instead of -arch. Yar Tikhiy wrote: | Hi there, | | The larger issue I'd like to discuss is as follows. Presently, | ${_program} variables are special in that they always override | ${command}. Some rc.d scripts (ab)use this to skip setting ${command}, | e.g., sshd. Some other scripts (ab)use ${_program} despite | they are not just starting ${command} once, e.g., pf, and so make | rc.subr think they have functionality that isn't realy there, such as | poll. Perhaps it's time to separate these two cases in a way? I think that here, and in the rest of the message you've stated the problem you're concerned about well, but I confess that I'm not 100% sure what the negative affects of this problem are. Sorry if I'm being dense here, but before I get excited about this I want to be sure I understand the problem. | I can see two possible approaches. One is to require scripts just | starting a daemon always set ${command}, and to apply the attached | patch to rc.subr. With the patch, ${command} is overridden only | if it was set in the first place. The other approach is to prevent | non-daemon scripts from abusing ${_program}. However, in the | latter case defining ${_program}, e.g., by mistake, still can | affect the script while it should not. | | The second issue is rather small. The rc command "reload" is | supported by code in /etc/rc.subr, but it doesn't appear on the | default list of commands unlike "status" or "poll" when there is | ${pidfile} or ${command} set, and so it is unusable by default. | Scripts have to use ``extra_commands=reload''. In addition, all | this is undocumented. Should "reload" be added to the list of | available commands along with "status" and "poll"? I think this sounds reasonable. Do you have patches for this? | Finally, we have a script named rcconf.sh which doesn't seem | to do anything useful now since all the other scripts invoke | load_rc_config by their own. Can we drop it then? I wouldn't lose sleep over this one, I'm planning to deal with it when I introduce the changes for rcorder in /usr/local/etc/rc.d. Doug - -- ~ This .signature sanitized for your protection -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQFDPOFxyIakK9Wy8PsRArroAKC6lkrsFVBZVXv+2Cwh+2/F06BEKQCfS70B +ydJ4hsRhsdVuM+KtXEbxfc= =WKZt -----END PGP SIGNATURE-----