liveBook · Manning

SR-IOV

As explained in Google Anthos in Action

SR-IOV is a PCI Express virtualization technology that lets a physical device expose multiple virtual interfaces for direct assignment to workloads.

SR-IOV is a PCI Express virtualization technology that exposes multiple virtual interfaces from one physical device for direct assignment to workloads. In Anthos clusters on bare metal, it appears as one option for additional Pod interfaces provided through Multus CNI, alongside IPvlan, MacVLAN, and Bridge. section 8.3.2

Deploy the capability through three configuration steps:

  • Enable multi-NIC support by setting multipleNetworkInterfaces to true in the clusterNetwork section of the Anthos bare metal cluster resource. section 8.3.2
  • Define available additional networks with NetworkAttachmentDefinition custom resources, selecting the appropriate CNI implementation such as SR-IOV. section 8.3.2
  • Attach networks to Pods or Deployments with the k8s.v1.cni.cncf.io/networks annotation; the default interface is eth0 and additional interfaces are net1, net2, and so on. section 8.3.2

Restricting network use to a node pool

Add the k8s.v1.cni.cncf.io/nodeSelector annotation to a NetworkAttachmentDefinition to make it valid only for a designated node pool. Anthos bare metal then schedules Pods referencing that network onto the appropriate pool. section 8.3.2

...
clusterNetwork:
 multipleNetworkInterfaces: true
 pods:
  cidrBlocks:
  - 192.168.0.0/16
 services:
  cidrBlocks:
  - 10.96.0.0/12
...

Use the cluster-network listing to inspect the multi-NIC enablement field and its surrounding network configuration. section 8.3.2

How Google Anthos in Action covers it

How deep it goes
Explains the Multus-based deployment sequence but stops short of detailing SR-IOV device configuration or virtual-function internals.
Examples
Uses cluster YAML, NetworkAttachmentDefinition resources, Pod annotations, and node-pool selectors to configure multiple interfaces.
What it assumes
Assumes familiarity with Anthos bare metal clusters, Kubernetes manifests, Pods, Deployments, and CNI networking.
What you can do after
Apply via Multus CNI by enabling multi-NIC, defining additional networks, assigning them to Pods, and restricting them to node pools.
How it connects
Connects SR-IOV with PCI Express, Multus CNI, Kubernetes Pods, NetworkAttachmentDefinition, and node pools.

Related concepts

This explainer was generated by Manning's knowledge graph from the text of Google Anthos in Action. The section links point to the parts of the book it draws on.