Translation(s): none

(!) ?Discussion


This article will show how to "bond" two Ethernet connections together to create an auto failover interface.

Bonding

Install packages

First install the 2 packages needed to enable bonding.

#apt-get install ifenslave-2.6 ifenslave

Config file for Lenny

When you use Lenny, you have to modify /etc/network/interfaces only.

auto bond0

iface bond0 inet static
    address 10.31.1.5
    netmask 255.255.255.0
    network 10.31.1.0
    gateway 10.31.1.254
    slaves eth0 eth1
    bond_mode active-backup
    bond_miimon 100
    bond_downdelay 200
    bond_updelay 200

For more detail, see /usr/share/doc/ifenslave-2.6/README.Debian.

Config files for Etch (and older versions)

There are a few config files that need to be edited. Change your /etc/network/interfaces to look like this. You will need to remove the listings associated with the bonded interfaces such as eth0 and eth1. Change the interfaces (ie: eth0; eth1) to match your needs as well as the IP address information

auto bond0

iface bond0 inet static
    address 10.31.1.5
    netmask 255.255.255.0
    network 10.31.1.0
    gateway 10.31.1.254
    up /sbin/ifenslave bond0 eth0 eth1
    down /sbin/ifenslave -d bond0 eth0 eth1

Add the following lines to /etc/modprobe.d/arch/i386

alias bond0 bonding
options bonding mode=1 miimon=100 downdelay=200 updelay=200

Last add this line to /etc/modules

bonding

and run

#update-modules

After this you will need to restart the network service or reboot the system.



CategoryNetwork