WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

RE: [Xen-users] odd behavior with network-bridge and ip aliases ondomU:s

To: "Markus Ingalsuo" <markus.ingalsuo@xxxxxx>, <xen-users@xxxxxxxxxxxxxxxxxxx>
Subject: RE: [Xen-users] odd behavior with network-bridge and ip aliases ondomU:s
From: "James Harper" <james.harper@xxxxxxxxxxxxxxxx>
Date: Thu, 12 Jun 2008 16:00:31 +1000
Delivery-date: Wed, 11 Jun 2008 23:01:11 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <4850B2E2.7030408@xxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <4850B2E2.7030408@xxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcjMTL2BlQo4124xTamfiO+shA5RtwAA/6rg
Thread-topic: [Xen-users] odd behavior with network-bridge and ip aliases ondomU:s
> I'm experiencing odd behavior of Linux domU:s that are running on
> bridged ethernet and using ip aliases. I've been able to rule out
> everything, including multiple bridges on domU:s to just adding ip
> aliases.
> 
> When I do "ifconfig eth0:1 xx.xxx.xxx.xxx" on the domU, it stops
> respondig over ethernet, on the original address also which is
specified
> in the .cfg. Is there a way to specify both/all addresses in the .cfg?
> Or is there a "best practice" that I should follow? :)

I don't think interface aliases are really supported anymore.

You can add a new ip address to an interface by just doing:

ip addr add xxx.xxx.xxx.xxx/yyy dev iface

eg

ip addr add 11.22.33.44/24 dev eth0

and often you don't actually need the secondary addresses on the
interface so you can just add them to lo instead.

Under Debian you can add the command to /etc/network/interfaces, eg:

"
auto xen-br0
iface xen-br0 inet static
bridge_ports eth0
 bridge_maxwait 0
 # primary address
 address 11.22.33.40
 netmask 255.255.255.0
 gateway 192.168.200.254
 # secondary address
 up /sbin/ip addr add 11.22.33.44/24 dev $IFACE || true
"

if you add them to lo instead, then you'll need a 'down' too, eg

"
auto lo
iface lo inet loopback
 up /sbin/ip addr add 11.22.33.44/24 dev $IFACE || true
 down /sbin/ip addr del 11.22.33.44/24 dev $IFACE || true
"

I normally put the '|| true' at the end so that a failure to add or
remove an address doesn't prevent the interface coming up or going down.

The reason I add addresses to lo instead of the interface is that the
routing daemons I use announce using all IP addresses on an interface
which looks messy.

James


_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

<Prev in Thread] Current Thread [Next in Thread>