From owner-freebsd-hackers Thu Jun 1 9:38:27 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from info.iet.unipi.it (info.iet.unipi.it [131.114.9.184]) by hub.freebsd.org (Postfix) with ESMTP id 2B46737B96D; Thu, 1 Jun 2000 09:37:57 -0700 (PDT) (envelope-from luigi@info.iet.unipi.it) Received: (from luigi@localhost) by info.iet.unipi.it (8.9.3/8.9.3) id SAA66853; Thu, 1 Jun 2000 18:37:32 +0200 (CEST) (envelope-from luigi) From: Luigi Rizzo Message-Id: <200006011637.SAA66853@info.iet.unipi.it> Subject: Re: changed pci bus probe order from 3.2 to 4.0 -- ideas? In-Reply-To: from Fred Clift at "Jun 1, 2000 09:54:23 am" To: Fred Clift Date: Thu, 1 Jun 2000 18:37:32 +0200 (CEST) Cc: freebsd-hackers@FreeBSD.ORG, freebsd-stable@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL61 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG ... > The problem is that the cards get swapped. ... > It's a long story as to why switching cables, or changing which card gets > which IP address isn't really a good solution. The short answer is that i suppose the only place where you use the actual card names is the firewall config and rc.conf -- can't you just make these scripts fetch the ethernet address of the card(s), set a shell variable with the name of the good card, and go ahead with that ? I did something similar in picobsd to make the same floppy recognise the hardware on different systems. Something like (in /etc/rc): n_ether="" for main_if in `ifconfig -l` ; do set `ifconfig $main_if` while [ "$1" != "" ] ; do if [ $1 = "ether" ] ; then main_ether=$2 break 2 else shift fi done done At which point $main_ether contains the ethernet address of your first ethernet interface and you can base decisions on that... cheers luigi -----------------------------------+------------------------------------- Luigi RIZZO, luigi@iet.unipi.it . Dip. di Ing. dell'Informazione http://www.iet.unipi.it/~luigi/ . Universita` di Pisa TEL/FAX: +39-050-568.533/522 . via Diotisalvi 2, 56126 PISA (Italy) Mobile +39-347-0373137 -----------------------------------+------------------------------------- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message