Networkd vs udev nic renaming race condition

Bug #1923115 reported by Seyeong Kim
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
systemd (Ubuntu)
Fix Released
Undecided
Unassigned
Bionic
Fix Released
Undecided
Seyeong Kim
Focal
Fix Released
Undecided
Unassigned

Bug Description

[Impact]

systemd-networkd renames nic just after udev renamed it

e.g

kernel: [ 2.827368] vmxnet3 0000:0b:00.0 ens192: renamed from eth0
kernel: [ 7.562729] vmxnet3 0000:0b:00.0 eth0: renamed from ens192
systemd-networkd[511]: ens192: Interface name change detected, ens192 has been renamed to eth0.

This cause netplan or the other network management pkg can't find proper nic sometimes.

This happens on Bionic

Below commit seems to solve this issue.
https://github.com/systemd/systemd/pull/11881/commits/30de2b89d125a8692c22579ef805b03f2054b30b

There are bunch of related commits but above one the customer tested it worked.

[Test Plan]

The customer has issue and they could help us to test this.
Internally they already test this and it worked.

Please refer to github issue's reproduction step as well.
https://github.com/systemd/systemd/issues/7293#issue-272917058
where the test plan is described as:
"Reboot a couple of times. Sometimes the interface is renamed correctly. Sometimes it is not."

[Where problems could occur]

systemd-networkd should be restarted for this patch. systemd-networkd nic renaming could have issue. renaming may not be happening unexpectedly. e.g doesn't rename it properly or rename it when it should do.

[Others]

Seyeong Kim (seyeongkim)
Changed in systemd (Ubuntu Focal):
status: New → Fix Released
Changed in systemd (Ubuntu):
status: New → Fix Released
Changed in systemd (Ubuntu Bionic):
status: New → In Progress
tags: added: sts
Changed in systemd (Ubuntu Bionic):
assignee: nobody → Seyeong Kim (seyeongkim)
Revision history for this message
Seyeong Kim (seyeongkim) wrote :
Seyeong Kim (seyeongkim)
description: updated
Seyeong Kim (seyeongkim)
description: updated
description: updated
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello Seyeong, or anyone else affected,

Accepted systemd into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/systemd/237-3ubuntu10.47 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in systemd (Ubuntu Bionic):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-bionic
Revision history for this message
Ubuntu SRU Bot (ubuntu-sru-bot) wrote : Autopkgtest regression report (systemd/237-3ubuntu10.47)

All autopkgtests for the newly accepted systemd (237-3ubuntu10.47) for bionic have finished running.
The following regressions have been reported in tests triggered by the package:

openssh/1:7.6p1-4ubuntu0.3 (arm64, ppc64el, s390x, i386, armhf, amd64)
lxc/3.0.3-0ubuntu1~18.04.1 (amd64)
snapd/2.48.3+18.04 (s390x)
systemd/237-3ubuntu10.47 (i386)
polkit-qt-1/0.112.0-5 (ppc64el)
network-manager/1.10.6-2ubuntu1.4 (amd64)
linux-hwe-5.4/5.4.0-72.80~18.04.1 (i386)
linux-gke-5.4/5.4.0-1040.42~18.04.1 (amd64)
casync/2+61.20180112-1 (s390x)
linux-hwe-5.0/5.0.0-65.71 (i386)
ubuntu-drivers-common/1:0.8.6.3~0.18.04.1 (ppc64el)
netplan.io/0.99-0ubuntu3~18.04.4 (i386)

Please visit the excuses page listed below and investigate the failures, proceeding afterwards as per the StableReleaseUpdates policy regarding autopkgtest regressions [1].

https://people.canonical.com/~ubuntu-archive/proposed-migration/bionic/update_excuses.html#systemd

[1] https://wiki.ubuntu.com/StableReleaseUpdates#Autopkgtest_Regressions

Thank you!

Revision history for this message
Fabio Augusto Miranda Martins (fabio.martins) wrote :

Customer has provided a positive feedback that the package in -proposed fixed this bug

Dan Streetman (ddstreet)
tags: added: verification-done verification-done-bionic
removed: verification-needed verification-needed-bionic
Revision history for this message
Łukasz Zemczak (sil2100) wrote :

There are still some autopkgtest issues for this package - can those get addressed? Are those irrelevant to the new version?

Revision history for this message
Dan Streetman (ddstreet) wrote :

only remaining failed autopkgtests are systemd/i386, which looks like it timed out, and linux-hwe-5.4/i386, which nearly always fails.

I started another re-run for systemd/i386 but even if it fails again it seems unlikely the timeout is related to the patch for this bug.

Revision history for this message
Dan Streetman (ddstreet) wrote :

re: autopkgtests, please note that while the pending-sru page and update_excuses page both show the systemd/i386 test as 'failing', it actually passed:
https://autopkgtest.ubuntu.com/packages/s/systemd/bionic/i386

the update_excuses and pending-sru pages appear to be stuck/broken, possibly due to the recent autopkgtest results url change

the linux-hwe-5.4/i386 autopkgtest still is failing, but it always fails for everything, so it can be ignored

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package systemd - 237-3ubuntu10.47

---------------
systemd (237-3ubuntu10.47) bionic; urgency=medium

  * d/p/network_always_drop_configs_when_interface_is_renamed.patch:
    Fix networkd renaming race condition (LP: #1923115)

 -- Seyeong Kim <email address hidden> Wed, 07 Apr 2021 15:11:17 +0900

Changed in systemd (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Update Released

The verification of the Stable Release Update for systemd has completed successfully and the package is now being released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Łukasz Zemczak (sil2100) wrote :

...as for the autopkgtest failures being marked as failed even thought they passed, it seems britney wasn't running for bionic since the 27th of April! It was not caused by any changes or anything, it simply wasn't running - after digging deeper it seems that there was a stale lockfile that prevented it from running. I have cleared it and hopefully things should be working normally now.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.