Date: Tue, 17 Jul 2007 12:44:22 +0200 (CEST) From: Oliver Fromme <olli@lurza.secnetix.de> To: freebsd-current@FreeBSD.ORG, marck@rinet.ru, dougb@FreeBSD.ORG Subject: Re: RFT: bin/106642: [patch] Allow excluding certain files from mergemaster (8) Message-ID: <200707171044.l6HAiMs1089059@lurza.secnetix.de> In-Reply-To: <20070717143422.F82929@woozle.rinet.ru>
next in thread | previous in thread | raw e-mail | index | archive | help
Dmitry Morozovsky wrote: > Oliver Fromme wrote: > OF> On my notebook I have a script /etc/rc.d/net-detect that > OF> pings several IP addresses in order to find out in which > OF> network environment the notebook is used (at the office, > OF> at home with wlan, at home with 100base-t, or no network > OF> at all). The script then adjusts several symlinks based > OF> on the network environment, i.e. several files in /etc > OF> are changed, including rc.conf, ntp.conf, resolv.conf, > OF> fstab (!), hosts and others. > OF> > OF> That script runs as the very first rc script, even before > OF> root is mounted r/w (it does fsck -p / + mount -u -o rw /, > OF> then changes the symlinks, then mount -u -o ro /). > OF> > OF> Works perfectly fine for me. The only thing I need to be > OF> careful about is to tell mergemaster not to remove that > OF> script. Mergemaster's default, unfortunately, is to delete > OF> all unknown scripts in /etc/rc.d. Of course I do have a > OF> backup copy, so I can easily recover if needed. > > Hmm, if it is the very first rc.d script, why don't you name it > /etc/rc.early ? Because /etc/rc.early is _not_ the very first script being run. See: $ rcorder /etc/rc.d/* | sed -n '1,/early/p' /etc/rc.d/dumpon /etc/rc.d/initrandom /etc/rc.d/geli /etc/rc.d/gbde /etc/rc.d/encswap /etc/rc.d/ccd /etc/rc.d/swap1 /etc/rc.d/mdconfig /etc/rc.d/ramdisk /etc/rc.d/early.sh $ Best regards Oliver -- Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing b. M. Handelsregister: Registergericht Muenchen, HRA 74606, Geschäftsfuehrung: secnetix Verwaltungsgesellsch. mbH, Handelsregister: Registergericht Mün- chen, HRB 125758, Geschäftsführer: Maik Bachmann, Olaf Erb, Ralf Gebhart FreeBSD-Dienstleistungen, -Produkte und mehr: http://www.secnetix.de/bsd "I started using PostgreSQL around a month ago, and the feeling is similar to the switch from Linux to FreeBSD in '96 -- 'wow!'." -- Oddbjorn Steffensen
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200707171044.l6HAiMs1089059>