After calling "netplan set" with --origin-hint and an existing interface and then calling it again for a non-existing interface, the original file where the first interface was defined is removed (and the renderer is not preserved):
root@lunar:/etc/netplan# netplan set --origin-hint 90-snapd-config bridges.br54.dhcp4=false
root@lunar:/etc/netplan# ls
0-defaults.yaml 90-snapd-config.yaml
Found another issue with the netplan.io currently in Lunar:
# apt policy netplan.io
netplan.io:
Installed: 0.105-0ubuntu4
Candidate: 0.105-0ubuntu4
(the same problem happens with 0.106)
After calling "netplan set" with --origin-hint and an existing interface and then calling it again for a non-existing interface, the original file where the first interface was defined is removed (and the renderer is not preserved):
root@lunar: /etc/netplan# ls
0-defaults.yaml
root@lunar: /etc/netplan# cat 0-defaults.yaml
network:
version: 2
renderer: NetworkManager
bridges:
br54:
dhcp4: true
root@lunar: /etc/netplan# netplan set --origin-hint 90-snapd-config bridges. br54.dhcp4= false /etc/netplan# ls config. yaml
root@lunar:
0-defaults.yaml 90-snapd-
root@lunar: /etc/netplan# cat 0-defaults.yaml
network:
version: 2
renderer: NetworkManager
bridges:
br54:
dhcp4: true
root@lunar: /etc/netplan# cat 90-snapd- config. yaml
network:
version: 2
bridges:
br54:
dhcp4: false
root@lunar: /etc/netplan# netplan set ethernets. eth2.dhcp4= false lunar:/ etc/netplan# ls config. yaml
root@deleteme-
70-netplan-set.yaml 90-snapd-
root@deleteme- lunar:/ etc/netplan# cat 70-netplan-set.yaml lunar:/ etc/netplan# cat 90-snapd- config. yaml
network:
version: 2
ethernets:
eth2:
dhcp4: false
root@deleteme-
network:
version: 2
bridges:
br54:
dhcp4: false
The same steps on Focal (0.104- 0ubuntu2~ 20.04.2) seem to work fine, except the renderer from 0-defaults.yaml is not preserved in the origin-hint file.