Selecting a container network interface
Virtual Private Cloud
Review the following information for selecting a container network interface (CNI).
In Red Hat OpenShift on IBM Cloud version 4.20 and later, Calico is the default CNI, but VPC clusters that use RHCOS worker nodes have the option of selecting Open Virtual Network (OVN) as their cluster CNI.
- Calico Default
- Calico is a single platform for networking, network security, and observability for any Kubernetes distribution in the cloud, on-premises, or at the edge. Whether you're just starting with Kubernetes or operating at scale, Calico's open source, enterprise, and cloud editions provide the networking, security, and observability you need. For more information, see Calico documentation.
- OVN-Kubernetes (OVN) 4.20 and later RHCOS worker nodes only
- OVN-Kubernetes is based on Open Virtual Network (OVN) and provides an overlay-based networking implementation. A cluster that uses the OVN-Kubernetes plugin also runs Open vSwitch (OVS) on each node. OVN configures OVS on each node to implement the declared network configuration. For more information, see the Red Hat documentation
Comparing Calico and OVN
Review the following table to compare the features and functionality of Calico and OVN.
When using OVN, you must ensure that your VPC subnets don't overlap with the additional subnets specified in the following table. If there is a subnet overlap, pod to pod networking will fail.
Layer2 and layer3 user defined networks (UDN) are not supported with workloads that use DHCP, such as Openshift Virtualisation VMs.
| Component | Calico | OVN-Kubernetes |
|---|---|---|
| Encapsulation |
|
|
| Default Cluster Network / Pod MTU | 1480 bytes (20 byte IPinIP header) by default. This can be changed. | 1400 bytes (100 byte Geneve header) by default. This can be changed. Daemonset needs to create NetworkManager file instead of just running ip link set dev ens3 mtu. You must also restart new worker nodes. |
| Pod IPAM | Calico initially allocates each new node a /26 subnet (64 IPs, at least one typically used as tunl0 IP, rest are available for pods). If all pod IPs in a /26 are used, then Calico assigns a second /26 subnet to the node, and more if/when
needed. You can use the calicoctl ipam check to see subnets assigned to each node. |
OVN initially allocates /24 pod subnet (256 IPs) to each new cluster node. There is no option to add any more pod subnets. It also allocates a join subnet IP to each new node, which is used internally by OVN |
| Pod to pod routing |
|
|
| Kubernetes network policies |
|
|
| Host network policies | Calico GlobalNetworkPolicies | None |
| Additional subnets | None |
|
| APIserver watches |
|
|
| CNI | The calico and calico-ipam CNI binaries are copied to each node by the install-cni initContainer on the calico-node pod. |
The ovnkube-node pod’s ovnkube-controller container executes the CNI binary for add and delete calls. |
| Resources created |
|
|
| Connections between pods |
|
|