** Description changed:

- Hi,
+ [Impact]
+ Several users have complained of issues with bringing up networking in the 
initramfs, which causes automatic LUKS volume unlocking via a network server to 
fail. The original report for this bug is one example, others can be found in 
the upstream bug:
+   https://github.com/latchset/clevis/issues/145
  
- initramfs-clevis wait 1s for carrier to show up, this is not much and not 
working in most cases.
- For me i have to up to 12 seconds for lan carrier. 
+ The symptoms vary - see the commit message in [Fix] below for an
+ enumerated list - but the general root cause is that we currently fail
+ to wait for device enumeration to complete before trying to configure an
+ interface.
  
- fix:
- i changed /usr/share/initramfs-tools/scripts/local-top/clevis
- to 12s loop:
+ [Test Case]
+ Boot a system with a slow-to-enumerate network device and confirm that the 
system is able to use it to automatically decrypt a LUKS root device.
  
- eth_check() {
-     for device in $(clevis_all_netbootable_devices); do
-         for i in {1..12}; do
-             ip link set dev $device up
-             sleep 1
-             ETH_HAS_CARRIER=$(cat /sys/class/net/"$device"/carrier)
-             if [ "$ETH_HAS_CARRIER" = '1' ]; then
-                 return 0
-             fi  
-         done
-     done
-     return 1
- }
  
- ProblemType: Bug
- DistroRelease: Ubuntu 20.04
- Package: clevis-initramfs 12-1ubuntu2 [modified: 
usr/share/initramfs-tools/scripts/local-top/clevis]
- ProcVersionSignature: Ubuntu 5.4.0-25.29-generic 5.4.30
- Uname: Linux 5.4.0-25-generic x86_64
- ApportVersion: 2.20.11-0ubuntu27
- Architecture: amd64
- CasperMD5CheckResult: skip
- CurrentDesktop: KDE
- Date: Mon Apr 20 18:55:44 2020
- InstallationDate: Installed on 2020-04-18 (2 days ago)
- InstallationMedia: Kubuntu 20.04 LTS "Focal Fossa" - Beta amd64 (20200401)
- PackageArchitecture: all
- SourcePackage: clevis
- UpgradeStatus: No upgrade log present (probably fresh install)
+ [Fix]
+ 
https://github.com/latchset/clevis/commit/f670383c276d6a61e165ff9e498e19271f8e168c
+ 
+ [Regression Potential]
+ The biggest risk I see is if a user was somehow benefiting from some unknown 
side-effect of the existing behavior. The existing "eth_check()" code brings up 
each interface and checks for a carrier. The new code leaves it to 
configure_networking() to bring up the device when its actually time to 
configure it.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1873914

Title:
  initramfs clevis no carrier after 1s, no retry

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/clevis/+bug/1873914/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to