questionable feature- rcvar woes

Mike Lempriere mike at
Wed Nov 28 15:12:35 PST 2007

Here's where I must disagree -- and you just explained why -- "...admin 
should be aware of".  Nonsense!  I do not have time in my life to keep 
track of every nuance of every version of every OS.  I fell into this 
same trap.  Took me a while to figure it out.  That's why I don't have 
time to take on other such trivialities!  (It would be interesting to 
take a poll to determine how many wasted hours this silly gotcha has 
cost the members of this list, but let's not waste the bandwidth.)

The script should be smart enough to know whether the it is being 
invoked through bootup/shutdown vs. admin interactive and should behave 
appropriately.  If this was hard to do or unreliable, maybe it wouldn't 
be worthwhile doing, but it would be so easy to fix; at the crudest 
level just pass in an extra parm in the startup/shutdown sequence and 
act on that...

Clifton Royston wrote:
> On Wed, Nov 28, 2007 at 08:37:30PM +0100, Milan Obuch wrote:
> ...
>> Agree - everything just fine.
>>> Everything looks fine, but when I disable powerd in rc.conf then problem
>>> arise.
>>> 1) Disable powerd in rc.conf- comment it out.
>>> # enable_powerd="YES"
>>> 2) Stop powerd
>>> # /etc/rc.d/powerd stop
>>> ...silence- nothing in logs either.
>> Stop for a moment - enable_powerd means actually 'enable action carried 
>> by /etc/rc.d/powerd script', using this semantics actually explains all 
>> details. Or you could treat it as a stack of a sort, reversing order to 2) 1) 
>> just produces desired output.
>>> What? Not even a warning message and powerd is actually running- why I have
>>> to reboot to disable it? I know that I can stop it by enabling it in
>>> rc.conf but what the point? Same problem when I want to start some service
>>> without appropriate line in rc.conf. I'd prefer to see somekind of warning
>>> about misconfigured rc.conf or at least information about what's going on
>>> in reality.
>> I hope my explanation above suffices. I was hit by this too, but rc.d scripts 
>> behavior is well designed and understandable. If, for some reason, you are 
>> still hit with described behavior, there is a save rope - /etc/rc.d/powerd 
>> forcestop will stop powerd even if there is no enable var in rc.conf.
>   Agree, agree, agree.  This is just something that any up-to-date
> admin should be aware of and in tune with.  Yes, it's a bit different
> from how some-but-not-all start/stop scripts behaved in 4.x or older
> systems, but it's a very sensible behavior and it makes the /etc/rc.d
> and /usr/local/etc/rc.d scripts behave much more coherently and
> consistently.
>   There are two different ways to get it to DWIM - either get in the
> habit of doing 2) then 1), or get in the habit of using forcestop. 
> Given this, I don't see it as a problem.
>   -- Clifton

Mike Lempriere- Home: mike at  Phone: 206-780-2146
Cellphone: 206-200-5902;  text pager: mlemp at

More information about the freebsd-stable mailing list