Browse Source

Allow Pods Network to have smaller MTU than Nodes

We should allow Pods Network MTU to be smaller than the
MTU of the Host VM to address scenarios like Nodes Network
being a provider network, while Pods Network is a Tenant
Network. This commit fixes the issue by allowing binding
of VIFs with MTU smaller than the Nodes.

Change-Id: Ibadcd07824702ff1160a4a1d6d10313c15910dea
Maysa Macedo 2 months ago
1 changed files with 4 additions and 4 deletions
  1. +4

+ 4
- 4
kuryr_kubernetes/cni/binding/ View File

@ -109,15 +109,15 @@ class NestedDriver(health.HealthHandler, b_base.BaseBindingDriver,
# driver for getting the link device.
vm_iface_name = self._detect_iface_name(h_ipdb)
mtu = h_ipdb.interfaces[vm_iface_name].mtu
if mtu !=
if mtu <
# NOTE(dulek): This might happen if Neutron and DHCP agent
# have different MTU settings. See
raise exceptions.CNIBindingFailure(
f'MTU of interface {vm_iface_name} ({mtu}) does not '
f'match MTU of pod network {} '
f'MTU of interface {vm_iface_name} ({mtu}) is smaller '
f'than MTU of pod network {} '
f'({}). Please make sure pod network '
f'has the same MTU as node (VM) network.')
f'has the same or smaller MTU as node (VM) network.')
args = self._get_iface_create_args(vif)
with h_ipdb.create(ifname=temp_name,