From owner-freebsd-stable Wed Apr 25 15:29: 7 2001 Delivered-To: freebsd-stable@freebsd.org Received: from dell.dannyland.org (dell.dannyland.org [64.81.36.13]) by hub.freebsd.org (Postfix) with ESMTP id 6358C37B423 for ; Wed, 25 Apr 2001 15:29:04 -0700 (PDT) (envelope-from dannyman@toldme.com) Received: by dell.dannyland.org (Postfix, from userid 1001) id 0EF555BFE; Wed, 25 Apr 2001 15:28:53 -0700 (PDT) Date: Wed, 25 Apr 2001 15:28:53 -0700 From: dannyman To: Sven Huster Cc: freebsd-stable@freebsd.org Subject: Re: diskless startup again Message-ID: <20010425152853.H1478@dell.dannyland.org> References: <5.1.0.14.0.20010425105221.02657d00@mx01.mailsurf.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0.1i In-Reply-To: <5.1.0.14.0.20010425105221.02657d00@mx01.mailsurf.com>; from sven.huster@mailsurf.com on Wed, Apr 25, 2001 at 11:00:04AM +0200 X-Loop: djhoward@uiuc.edu X-URL: http://www.dannyland.org/~dannyman/ Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Wed, Apr 25, 2001 at 11:00:04AM +0200, Sven Huster wrote: [...] > Another thing is that i want to run different local daemons depending on > the machines (ip's or hostnames), or machine groups > So what i thought is to add the same function as for /etc to /usr/local/etc, > maybe which the enhancement of grouping machines in a config file. > This might be also useful for global config of "normal" machines, > which then can be mirrored to all of them. > > So my intention is to build clusters of www-server, mysql-server ..., > which boot from the same root fs, use the same /usr, /usr/local ... From rc.diskless1: # Files in /etc are copied to /conf/etc which is writable. Then # per-machine configs from /conf/ip.address/etc are copied onto this # directory. First choice is using the client's IP, then the client's # broadcast address, then a default configuration. # This way we have some flexibility to handle clusters of machines # on separate subnets. I use this. In my install script I do something slightly different: # Copy default files in to /tmp/root echo "Copying files from /install/default to /tmp/root:" cp -Rp /install/default/* /tmp/root if [ -d /install/`hostname` ] ; then echo "Copying files from /install/`hostname` to /tmp/root:" cp -Rp /install/`hostname`/* /tmp/root fi if [ -d /install/${bootp_ipa} ] ; then echo "Copying files from /install/${bootp_ipa} to /tmp/root:" cp -Rp /install/${bootp_ipa}/* /tmp/root fi This copies files from /install/default, /install/ and /install/ in sequence, so you can put everything in default, and selectively override it. -danny To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message