Subject: Re: CVS commit: src
To: Andrew Gillham <gillhaa@ghost.whirlpool.com>
From: dustin sallings <dustin@spy.net>
List: current-users
Date: 03/16/1999 22:04:11
On Wed, 17 Mar 1999, Andrew Gillham wrote:
// And what if I want one 'rc.conf' for a laptop at home, and one for
// the laptop while "mobile", and one for it when it is at work? Now I
// have to use some fancy script to keep track of all the little bits
// that relate to this hostname. Sure 'dhclient' would probably solve
// the interface and resolver bits, but where is the decision about
// whether to launch a web server, and proxy server, nfsd, etc,
// depending on my ip address? For me this would be via an "overall
// configuration" file like rc.conf that is switched depending on where
// my laptop is. Little files in /etc are not the best for this.
// (neither is switching rc.conf actually)
(from my laptop, I love DHCP):
DOMAIN=`domainname`
echo "Doing local configuration for $DOMAIN"
if [ -f /usr/local/etc/dhconfigs/$DOMAIN ]
then
/usr/local/etc/dhconfigs/$DOMAIN
else
echo "No config for this domain ($DOMAIN)"
fi
It starts up netatalk in the right places, NIS in the right
places, Samba in the right places, etc...
// Another thing that might be worth considering, is creating a method
// of using a specific rc.conf.* depending on what ethernet device was
// found, or based on the mac address found. I have a docking station
// and home, and at work. The only real difference is the mac address
// on 'ex0', yet I want a different rc.conf for each machine. I also
// want different /etc/fstab, or /etc/amd/*, etc.
dhclient really is a win here
// As far as _I_ am concerned the _network_ is up. My
// ftp/telnet/web/whatever client will work. Perhaps I don't even
// start "services" on my machine? IMHO, 'rc.net' is fine for starting
// network interfaces. Then there could be an 'rc.daemon', or
// 'rc.servers' or whatever.
This is why I like the SysV. I think that's *MUCH* too general. I
want rc.apache, rc.squid, rc.pageserv, etc... I want these to be able to
not only start things, but stop them. I want to be able to have packages
install in such a way that they can safely add startup scripts, and
even...take them away. rm is certainly a pleasant way of disabling a
package (or mv, or chkconfig, etc...).
// services != network. I could start services with only a loopback,
// which is not exactly "network" either. Services use the network,
// but are not the network. Admittedly without services of some sort,
// there is little use for the network.
You don't make outbound connections from your UNIX machines? :)
--
Principal Member Technical Staff, beyond.com The world is watching America,
pub 1024/3CAE01D5 1994/11/03 Dustin Sallings <dustin@spy.net>
| Key fingerprint = 87 02 57 08 02 D0 DA D6 C8 0F 3E 65 51 98 D8 BE
L______________________________________________ and America is watching TV. __