NetworkManager renderer for Netplan ignores link-local: []
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
netplan.io (Ubuntu) |
Triaged
|
Low
|
Unassigned |
Bug Description
If I am trying to get rid of IPv4 and IPv6 addresses on a particular interface using Netplan, if I use NetworkManager as the renderer, it does not follow the last of these three Netplan documentation examples:
Example to enable only IPv4 link-local: link-local: [ ipv4 ]
Example to enable all link-local addresses: link-local: [ ipv4, ipv6 ]
Example to disable all link-local addresses: link-local: [ ]
/etc/netplan/
network:
version: 2
renderer: NetworkManager
ethernets:
lan:
match:
macaddress: a8:20:XX:XX:9f:da
dhcp6: true
addresses:
- 192.168.1.3/24
routes:
- to: default
via: 192.168.1.1
metric: 100
nameservers:
addresses: [192.168.1.1]
search: []
set-name: lan
softether:
match:
macaddress: 40:6c:XX:XX:4a:93
optional: true
link-local: []
set-name: softether
Followed by `netplan generate` and `netplan apply`, results of `ip a` for the softether interface...
2: softether: <BROADCAST,
link/ether 40:6c:XX:XX:4a:93 brd ff:ff:ff:ff:ff:ff
altname enp9s0
inet 169.254.65.216/16 brd 169.254.255.255 scope link noprefixroute softether
valid_lft forever preferred_lft forever
inet6 fd8b:a698:
valid_lft 769sec preferred_lft 0sec
inet6 fd97:65c2:
valid_lft 1785sec preferred_lft 1785sec
inet6 fda2:db11:
valid_lft 769sec preferred_lft 0sec
inet6 fdaa:ed5f:
valid_lft 770sec preferred_lft 0sec
inet6 fe80::426c:
valid_lft forever preferred_lft forever
However, if the renderer is changed to networkd...
network:
version: 2
renderer: networkd
ethernets:
lan:
match:
macaddress: a8:20:XX:XX:9f:da
dhcp6: true
addresses:
- 192.168.1.3/24
routes:
- to: default
via: 192.168.1.1
metric: 100
nameservers:
addresses: [192.168.1.1]
search: []
set-name: lan
softether:
match:
macaddress: 40:6c:XX:XX:4a:93
optional: true
link-local: []
set-name: softether
Then `netplan generate` and `netplan apply`, results of `ip a` for the softether interface...
2: softether: <BROADCAST,
link/ether 40:6c:XX:XX:4a:93 brd ff:ff:ff:ff:ff:ff
altname enp9s0
To recap, using NetworkManager as the renderer for Netplan fails to eliminate IPv4 and IPv6 addresses when setting link-local: [].
ProblemType: Bug
DistroRelease: Ubuntu 21.10
Package: ubiquity (not installed)
ProcVersionSign
Uname: Linux 5.13.0-20-generic x86_64
NonfreeKernelMo
ApportVersion: 2.20.11-0ubuntu71
Architecture: amd64
CasperMD5CheckR
Date: Sat Nov 6 12:51:59 2021
InstallCmdLine: BOOT_IMAGE=
InstallationDate: Installed on 2021-11-05 (0 days ago)
InstallationMedia: Ubuntu 21.10 "Impish Indri" - Release amd64 (20211012)
ProcEnviron:
TERM=xterm-
PATH=(custom, no user)
LANG=en_US.UTF-8
SHELL=/bin/bash
SourcePackage: ubiquity
Symptom: installation
UpgradeStatus: No upgrade log present (probably fresh install)
affects: | ubuntu → ubiquity (Ubuntu) |
affects: | ubiquity (Ubuntu) → netplan.io (Ubuntu) |
Indeed, the NetworkManager backend renderer does not seem to act upon those settings. As it does not seem to have any handler implemented as of v0.106. It seems to fallback to "ipv4.method= link-local" whenever nothing else is defined for NetworkManager.
We should improve the implementation of this or at least clearly state the limitation in the documentation.