Bonding multiple NICs in Linux is often useful for performance and redundancy.
There are a few userland applications we'll need for this exercise. Install them in the typical Debian fashion (as root):
aptitude install ifenslave ifenslave-2.6 ethtool
In order for bonding to work, you'll also need a couple of modules. You can load them like so:
modprobe bonding mii
…and set them to load automatically in the future as follows:
echo "modprobe" >> /etc/modules echo "mii" >> /etc/modules
All that's left to do is create one or more bonded interfaces for your system to use. First, take down any interfaces which are to be bonded. For instance:
ifdown eth0 eth1
In /etc/network/interfaces, you would comment out or remove any existing entries for the interfaces you plan to bond, then create an entry for each virtual 'bond' device. For example:
auto bond0
allow-hotplug bond0
iface bond0 inet static
address 10.0.0.250
netmask 255.255.0.0
network 10.0.0.0
broadcast 10.0.255.255
gateway 10.0.0.1
bond_mode balance-tlb
bond_miimon 100
bond_downdelay 200
bond_updelay 200
slaves eth0 eth1
Of course, one would replace all of the IP and routing information detailed above with the correct ones for your own environment. As you can also see there are many options to be tweaked, including different load-balancing methods, though the bonding settings outlined above should be acceptable for most environments. When you are happy with your settings, you can bring up your new bonded interface(s):
ifup bond0
For detailed info on the myriad of options for the bonding driver, see here.