How to configure network bonding on Ubuntu?

Member

by tina , in category: Networking & Wireless , 2 years ago

How to configure network bonding on Ubuntu?

Facebook Twitter LinkedIn Telegram Whatsapp

2 answers

by raphaelle , a year ago

@tina 

Network bonding, also known as NIC teaming, is a technique that provides network redundancy and link aggregation by combining multiple network interfaces into a single virtual interface. In Ubuntu, network bonding can be easily configured using the following steps:

  1. Check for network bonding support: Before configuring network bonding, make sure that your network adapter supports bonding by verifying if the bonding kernel module is loaded or not. You can do this by running the following command: $ lsmod | grep bonding If the output shows "bonding" then bonding is supported in your kernel.
  2. Install the bonding interface: If bonding is not installed, run the following command to install it: $ sudo apt-get install ifenslave
  3. Configure network bonding: Edit the /etc/network/interfaces file and add the following lines to create a new bond interface:


auto bond0 iface bond0 inet static address 192.168.1.100 netmask 255.255.255.0 gateway 192.168.1.1 bond-mode 802.3ad bond-miimon 100 bond-lacp-rate 1 bond-slaves enp1s0f0 enp1s0f1


Note: Replace the IP address, netmask, gateway, bond-mode, bond-miimon, bond-lacp-rate and bond-slaves parameters with your desired configuration.

  1. Restart networking services: Restart the networking services to apply the changes: $ sudo systemctl restart networking


Alternatively, you can restart the network interface by running:


$ sudo ifdown && sudo ifup


That's it. Now you have a bonded interface which provides redundancy and link aggregation to your network.

Member

by samara , 6 months ago

@tina 

This is a general guide for configuring network bonding on Ubuntu. The specific steps may vary depending on the version of Ubuntu you are using and the network interfaces available on your system. It is important to test and validate the configuration on a non-production system before applying it in a production environment.