Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 14 Apr 1998 08:51:08 -0700 (PDT)
From:      patl@phoenix.volant.org
To:        freebsd-questions@FreeBSD.ORG
Subject:   Re: /etc/rc.local vs. /usr/local/etc/rc.d vs. ???
Message-ID:  <ML-3.3.892569068.7515.patl@asimov>
In-Reply-To: <19980414013359.26683@ucb.crimea.ua>

next in thread | previous in thread | raw e-mail | index | archive | help
> > ...
> > Now, we use /usr/local for site-specific (vs. machine-specific) things.
> > 
> > This machine exports a filesystem that most machines import as
> > /usr/local. 
> > We also would like to use programs &c. that are on this filesystem from
> > this machine's /usr/local; therefore, that filesystem also appears on
> > this machine as /usr/local.
> > 
> > However, if I put the initialization stuff for the machine-specific
> > servers in /usr/local/etc/rc.d, every machine on the net sees that,
> > and tries to start them up at boot time.
> > 
> > This really is not what I'd prefer to do.
> > 
> > So, for now, I've gone back to the (deprecated) /etc/rc.local for this
> > purpose.
> > 
> > ...
> 
> I have an idea!
> Change your rc.conf files:
> 
> local_startup="/usr/local/etc/rc.d /usr/local/etc/rc.d/${hostname}
> /usr/X11R6/etc/rc.d" 
> 
> Then put the staff that should be started on each machine in rc.d
> directory, and put the staff for machine myname.my.domain into
> rc.d/myname.my.domain. 

Another technique is to make /usr/local/etc/rc.d a symlink back to
a local directory.  (E.g., /etc/local.rc.d)  That way you don't
have to remember to modify rc.conf when you upgrade the OS on the
client machines.  And you still get the benefits of separate rc
scripts for each local daemon.

Of course this assumes that you are not one of those sysadmins
who really hates symlink proliferation...


-Pat

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?ML-3.3.892569068.7515.patl>