Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 29 Aug 2011 16:41:37 +0000
From:      "Li, Qing" <qing.li@bluecoat.com>
To:        John <jwd@freebsd.org>, FreeBSD Net <freebsd-net@freebsd.org>
Subject:   RE: ifconfig -alias with duplicate netmasks work?
Message-ID:  <B143A8975061C446AD5E29742C5317230FE80B@PWSVL-EXCMBX-01.internal.cacheflow.com>
In-Reply-To: <20110822234921.GA34843@FreeBSD.org>
References:  <20110822234921.GA34843@FreeBSD.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi,

Yes, the address alias and its associated prefix installation code changed.=
=20
Operationally it makes sense because all addresses of that same prefix go
through one route utilizing that given interface.

The side effect is you can have two separate interfaces on the same prefix,
but only a single route is installed, which is associated with the address
installed first.

The other interfaces won't be utilized for outgoing traffic unless you enab=
le
RADIX_MPATH option in the kernel configuration.

I think the manpage needing updates, and I am partly guilty for not having =
time
to update the content, which does take considerable amount of time for actu=
al=20
behavior verification on different released versions.

I am now resuming work on FBSD after a long hiatus, updating the route manp=
age=20
is on my to-do list.

--Qing


> -----Original Message-----
> From: owner-freebsd-net@freebsd.org [mailto:owner-freebsd-
> net@freebsd.org] On Behalf Of John
> Sent: Monday, August 22, 2011 4:49 PM
> To: FreeBSD Net
> Subject: ifconfig -alias with duplicate netmasks work?
>=20
> Fellow Net'ers
>=20
>    Debugging an nfs locking problem to a linux host, I accidently
> issued some ifconfig commands on the bsd server (9-current) and
> found that duplicate netmasks seem to work fine. For instance:
>=20
> bce0: flags=3D8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu
> 1500
> 	options=3Dc01bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLA
> N_HWCSUM,TSO4,VLAN_HWTSO,LINKSTATE>
> 	ether d4:85:64:66:2a:14
> 	inet6 fe80::d685:64ff:fe66:2a14%bce0 prefixlen 64 scopeid 0x1
> 	inet 10.24.99.127 netmask 0xffff0000 broadcast 10.24.255.255
> 	inet 10.24.99.128 netmask 0xffff0000 broadcast 10.24.255.255
> 	inet 10.24.99.126 netmask 0xffff0000 broadcast 10.24.255.255
> 	nd6 options=3D29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
> 	media: Ethernet autoselect (1000baseT <full-duplex>)
> 	status: active
>=20
> via the commands:
>=20
> ifconfig bce0 inet 10.24.99.127 netmask 0xffff0000 broadcast
> 10.24.255.255
> ifconfig bce0 inet 10.24.99.128 netmask 0xffff0000 broadcast
> 10.24.255.255 alias
> ifconfig bce0 inet 10.24.99.126 netmask 0xffff0000 broadcast
> 10.24.255.255 alias
>=20
> The man page for ifconfig says one 'must' use a different netmask,
> typically 0xffffffff. However, everything still seems to work ok.
>=20
> Has something changed, is the manpage wrong, am I totally missing
> something?
>=20
> Thanks,
> John
>=20
> man ifconfig
>=20
> If the address
> is on the same subnet as the first network address for this
> interface, a non-conflicting netmask must be given.  Usually
> 0xffffffff is most appropriate.
> _______________________________________________
> freebsd-net@freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?B143A8975061C446AD5E29742C5317230FE80B>