Comment 1 for bug 2031421

Revision history for this message
Danilo Egea Gondolfo (danilogondolfo) wrote :

The new Network Manager is not installing the route for the vrf0 interface.

This change in behavior might be related to this commit https://gitlab.freedesktop.org/NetworkManager/NetworkManager/-/commit/dabfa26a41edc7911a45a4689d555e8f055b0373

The interface is not being assigned any IP addresses. And we actually can't add IPs to VRFs in Netplan but we probably should...

Test case:

---
network:
  dummy-devices:
    dummy0:
      renderer: NetworkManager
      addresses: [10.10.10.22/24]
      routes:
      - to: 11.11.11.0/24
        via: 10.10.10.2
        table: 1000
  vrfs:
    vrf0:
      renderer: NetworkManager
      table: 1000
      interfaces: [dummy0]
      routes:
      - to: 10.10.0.0/16
        via: 10.10.10.1
      routing-policy:
      - from: 10.10.10.42
---

The interface is created

# nmcli con show
NAME UUID TYPE DEVICE
netplan-vrf0 be402d13-a9f8-395d-8382-81a1ef0bdd1d vrf vrf0
netplan-enp5s0 e1419a5e-5e1d-3fff-a17c-b2fc6d2cef99 ethernet enp5s0
lo 6c74c0d6-04c6-4ea2-b5e3-b53b579e3adf loopback lo
netplan-dummy0 9c4bae2d-b07e-3aea-965f-76d9e84fa47e dummy dummy0

But will stuck in "activating"

# nmcli -f GENERAL.STATE con show netplan-vrf0
GENERAL.STATE: activating

And the route "10.10.0.0/16 via 10.10.10.1" will not be installed

# ip r show table 1000
10.10.10.0/24 dev dummy0 proto kernel scope link src 10.10.10.22 metric 550
local 10.10.10.22 dev dummy0 proto kernel scope host src 10.10.10.22
broadcast 10.10.10.255 dev dummy0 proto kernel scope link src 10.10.10.22
11.11.11.0/24 via 10.10.10.2 dev dummy0 proto static metric 550

In Lunar, with Network Manager 1.42, the vrf interface will also stuck in activating, but the route will be installed.

Assigning an IP to the vrf interface will make the test pass but Netplan doesn't support it. Adding the IP via networkmanager.passthrough fixes the test for Network Manager but will break networkd.

With networkd, the route is installed even if the interface has no IP addresses.

We could just stop checking for that route to make the test pass but we probably want to rethink our support for VRFs in Netplan.

Lukas, what do you think?