Netplan 1.0, the network configuration system utilized in Ubuntu, is now accessible

After seven years of development published toolkit release Netplan 1.0, which develops a format for storing network interface settings and associated utilities for managing network configurations. Netplan provides parameter storage in YAML format and provides backends that abstract configuration access for NetworkManager and systemd-networkd. The project code is written in Python and C languages, and distributed by licensed under GPLv3.

In addition to employees from Canonical, employees from Microsoft and Deutsche Telekom also take part in the development of the project. Netplan has already been used in Ubuntu since the 17.10 release, is included in Ubuntu 23.10 Desktop as the default backend in NetworkManager, and is used by default to manage network settings in official Debian 12 cloud builds. Netplan support is also implemented for cloud-init and the Calamares installer. The new release of Netplan 1.0 will be included in the Ubuntu 24.04 distribution and will ship with Debian 13.

Netplan 1.0 marks the first significant stable release, eliminating some long-deprecated features. Removing technical debt made the codebase easier to maintain and removed barriers that were preventing some new ideas from being implemented. Except API stabilization libnetplan1 library, the new version contains the following changes:

  • Simultaneous support for WPA2 and WPA3.
  • Support for Mellanox VF-LAG network devices with SR-IOV (Single-Root I/O Virtualization).
  • New “hairpin” and “port-mac-learning” options useful when configuring VXLAN tunnels using FRRouting.
  • A new set of frameworks for the Python language (python3-netplan), simplifying integration with third-party systems.
  • The “netplan status –diff” command allows you to visually evaluate the differences between the actual state of the settings and the configuration files.

Using netplan unifies the definition of the base configuration files used by NetworkManager and systemd-networkd, eliminating the need to learn the details of each system's configuration formats. The essence of how netplan works is that during the initial boot process it reads basic network settings from the files “/{lib,etc,run}/netplan/*.yaml” and writes the configuration to the /run directory in a format suitable for further processing in systemd-networkd or NetworkManager.

Netplan Features:

  • Ignoring devices not marked in the configuration;
  • All configuration is stored only in the source YAML file (without using /etc/network/interfaces);
  • Ability to split the configuration into several files (for example, to export libvirt and lxd settings);
  • Flexible options for choosing and changing the backend.
  • The description of network interface parameters in netplan is carried out using declarative syntax, which allows you to quite simply describe the structure of a complex network.

Among the advantages of netplan compared to ifupdown:

  • Declarative syntax;
  • Ability to use masks for network interface names, MAC addresses, drivers and other components;
  • Taking into account the context when parsing the hierarchy of network interface parameters, which allows you to correctly and in the correct order pass settings to the handlers (in ifupdown, when parsing complex configurations, problems caused by race conditions cannot be ruled out).

Thanks for reading: