Hi,
First of all, I don't know if this bug is related to the new ubuntu 20.04 ecosystem or to the new netplan version.
The problem arises when we try to rename a network interface, for example with this config file:
```
network:
version: 2
ethernets:
ens4:
accept-ra: no
dhcp4: false
match:
macaddress: fa:16:3e:b5:71:18
set-name: uplink
```
The same configuration works on ubuntu 19.10 with netplan 0.98-0ubuntu1, but fails on ubuntu 20.04 with netplan 0.99-0ubuntu2 with the error:
```~# netplan apply
Traceback (most recent call last):
File "/usr/sbin/netplan", line 23, in <module>
netplan.main()
File "/usr/share/netplan/netplan/cli/core.py", line 50, in main
self.run_command()
File "/usr/share/netplan/netplan/cli/utils.py", line 179, in run_command
self.func()
File "/usr/share/netplan/netplan/cli/commands/apply.py", line 46, in run
self.run_command()
File "/usr/share/netplan/netplan/cli/utils.py", line 179, in run_command
self.func()
File "/usr/share/netplan/netplan/cli/commands/apply.py", line 162, in command_apply
subprocess.check_call(['ip', 'link', 'set',
File "/usr/lib/python3.8/subprocess.py", line 364, in check_call
raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['ip', 'link', 'set', 'dev', 'ens4', 'name', 'uplink']' returned non-zero exit status 2.
```
At this time, the fix is to set the interface down, and apply netplan conf again.
Hi,
First of all, I don't know if this bug is related to the new ubuntu 20.04 ecosystem or to the new netplan version.
The problem arises when we try to rename a network interface, for example with this config file:
```
network:
version: 2
ethernets:
ens4:
accept-ra: no
dhcp4: false
match:
macaddress: fa:16:3e:b5:71:18
set-name: uplink
```
The same configuration works on ubuntu 19.10 with netplan 0.98-0ubuntu1, but fails on ubuntu 20.04 with netplan 0.99-0ubuntu2 with the error: netplan" , line 23, in <module> netplan/ netplan/ cli/core. py", line 50, in main run_command( ) netplan/ netplan/ cli/utils. py", line 179, in run_command netplan/ netplan/ cli/commands/ apply.py" , line 46, in run run_command( ) netplan/ netplan/ cli/utils. py", line 179, in run_command netplan/ netplan/ cli/commands/ apply.py" , line 162, in command_apply check_call( ['ip', 'link', 'set', python3. 8/subprocess. py", line 364, in check_call ror(retcode, cmd) CalledProcessEr ror: Command '['ip', 'link', 'set', 'dev', 'ens4', 'name', 'uplink']' returned non-zero exit status 2.
```~# netplan apply
Traceback (most recent call last):
File "/usr/sbin/
netplan.main()
File "/usr/share/
self.
File "/usr/share/
self.func()
File "/usr/share/
self.
File "/usr/share/
self.func()
File "/usr/share/
subprocess.
File "/usr/lib/
raise CalledProcessEr
subprocess.
```
At this time, the fix is to set the interface down, and apply netplan conf again.
Cheers