athom...@athompso.net (Adam Thompson), 2014.10.24 (Fri) 11:19 (CEST):
> On 14-10-24 03:57 AM, Craig R. Skinner wrote:
> >On 2014-10-24 Fri 15:29 PM |, Worik Stanton wrote:
> >>I installed postgresql (with pkg_add) and it did not change this, I had
> >>to change /etc/rc.local by hand.  Is there some reason why postgresql
> >>should not be started after a reboot?  Have I completely got the wrong
> >>end of the stick?
> >You're very close.
> >
> >$ man rc.conf:
> 
> Adding to Craig's comments, no, OpenBSD packages generally do NOT modify
> /etc/rc.conf.local for you.

and now there's rcctl(8), so there is almost no reason to touch
rc.conc.local(8) manually anymore.

But be warned (it's biting me a bit): using ``rcctl disable xxxxxx''
doesn't just remove xxxxxx from pkg_scripts, it removes the
xxxxxx_flags as well. In case you had carefully crafted command line
parameters there, the simple ``rcctl disable'' command might make you
unhappy. (rcctl disable is not reversed by rcctl enable, that is.)

Question: why does "rcctl disable xxxxxx" not just remove xxxxxx from
pkg_scripts? (But also removes xxxxxx_flags.) Removing the xxxxxx_flags
could be done via ``rcctl disable xxxxxx flags ""'' if really wanted,
no?

And while I'm in asking mode: the rcctl(8) ``default'' command cannot
have values for non-base services/daemons, right?

Bye + TIA, Marcus

> Until very recently, /etc.rc.conf.local was executed as a shell script, so
> arbitrarily modifying things in a (possibly completely custom) shell script
> would be a Very Bad Thing.
> Recent changes mean that /etc/rc.conf.local is now parsed instead of being
> executed; the format & syntax are now much more constrained, and AFAIK it
> would be possible for packages to now automatically make changes in a
> safe(r) way.
> 
> However, I still don't expect to see that happen - it just doesn't feel like
> the OpenBSD way.
> If you want to run a process, you should have to perform some manual step to
> cause it to run.  Processes that unexpectedly spring into existence at the
> next reboot are also considered (at least by me) a Bad Thing.
> !DSPAM:544a19e1213124755513058!

Reply via email to