From owner-freebsd-net@FreeBSD.ORG Tue May 6 09:21:59 2003 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id BC1F437B401 for ; Tue, 6 May 2003 09:21:59 -0700 (PDT) Received: from mail1.psconsult.nl (mail1.psconsult.nl [213.222.19.243]) by mx1.FreeBSD.org (Postfix) with ESMTP id 2709543FA3 for ; Tue, 6 May 2003 09:21:58 -0700 (PDT) (envelope-from paul@pop3.psconsult.nl) Received: from pop3.psconsult.nl (ps227.psconsult.nl [213.222.19.227]) by mail1.psconsult.nl (8.12.6p2/8.12.6) with ESMTP id h46GLnwU055156; Tue, 6 May 2003 18:21:50 +0200 (CEST) (envelope-from paul@pop3.psconsult.nl) Received: (from paul@localhost) by pop3.psconsult.nl (8.9.2/8.9.2) id SAA58089; Tue, 6 May 2003 18:21:49 +0200 (CEST) (envelope-from paul) Date: Tue, 6 May 2003 18:21:49 +0200 From: Paul Schenkeveld To: Wes Peters Message-ID: <20030506182149.A57876@psconsult.nl> References: <_MzYgD.A.O9P._h8s-@coal.sentex.ca> <200305042117.39042.wes@softweyr.com> <20030505114756.K53365@beagle.fokus.fraunhofer.de> <200305060841.40502.wes@softweyr.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0i In-Reply-To: <200305060841.40502.wes@softweyr.com>; from wes@softweyr.com on Tue, May 06, 2003 at 08:41:40AM -0700 cc: freebsd-net@freebsd.org cc: Jeremy Chadwick Subject: Re: Howto rename an interface X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 May 2003 16:22:00 -0000 Hi All, On Tue, May 06, 2003 at 08:41:40AM -0700, Wes Peters wrote: > On Monday 05 May 2003 02:49, Harti Brandt wrote: > > On Sun, 4 May 2003, Wes Peters wrote: > > > > >On Sunday 04 May 2003 11:18, Jeremy Chadwick wrote: > > > > > All of the system startups need to refer to these ports by function, > > > not by some silly number assigned as a side effect of the PCI bus > > > probing order. > > > > > > This almost begs for some simple alias that can be programmatically > > > (or via a command line utility) added to the interface so the > > > association with the device type isn't lost. That bears some > > > thought. An interface label, as it were... > > > > Perhaps an if_alias field in struct ifnet, setable via ifconfig? This > > would just nicely map to the alias name field in the SNMP interface > > MIB. > > That's what I was thinking, but that's just the beginning of the project. > The next step is to make references to the alias, i.e. from ifconfig, > ipfw, ipfilter, etc. recognize the alias or label as well as the device > name. I'll ask the boss if I can do this on St. Bernard's ticket. ;^) Ok, ifconfig, ipfw, ipfilter and many others can be changed to understand both the original interface name and the alias when specified on the commandline. But what would ifconfig -l, ifconfig -a, netstat -i and others output and what would ipmon log about blocked packets? The original name, the alias or both? I am not really against interface aliases and I can see the benefits for simplified configuration of similar machines (I'm facing the same issues with many multi-homes machines I manage that are conceptually the same but have slightly different mixes of interfaces that you described a few messages ago). But being able to have aliases so configuration scripts can use the logical name does not solve all problems. Perhaps commands reporting interface names should have a flag to choose for physical names or logical names (eg. 'ifconfig -l -P' or 'ifconfig -l -L') and messages that get logged somewhere could output both the physical and logical names like this: May 6 18:16:50 firewall ipmon[54]: 18:16:49.563047 dc7/ext0 @0:17 b xx.xx.xx.xx,1030 -> xx.xx.xx.xx,1434 PR udp len 20 404 IN I separated the physical name and logical names by a slash and not a space so that it still counts as a single word for compatibility. > -- > > Where am I, and what am I doing in this handbasket? > > Wes Peters wes@softweyr.com My $0.02. Paul Schenkeveld, Consultant PSconsult ICT Services BV