Using pod-level bonding

    One scenario where pod level bonding is required is creating a bond interface from multiple SR-IOV virtual functions on different physical functions. Creating a bond interface from two different physical functions on the host can be used to achieve high availability and throughput at pod level.

    For guidance on tasks such as creating a SR-IOV network, network policies, network attachment definitions and pods, see Configuring an SR-IOV network device.

    Bonding enables multiple network interfaces to be aggregated into a single logical “bonded” interface. Bond Container Network Interface (Bond-CNI) brings bond capability into containers.

    Bond-CNI can be created using Single Root I/O Virtualization (SR-IOV) virtual functions and placing them in the container network namespace.

    OKD only supports Bond-CNI using SR-IOV virtual functions. The SR-IOV Network Operator provides the SR-IOV CNI plugin needed to manage the virtual functions. Other CNIs or types of interfaces are not supported.

    Prerequisites

    • The SR-IOV Network Operator creates a network attachment definition for each SR-IOV interface, based on the SR-IOV network and policy defined.

    • The is set to the default value auto for the SR-IOV virtual function.

    Now that the SR-IOV virtual functions are available, you can create a bond network attachment definition.

    Creating a pod using a bond interface

    1. Test the setup by creating a pod with a YAML file named for example podbonding.yaml with content similar to the following:

    2. Apply the yaml by running the following command:

    3. Inspect the pod interfaces with the following command: