Weblog entry #14 for lters

Xen networking with Bonding
Posted by lters on Wed 16 Apr 2008 at 13:12
In an interest of redunancy, I like setting up 2 network cables and than using bonding to bond them together.

I add something like this to /etc/network/interfaces

auto bond0
iface bond0 inet static
        address 10.1.1.2
        netmask 255.255.255.0
        network 10.1.1.0
        gateway 10.1.1.1
        up /sbin/ifenslave bond0 eth0
        up /sbin/ifenslave bond0 eth1
        pre-up modprobe -v bonding -o bond0 mode=4 miimon=50
        post-down rmmod bond0


After creating the first DomU, I could not get it to use my bond0. It wanted to use eth0. I tried adding
('network-bridge netdev=bond0')
to /etc/xen/xend-config.sxp but it would not work.

After doing some research I found this article: http://www.performancemagic.com/Dell1950_MD3000i_Xen_Debian_iSCSI_RDAC/Networking.html which proved to be very helpful.

I added the network-bond to the scripts in /etc/xen/scripts, set it to executable with chmod. I commented out the network-bridge and used this instead.
 (network-script network-bond) 


After a reboot it quit working. After reviewing the above link again, I saw I was missing the netboot in /etc/modules. Adding this and another reboot makes it all work great.

I sent an email with this info to the debian xen package team, but did not hear back from them.

It would be nice to have this script included and a comment added to /etc/xen/xend-config.sxp.

Perhaps this is all fixed in Lenny.
Or maybe there is a better way to do this.

Hopefully this can save someone else similar problems.

 

User Login

Username:

Password:

[ Advanced Login ]

Register Account

Quick Site Search