Bridging a Bonded Network Centos 7
This is exclusively for a KVM Hypervisor running Centos 7 with at least 2 Network cards (NIC’s) but may work on other Linux Flavors.
- Disable and stop network manager: systemctl disable NetworkManager && systemctl stop NetworkManager
- Navigate to the network scripts folder on your server or workstation:
- Use the following command to ensure bonding modules are installed and supported: modprobe bonding. You won’t get output if it is installed and supported.
- Then run; modinfo bonding. You will get output like this, the output is truncated.
- Configure your nics:
- Create your Bond: vi ifcfg-bond0
Insert the following:
IPADDR=192.168.1.200 — ensure this matches your subnet
- Restart your network: systemctl restart network –ensure you can connect and ssh into the server and then test the bond: ifdown eno1 to ensure you can still connect, etc. Try it on the NIC’s one at time. Ifdown/ifup <name of NIC>
- Now we can Bridge the bonded pair.
- vi ifcfg-virbr0
- Insert the following:
IPADDR=”192.168.1.200″ — This is the same IP, subnet and gateway from the bond. Now the bridge will have the IP info.
- Next edit the bond you just created and tested by removing the IP address, subnet and gateway you just added to your bridge. At the bottom of the bond0 add BRIDGE=virbr0, the name of the bridge you just created.
- Once you have saved the Bridge, restart your network and test. If all went well, you have a bonded, bridged pair for your KVM Hypervisor.