From owner-freebsd-current@FreeBSD.ORG Sun Sep 25 22:55:17 2005 Return-Path: X-Original-To: freebsd-current@freebsd.org Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8208E16A41F; Sun, 25 Sep 2005 22:55:17 +0000 (GMT) (envelope-from ticso@cicely12.cicely.de) Received: from srv1.cosmo-project.de (srv1.cosmo-project.de [213.83.6.106]) by mx1.FreeBSD.org (Postfix) with ESMTP id B5BB643D53; Sun, 25 Sep 2005 22:55:16 +0000 (GMT) (envelope-from ticso@cicely12.cicely.de) Received: from cicely5.cicely.de (cicely5.cicely.de [10.1.1.7]) (authenticated bits=0) by srv1.cosmo-project.de (8.12.10/8.12.10) with ESMTP id j8PMt2BS011949 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=OK); Mon, 26 Sep 2005 00:55:05 +0200 (CEST) (envelope-from ticso@cicely12.cicely.de) Received: from cicely12.cicely.de (cicely12.cicely.de [10.1.1.14]) by cicely5.cicely.de (8.12.10/8.12.10) with ESMTP id j8PMsceG046408 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Mon, 26 Sep 2005 00:54:38 +0200 (CEST) (envelope-from ticso@cicely12.cicely.de) Received: from cicely12.cicely.de (localhost [127.0.0.1]) by cicely12.cicely.de (8.13.4/8.13.3) with ESMTP id j8PMsbLt051387; Mon, 26 Sep 2005 00:54:37 +0200 (CEST) (envelope-from ticso@cicely12.cicely.de) Received: (from ticso@localhost) by cicely12.cicely.de (8.13.4/8.13.3/Submit) id j8PMsXKx051386; Mon, 26 Sep 2005 00:54:33 +0200 (CEST) (envelope-from ticso) Date: Mon, 26 Sep 2005 00:54:33 +0200 From: Bernd Walter To: Gavin Atkinson Message-ID: <20050925225432.GH552@cicely12.cicely.de> References: <20050922104104.GA13539@comp.chem.msu.su> <20050925213741.GG15981@odin.ac.hmc.edu> <1127686105.23447.35.camel@buffy.york.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1127686105.23447.35.camel@buffy.york.ac.uk> X-Operating-System: FreeBSD cicely12.cicely.de 5.4-STABLE alpha User-Agent: Mutt/1.5.9i X-Spam-Status: No, score=-5.9 required=3.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham version=3.0.4 X-Spam-Report: * -3.3 ALL_TRUSTED Did not pass through any untrusted hosts * -2.6 BAYES_00 BODY: Bayesian spam probability is 0 to 1% * [score: 0.0000] X-Spam-Checker-Version: SpamAssassin 3.0.4 (2005-06-05) on cicely12.cicely.de Cc: Yar Tikhiy , freebsd-current@freebsd.org, freebsd-net@freebsd.org Subject: Re: "ifconfig -vlandev" syntax X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: ticso@cicely.de List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 25 Sep 2005 22:55:17 -0000 On Sun, Sep 25, 2005 at 11:08:25PM +0100, Gavin Atkinson wrote: > On Sun, 2005-09-25 at 14:37 -0700, Brooks Davis wrote: > > On Thu, Sep 22, 2005 at 02:41:05PM +0400, Yar Tikhiy wrote: > > > Hi folks, > > > > > > As our ifconfig(8) is growing more options for special interface > > > types, inconsistencies sneak into their syntax. In particular, > > > -vlandev takes a useless argument (vlan(4) cannot attach to more > > > than one parent anyway) while, e.g., -carpdev doesn't need one. > > > Personally, I like the latter since having to type unneeded words > > > on the command line annoys me. Do you think that making -vlandev > > > need no arguments in CURRENT would break many existing things? > > > > I agree the argument is useless. Unfortunatly, it's going to be hard to > > deprecate the old syntax so we may need to keep it around. > > There's also the issue that the "vlan" and "vlandev" options have to be > specified in that order, which is counter-intuitive and undocumented. > > leeloo# ifconfig vlan14 vlandev fxp0 vlan 14 > ifconfig: must specify both vlan tag and device > leeloo# ifconfig vlan14 vlan 14 vlandev fxp0 > leeloo# > > Also, you can't set both the vlan and IP address information: > leeloo# ifconfig vlan14 vlan 14 vlandev fxp0 inet W.X.Y.Z netmask 255.255.255.0 > ifconfig: inet: bad value > > As a result of this, the only way to create vlans from rc.conf seems to > be in two stages, by renaming the interface: > > cloned_interfaces="vlan14" > ifconfig_vlan14="vlan 14 vlandev fxp0 name somename" > ifconfig_somename="inet W.X.Y.Z netmask 255.255.255.0" The follwing always worked for me, no need to rename: cloned_interfaces="vlan1" ifconfig_vlan1="inet 1.2.3.4/29 vlan 1 vlandev fxp0" What doesn't work is this: ifconfig_vlan1_alias0="1.2.3.4/32" I had to configure them by a selfdone script. -- B.Walter BWCT http://www.bwct.de bernd@bwct.de info@bwct.de