Setting network card bonding in Ubuntu

  1. Install ifenslave package.
    # sudo apt-get install ifenslave
  2. Load bonding module.
    # sudo modprobe bonding
  3. Select bonding mode. Reference here. (ps. I had tried to configure according to official document. But always fails.)
  4. Edit /etc/network/interface. Here is an example.
    auto bond0
    iface bond0 inet static
            address 192.168.1.1
            netmask 255.255.255.0
            network 192.168.1.0
            gateway 192.168.1.254
            # This option must always be 'none'; use "bond-master" on each interface.
            bond-slaves none
            bond-mode 802.3ad
            bond-miimon 100
            bond-downdelay 200
            bond-updelay 100

    auto eth0
    allow-bond0 eth0
    iface eth0 inet manual
            bond-master bond0

    auto eth1
    allow-bond0 eth1
    iface eth1 inet manual
            bond-master bond0
  5. 802.3ad mode(mode=4) need switch support. In cisco switch , it need to create port-channel in LACP mode.

留言

熱門文章