Renaming Network Interface (18.04 / Netplan)

How can I tell MaaS to create a bond0.20 (VLAN on top of BOND) interface, named br-storage, instead of bond0.20?

Thing is, today, the “workaround” is to create a bridge on top of bond0.20, called br-storage, however, I don’t actually need the bridge!

I think this is somewhat of a limitation left over from the the 8021q driver and its vconfig utility. If you run vconfig you’ll see the possible name-types:

* name-type:  VLAN_PLUS_VID (vlan0005), VLAN_PLUS_VID_NO_PAD (vlan5),
              DEV_PLUS_VID (eth0.0005), DEV_PLUS_VID_NO_PAD (eth0.5)

That is, there is no option to use a naming scheme different than the above. To make matters worse, on a MAAS controller we need to use the naming scheme to infer which VLAN ID (VID) the interface is communicating on. Even if renaming bond0.20 to something else worked, we would then need to read /proc/net/vlan/config to determine which VID the bond is on. (But we can’t do that easily, because it’s only readable by root.)

That said, assuming renaming VLAN interfaces is supported by Netplan, we could potentially support this in MAAS in the future.