vlan usage requires an intermediate step

Bug #1738058 reported by Mathieu Trudel-Lapierre on 2017-12-13
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
nplan (Ubuntu)
Undecided
Unassigned
systemd (Ubuntu)
Undecided
Dimitri John Ledkov

Bug Description

If I try to apply vlans directly:

network:
  version: 2
  renderer: networkd
  ethernets:
    eth0: {}
  vlans:
    vlan1:
      id: 1
      link: eth0
      addresses: [ 192.168.0.10/23 ]
    vlan10:
      id: 10
      link: eth0
      addresses: [ 10.0.0.5/24 ]

The vlan devices never come up, they are left in degraded state by networkd. If I define an address for eth0, then eth0 and all of the vlans will have the same address. Needless to say, this doesn't work.

If I use an intermediary device instead, such as a bond:

network:
  version: 2
  renderer: networkd
  ethernets:
    eth0: {}
  bonds:
    vmaster:
      interfaces: [ eth0 ]
  vlans:
    vlan1:
      id: 1
      link: vmaster
      addresses: [ 192.168.0.10/23 ]
    vlan10:
      id: 10
      link: vmaster
      addresses: [ 10.0.0.5/24 ]

Then the vlans are correctly applied and brought up by systemd.

I think this is either a systemd bug or a netplan bug; it's possible we don't generate the config quite in the way that systemd expects it (even though it looks straightforward enough).

Dimitri John Ledkov (xnox) wrote :

That sounds like a bug.

I have only previously used vlans on top of bonds.

Changed in systemd (Ubuntu):
assignee: nobody → Dimitri John Ledkov (xnox)
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in nplan (Ubuntu):
status: New → Confirmed
Changed in systemd (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers