HowTo Configure LAG in the VM over SR-IOV

Version 3

    This post discuss and shows how to configure LAG (bond) within the VM while the VM interfaces are configured with SR-IOV.




    It is possible to configure bond over two interfaces in the VM in case the VM have two interfaces configured with SR-IOV.

    It is not possible to do it within the hypervisor in such case.




    Host Configuration

    1. Install latest MLNX_OFED on the server while enabling SR-IOV, refer to Mellanox OFED UM or to Mellanox OFED Driver Installation and Configuration for SR-IOV post.

    2. Configure one VF on each port connected to the VM, refer to HowTo Configure SR-IOV VFs on Different ConnectX-3 Ports

    3. Configure bond interface on the server and connect both eth1 and eth2 to this bond, refer to Linux Network bonding – setup guide - Cloudibee's Notes (Make sure you use bond mode 0 or 2).

    4. Configure IP address on the bond interface.



    1. LACP will not work in such case, as more than 1 VM can be configured with bond.

    2. You cannot configure on VM with bond and another VM with regular one port connectivity - It will not work (basic networking)

    Switch Configuration

    1. Configure port-channel on the switch

    2. Configure VLAN interface on the port channel with the IP in the same network as the bond IP.



    1. Check that ping works between the server and the switch.

    2. Shutdown one of the ports and re-check that ping works.