Bonding on CentOS 7 and Switch Arista and Mikrotik

Check bonding

lsmod | grep 8021q

Disable?
Please ENABLE

echo 8021q >> /etc/modules-load.d/8021q.conf

enable

modprobe --first-time 8021q

Check

lsmod | grep 8021q
8021q                  32768  0 
garp                   16384  1 8021q
mrp                    20480  1 8021q

What is bonding?Bonding in Linux refers to the process of combining multiple network interfaces into a single logical interface for redundancy or increased bandwidth. This can be useful when you want to ensure that your server remains connected even if one physical link fails.

Steps to configure bonding on CentOS 7:

  1. Install necessary packages:sudo yum install -y net-tools
  2. Create bond configuration file:Create a new file /etc/sysconfig/network-scripts/ifcfg-bond0 with the following content:DEVICE=bond0NAME=»bond0″TYPE=BondBONDING_MASTER=yesIPADDR=<IP_ADDRESS>NETMASK=<NETMASK>ONBOOT=yesBOOTPROTO=noneZONE=publicUSERCTL=noDNS1=<DNS_SERVER_1>DNS2=<DNS_SERVER_2>
  3. Configure slave interfaces:Edit the existing interface files (/etc/sysconfig/network-scripts/ifcfg-ethX) and add the following lines:SLAVE=yesMASTER=bond0ONBOOT=yesBOOTPROTO=none
  4. Restart networking service:sudo systemctl restart network
  5. Verify bonding setup:Check the status using cat /proc/net/bonding/bond0.

Configuring Arista Switches

Arista switches support various types of LACP configurations which are used for bonding links between devices. Here’s how to set up LACP on an Arista switch:

  1. Enable LACP globally:configure terminallacp system-priority <PRIORITY_VALUE>exit
  2. Create an EtherChannel bundle:interface Port-Channel<X>description <DESCRIPTION>no shutdownswitchport mode trunk
  3. Add member ports to the bundle:For each port to be added to the bundle:interface Ethernet<X>channel-group <PORT_CHANNEL_ID> mode active
  4. Verify configuration:Use commands like show etherchannel summary, show lacp neighbors, etc., to verify the configuration.

Configuring MikroTik Router

On MikroTik routers, you can use bonding through Bridge Interface Bonding feature.

  1. Create a bridge interface:Go to Interfaces > Bridges, click on + to create a new bridge.
  2. Add slave interfaces:Add all desired interfaces as members of this bridge by clicking on the bridge name and then adding them under the Members tab.
  3. Set the protocol:Set the appropriate protocol such as Static bonding or Dynamic bonding depending on your requirements.
  4. Apply settings:Click Apply after making changes.
  5. Monitor performance:You can monitor the bonding activity via the Tools > Monitor section within the router’s web UI.

By following these steps, you should have successfully configured bonding across different platforms including CentOS 7 servers, Arista switches, and MikroTik routers.

Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *

Этот сайт использует Akismet для борьбы со спамом. Узнайте, как обрабатываются ваши данные комментариев.