$ cat /etc/systemd/network/10-ens3.network [Match] Name=ens3 [Link] MACAddress=00:16:3e:ff:ff:ff
[Network] DHCP=yes ubuntu@lp1929560-g:~$ dpkg -l systemd|grep systemd ii systemd 246.6-1ubuntu1.3 amd64 system and service manager ubuntu@lp1929560-g:~$ ip l show dev ens3 2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000 link/ether 52:54:00:be:9d:58 brd ff:ff:ff:ff:ff:ff altname enp0s3 ubuntu@lp1929560-g:~$ sudo systemctl restart systemd-networkd ubuntu@lp1929560-g:~$ ip l show dev ens3 2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000 link/ether 52:54:00:be:9d:58 brd ff:ff:ff:ff:ff:ff altname enp0s3 ubuntu@lp1929560-g:~$ sudo ip l set down dev ens3 ubuntu@lp1929560-g:~$ ip l show dev ens3 2: ens3: <BROADCAST,MULTICAST> mtu 1500 qdisc fq_codel state DOWN mode DEFAULT group default qlen 1000 link/ether 52:54:00:be:9d:58 brd ff:ff:ff:ff:ff:ff altname enp0s3 ubuntu@lp1929560-g:~$ sudo systemctl restart systemd-networkd ubuntu@lp1929560-g:~$ ip l show dev ens3 2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000 link/ether 00:16:3e:ff:ff:ff brd ff:ff:ff:ff:ff:ff permaddr 52:54:00:be:9d:58 altname enp0s3 ubuntu@lp1929560-g:~$ dpkg -l systemd|grep systemd ii systemd 246.6-1ubuntu1.4 amd64 system and service manager ubuntu@lp1929560-g:~$ ip l show dev ens3 2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000 link/ether 52:54:00:be:9d:58 brd ff:ff:ff:ff:ff:ff altname enp0s3 ubuntu@lp1929560-g:~$ sudo systemctl restart systemd-networkd ubuntu@lp1929560-g:~$ ip l show dev ens3 2: ens3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP mode DEFAULT group default qlen 1000 link/ether 00:16:3e:ff:ff:ff brd ff:ff:ff:ff:ff:ff permaddr 52:54:00:be:9d:58 altname enp0s3 ** Tags removed: verification-needed-groovy ** Tags added: verification-done-groovy -- You received this bug notification because you are a member of Ubuntu Touch seeded packages, which is subscribed to systemd in Ubuntu. https://bugs.launchpad.net/bugs/1929560 Title: link mac isn't set if already up Status in systemd: Fix Released Status in systemd package in Ubuntu: Fix Released Status in systemd source package in Bionic: Fix Committed Status in systemd source package in Focal: Fix Committed Status in systemd source package in Groovy: Fix Committed Bug description: [impact] if link is already up, configured mac isn't set this also affects the master/nomaster configuration [test case] create .network config for the link, for example: [Match] Name=eth0 [Link] MACAddress=00:16:3e:ff:ff:ff [Network] DHCP=yes make sure the link is already up, and restart systemd-networkd: root@test-f:/etc/systemd/network# ip l show eth0 61: eth0@if62: <BROADCAST,MULTICAST> mtu 1500 qdisc noqueue state DOWN mode DEFAULT group default qlen 1000 link/ether 00:16:3e:fc:b2:00 brd ff:ff:ff:ff:ff:ff link-netnsid 0 root@test-f:/etc/systemd/network# ip l set dev eth0 up root@test-f:/etc/systemd/network# ip l show eth0 61: eth0@if62: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000 link/ether 00:16:3e:fc:b2:00 brd ff:ff:ff:ff:ff:ff link-netnsid 0 root@test-f:/etc/systemd/network# systemctl restart systemd-networkd root@test-f:/etc/systemd/network# ip l show eth0 61: eth0@if62: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000 link/ether 00:16:3e:fc:b2:00 brd ff:ff:ff:ff:ff:ff link-netnsid 0 root@test-f:/etc/systemd/network# ip l set dev eth0 down root@test-f:/etc/systemd/network# ip l show eth0 61: eth0@if62: <BROADCAST,MULTICAST> mtu 1500 qdisc noqueue state DOWN mode DEFAULT group default qlen 1000 link/ether 00:16:3e:fc:b2:00 brd ff:ff:ff:ff:ff:ff link-netnsid 0 root@test-f:/etc/systemd/network# systemctl restart systemd-networkd root@test-f:/etc/systemd/network# ip l show eth0 61: eth0@if62: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP mode DEFAULT group default qlen 1000 link/ether 00:16:3e:ff:ff:ff brd ff:ff:ff:ff:ff:ff link-netnsid 0 [regression potential] any regression would likely result in incorrectly set link mac and/or master, or failure to correctly set mac and/or master [scope] this is needed for g and earlier this is fixed upstream by commit e16e4b3bedc57919b3ecb4096e941709a5d39b8a which is included in v247 so this is fixed already in h and later [other info] this moves the configuration of the link mac and master out of the link_up() function, so this also allows repeated calls to link_up() without reconfiguring the link mac and master. That behavior is useful for the commits for bug 1664844 To manage notifications about this bug go to: https://bugs.launchpad.net/systemd/+bug/1929560/+subscriptions -- Mailing list: https://launchpad.net/~touch-packages Post to : touch-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~touch-packages More help : https://help.launchpad.net/ListHelp