From owner-freebsd-mobile Sat Jul 7 15: 7:52 2001 Delivered-To: freebsd-mobile@freebsd.org Received: from moek.pir.net (moek.pir.net [130.64.1.215]) by hub.freebsd.org (Postfix) with ESMTP id 69E8337B403 for ; Sat, 7 Jul 2001 15:07:48 -0700 (PDT) (envelope-from pir@pir.net) Received: from pir by moek.pir.net with local (Exim) id 15J0Et-0000UV-00 for freebsd-mobile@FreeBSD.ORG; Sat, 07 Jul 2001 18:07:47 -0400 Date: Sat, 7 Jul 2001 18:07:47 -0400 From: Peter Radcliffe To: freebsd-mobile@FreeBSD.ORG Subject: Re: ifconfig wireless card options and DHCP Message-ID: <20010707180747.E27611@pir.net> Reply-To: freebsd-mobile@freebsd.org Mail-Followup-To: freebsd-mobile@FreeBSD.ORG References: <20010707160606.B27611@pir.net> <200107072144.f67LiWx28122@bunrab.catwhisker.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <200107072144.f67LiWx28122@bunrab.catwhisker.org>; from david@catwhisker.org on Sat, Jul 07, 2001 at 02:44:32PM -0700 X-fish: < X-Copy-On-Listmail: Please do NOT Cc: me on list mail. Sender: owner-freebsd-mobile@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org David Wolfskill probably said: > Hmm... sounds as if I'm failing to express myself adequately; sorry. > From my perspective, putting "site specific" stuff in a given (mobile) > machine's /etc/*.local is what I would call "hard coding", and is a > problem to avoid. > For example, I normally use my laptop both at home and at work; in both > cases, I normally use the an0 interface. I use my laptop in various places with various wired and wireless configurations. I use rc.conf.local not as a "hardcoded" file (rc.conf is my hardcoded file), but as a place to put changable configurations. I select which configuration I wish to use with a small script. > However, there certainly exist differences between those > environments, and I am averse to trying to use an approach that > requires that I "tweak" something in a file system ini order to > allow the machine to join the network. I set up configrations and simply select which one (or ones, I can be using multiple interfaces at a time). > But I believe that setting things up as dhclient is, where there can be > an (optional) "hooks" script would be a good way to handle both > approaches, As I said, I use rc.conf.local as a "hooks" script. I don't see the requirement for a seperate one, but it is certainly easy to provide one as you have shown. I'd suggest making the path of the script an rc.conf variable, though. > :-} But you need a way to select which, yes? And an opportunity to do > so.... I don't want something to try various configs on it's own. ssids always go out in the clear, even with WEP on, and I don't wish to broadcast ssids that may be closed, private and not belong to me. I want the interface to come up quickly. I have a _lot_ of different configurations which would take time to go through. I choose which config I want to use manually with a small script (I called 'ether') for wired ethernet or wireless - I know better what location I'm in than the laptop does and there may be several different reachable configurations in a given area (such as at USENIX where there were private base stations with no link to the world that were open and closer to my laptop than the real USENIX provided base stations which had a link to the world - I had to force the ssid to get a legitimate connection). When I go home I unsuspend and type 'ether -link1' and it is cleared back to the default for home. I type 'ether -link1 tab' it configures wireless settings for my building at work, etc, etc. This is what I meant before. > Well, I've used (essentially) the same Perl script (which I stuffed in > /usr/local/sbin) through 3 iterations of invocation: I've been through similar thought processes. With PAO's pccard_ether scripts I actually found a lot of things easier until recently, so I'd been maintaining my own script bases on PAO and with more recent improvements from 4.*'s pccard_ether merged in. I'm tired of doing that. Called from any method of bringing an interface up after boot time (ppp, pccard_ether, etc. the only one I haven't done this for yet is usb ether, since I don't have any) I have another script I've also been using for the last few years to do the scattering of things I do after an interface changes status. > But I was informed that /etc/pccard_ether was viewed as a hack, and > that there was a desire to make it Go Away. Something has to configure the interfaces - something has to be run when an interface appears - I doubt pccard_ether is going anywhere anytime soon. In the meantime my small changes mean that people who wish to hardcode a few simple settings can do so without changing pccard.conf (and restarting pccardd), without changing the existing pccard_ether and without creating lots of /etc/*if* files. It also gives a place to add location dependant configurations where you can easily change chunks of configuration with very simple external scripts. > And (as you noted), there needs to be a separate such file (even it's > only a single line long) for each possible interface instantiation, > which is pretty unaesthetic, to put it kindly. Quite. P. -- pir pir@pir.net pir@net.tufts.edu To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-mobile" in the body of the message