[Bug 1918421] Re: netplan does not match multiple driver specifications

Launchpad Bug Tracker 1918421 at bugs.launchpad.net
Fri Feb 18 15:10:54 UTC 2022


This bug was fixed in the package netplan.io - 0.104-0ubuntu1

---------------
netplan.io (0.104-0ubuntu1) jammy; urgency=medium

  * New upstream release: 0.104
    - Enable 'embedded-switch-mode' setting on SmartNICs
    - Permit multiple patterns for the driver globs in match (LP: #1918421)
    - Improve routing capabilities (LP: #1892272, LP: #1805038)
    - Support additional link offload options for networkd (LP: #1771740)
    - Handle differing 'ip6-privacy' default value for NetworkManager
    - YAML state tracking for DBus API and 'netplan try' (LP: #1943120)
    - Support ConfigureWithoutCarrier ('ignore-carrier') for networkd
    - Cleanup Makefile, install only public headers
    - Netplan 'get' to use the libnetplan parser
    - libnetplan:
      + introduce the notion of NetplanState
      + use an explicit parser context
      + expose coherent generator APIs
      + improve overall error handling
      + consolidation of YAML parsing into the library
    ATTENTION:
    - Restrict the symbol export to a determined public API
      + We dropped some internal symbols from the API that we know have no
        external consumers, see upstream changelog for list of dropped symbols
    Bug fixes:
    - Fix removal of defunct OVS vlan interfaces (LP: #1959147)
    - Make ConfigManager cleanup on destruction (LP: #1959729)
    - Do not write unvalidated YAML from keyfile (LP: #1952967)
    - Disable tmp address generation for real with NetworkManager (LP: #1948027)
    - Ignore empty YAML hints, delete files on 'set network=null' (LP: #1946957)
    - Wait for 'netplan try' to be ready in DBus API (LP: #1949893)
    - Initialize self.state in 'apply' (LP: #1949104)
    - Driver fallback to nl80211 and/or wext for wpa_supplicant (LP: #1814012)
    - Handle missing 'gateway' in keyfile routes, keep 'dns-search' fallback
    - Make it possible to unset a whole devtype subtree (LP: #1942930)
    - Fix memory leaks, dangling pointers & overall cleanup of API data
  * d/t/control: Add explicit wpasupplicant test Depends
  * d/control: Improved glib (v2.70+-) compat
  * d/control: Strict version dependency on libnetplan
  * d/control: Bump standards version to 4.6.0, improve sections
  * Mute false positive lintian warning
  * d/patches/: Drop patches, applied upstream
  * d/p/autopkgtest-fixes: Refresh
  * d/libnetplan0.symbols: Add new symbols for 0.104
  * d/libnetplan0.symbols: Drop (internal) legacy symbols

 -- Lukas Märdian <slyon at ubuntu.com>  Thu, 17 Feb 2022 12:46:23 +0100

** Changed in: netplan.io (Ubuntu Jammy)
       Status: Triaged => Fix Released

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to netplan.io in Ubuntu.
Matching subscriptions: foundations-bugs
https://bugs.launchpad.net/bugs/1918421

Title:
  netplan does not match multiple driver specifications

Status in netplan.io package in Ubuntu:
  Fix Released
Status in netplan.io source package in Jammy:
  Fix Released

Bug description:
  The current network-config configuration for cloud-init on the Ubuntu
  Raspberry Pi images includes the following section for matching the
  built-in Ethernet port on all supported models of Pi:

  ethernets:
    eth0:
      # Rename the built-in ethernet device to "eth0"
      match:
        driver: bcmgenet smsc95xx lan78xx
      set-name: eth0
      dhcp4: true
      optional: true

  The space-separated list of driver names (actually globs) is the
  format supported by networkd; from systemd.network(5):

    Driver=
      A whitespace-separated list of shell-style globs matching the driver currently bound to the
      device, as exposed by the udev property ID_NET_DRIVER of its parent device, or if that is
      not set, the driver as exposed by ethtool -i of the device itself. If the list is prefixed
      with a "!", the test is inverted.

  Given that netplan only supports driver matching when the back-end is
  networkd, it would be logical to assume that it also permits multiple
  specifications here (although the format is somewhat incongruous given
  it's not a YAML list), and this had *appeared* to work historically
  (netplan happily copied the specification to
  /run/systemd/network/10-netplan-eth0.link). However, while testing
  netplan under hirsute a recent change (specifically in 0.101-1) makes
  it clear that it is in fact failing to match the interface:

    $ sudo netplan apply
    []
    Cannot find unique matching interface for 'eth0': {'driver': 'bcmgenet smsc95xx lan78xx'}

  A work-around I'm implementing for now is to use three separate
  sections (each with a different name) to split out the driver
  components but I get the impression netplan probably ought to support
  this a bit more elegantly given the underlying networkd back-end does.

  It would be trivial to tweak "is_interface_matching_driver_name" in
  netplan/cli/utils.py to support the space separated format (and I'm
  happy to provide a PR implementing that if requested) but for the sake
  of consistency I suspect the schema ought to be extended to support
  the option of a YAML list instead of a string for that value?

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/netplan.io/+bug/1918421/+subscriptions




More information about the foundations-bugs mailing list