Bug 2164404 - systemd-253~rc1-1.fc38.x86_64 breaks initramfs, infinite wait on device mapper devices
Summary: systemd-253~rc1-1.fc38.x86_64 breaks initramfs, infinite wait on device mappe...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: systemd
Version: 38
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: systemd-maint
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-01-25 13:45 UTC by Petr Pisar
Modified: 2023-06-02 16:05 UTC (History)
11 users (show)

Fixed In Version: systemd-253-3.fc39 systemd-253-6.fc38
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-02-21 15:58:29 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github systemd systemd issues 26488 0 None open Boot failure regression 253 (Bisected) (lvm at fault) 2023-02-21 10:02:20 UTC

Description Petr Pisar 2023-01-25 13:45:02 UTC
After upgrading systemd from 0:252.4-4.fc38.x86_64 to 0:253~rc1-1.fc38.x86_64, initramfs images created with dracut are slightly smaller and they hang on waiting on lvm devices when rebooted.

-rw-------  1 root root 20858769 Jan 25 14:36 initramfs-6.2.0-0.rc4.20230120gitd368967cb103.35.fc38.x86_64.img
-rw-------  1 root root 21087601 Jan 25 14:31 initramfs-6.2.0-0.rc4.20230120gitd368967cb103.35.fc38.x86_64.img.good

The only change in verbose dracut output is this:

# diff -u /tmp/good /tmp/bad |less
--- /tmp/good   2023-01-25 14:34:58.565000000 +0100
+++ /tmp/bad    2023-01-25 14:36:30.378000000 +0100
@@ -66,12 +66,12 @@
 dracut: *** Hardlinking files ***
 dracut: Mode:                     real
 dracut: Method:                   sha256
-dracut: Files:                    1643
+dracut: Files:                    1641
 dracut: Linked:                   12 files
 dracut: Compared:                 0 xattrs
 dracut: Compared:                 434 files
 dracut: Saved:                    396.88 KiB
-dracut: Duration:                 0.029792 seconds
+dracut: Duration:                 0.029782 seconds
 dracut: *** Hardlinking files done ***
 dracut: *** Generating early-microcode cpio image ***
 dracut: *** Store current command line parameters ***

This is the infinite wait on boot in initramfs:

[  OK  ] Started systemd-journald.service - Journal Service. 
         Starting systemd-tmpfiles-  Volatile Files and Directories... 
[  OK  ] Finished systemd-tmpfiles- te Volatile Files and Directories. 
[  OK  ] Finished systemd-vconsole- rvice - Setup Virtual Console. 
         Starting dracut-cmdline.service - dracut cmdline hook... 
[  OK  ] Finished dracut-cmdline.service - dracut cmdline hook. 
         Starting dracut-pre-udev.s vice - dracut pre-udev hook... 
[  OK  ] Finished dracut-pre-udev.service - dracut pre-udev hook. 
         Starting systemd-udevd.ser ger for Device Events and Files... 
[  OK  ] Started systemd-udevd.serv nager for Device Events and Files. 
         Starting systemd-udev-trig [0m - Coldplug All udev Devices... 
[  OK  ] Finished systemd-udev-trig e - Coldplug All udev Devices. 
[  OK  ] Reached target sysinit.target - System Initialization. 
[  OK  ] Reached target basic.target - Basic System. 
         Starting dracut-initqueue. ice - dracut initqueue hook... 
[  OK  ] Finished dracut-initqueue. rvice - dracut initqueue hook. 
[  OK  ] Reached target remote-fs-p eparation for Remote File Systems. 
[  OK  ] Reached target remote-fs.target - Remote File Systems. 
         Starting dracut-pre-mount. ice - dracut pre-mount hook... 
[  OK  ] Finished dracut-pre-mount. rvice - dracut pre-mount hook. 
[ ***  ] Job dev-mapper-vg_dhcp30157\x2dlv_r vice/start running (5s / no limit) 
[    7.398676] systemd-udevd (354) used greatest stack depth: 12584 bytes left 
[  *** ] Job dev-mapper-vg_dhcp30157\x2dlv_r vice/start running (9s / no limit)

Comment 1 Petr Pisar 2023-01-25 14:44:50 UTC
This is the difference in files presented in the initramfs images:

# diff -u good.list bad.list
--- good.list   2023-01-25 15:42:13.369000000 +0100
+++ bad.list    2023-01-25 15:42:18.495000000 +0100
@@ -208,9 +208,6 @@
 ./usr/lib64/libedit.so.0.0.70
 ./usr/lib64/libext2fs.so.2
 ./usr/lib64/libext2fs.so.2.4
-./usr/lib64/libffi.so
-./usr/lib64/libffi.so.8
-./usr/lib64/libffi.so.8.1.2
 ./usr/lib64/libfreebl3.so
 ./usr/lib64/libfreeblpriv3.chk
 ./usr/lib64/libfreeblpriv3.so
@@ -236,9 +233,6 @@
 ./usr/lib64/libnss_mymachines.so.2
 ./usr/lib64/libnss_resolve.so.2
 ./usr/lib64/libnss_systemd.so.2
-./usr/lib64/libp11-kit.so
-./usr/lib64/libp11-kit.so.0
-./usr/lib64/libp11-kit.so.0.3.0
 ./usr/lib64/libpam.so
 ./usr/lib64/libpam.so.0
 ./usr/lib64/libpam.so.0.85.1
@@ -258,13 +252,13 @@
 ./usr/lib64/libsmartcols.so.1.1.0
 ./usr/lib64/libsystemd.so
 ./usr/lib64/libsystemd.so.0
-./usr/lib64/libsystemd.so.0.35.0
+./usr/lib64/libsystemd.so.0.36.0
 ./usr/lib64/libtinfo.so
 ./usr/lib64/libtinfo.so.6
 ./usr/lib64/libtinfo.so.6.4
 ./usr/lib64/libudev.so
 ./usr/lib64/libudev.so.1
-./usr/lib64/libudev.so.1.7.5
+./usr/lib64/libudev.so.1.7.6
 ./usr/lib64/libuuid.so
 ./usr/lib64/libuuid.so.1
 ./usr/lib64/libuuid.so.1.3.0
@@ -275,8 +269,8 @@
 ./usr/lib64/libzstd.so.1
 ./usr/lib64/libzstd.so.1.5.2
 ./usr/lib64/systemd
-./usr/lib64/systemd/libsystemd-core-252.4-4.fc38.so
-./usr/lib64/systemd/libsystemd-shared-252.4-4.fc38.so
+./usr/lib64/systemd/libsystemd-core-253-rc1-1.fc38.so
+./usr/lib64/systemd/libsystemd-shared-253-rc1-1.fc38.so
 ./usr/lib/dracut
 ./usr/lib/dracut/build-parameter.txt
 ./usr/lib/dracut-dev-lib.sh
@@ -1818,7 +1812,6 @@
 ./usr/lib/systemd/system/slices.target
 ./usr/lib/systemd/system/sockets.target
 ./usr/lib/systemd/system/sockets.target.wants
-./usr/lib/systemd/system/sockets.target.wants/systemd-journald-audit.socket
 ./usr/lib/systemd/system/sockets.target.wants/systemd-journald-dev-log.socket
 ./usr/lib/systemd/system/sockets.target.wants/systemd-journald.socket
 ./usr/lib/systemd/system/sockets.target.wants/systemd-udevd-control.socket

Comment 2 Zbigniew Jędrzejewski-Szmek 2023-01-25 16:01:41 UTC
/usr/lib64/libp11-kit.so is now dlopen'ed, instead of being linked statically.
libp11-kit was linked to libffi.
But I don't think libp11-kit is necessary for lvm. I don't think that this
is the cause of the boot failure.

Also systemd-journald-audit.socket is probably unrelated.

I'll try to debug this, but maybe attach a boot log if you have it.

Comment 3 darrell pfeifer 2023-01-25 19:02:34 UTC
Booted qithout rhgb quiet and level 3

Last message is 

Reached target remote-fs.target

Is there a more detailed debug parameter?

I can help test either a workaround or a fix

Comment 4 David Tardon 2023-01-25 20:16:34 UTC
This is likely the same issue as bug 2164594.

Comment 5 Petr Pisar 2023-01-26 08:10:57 UTC
I first suffered from bug #2164594. Then I noticed selinux_status_open() failure in initramfs run. But neither kernel, nor libselinux, nor selinux-policy have changed. So I tried regenerating initramfs to see whether it helps. It did not help (what helped was disabling SELinux in kernel arguments), but surfaced this initramfs generation bug #2164404. Maybe they have the same cause.

Comment 6 Petr Pisar 2023-01-26 13:11:05 UTC
The LVM issue still happens with systemd-253~rc1-3.fc38.x86_64. (Also the SELinux issue continues. But I'm unable to ascribe the SELinux issue to any RPM package.)

Comment 7 darrell pfeifer 2023-01-26 14:07:06 UTC
Changing selinux to enforcing=0 on boot allowed a successful boot for me

Comment 8 darrell pfeifer 2023-01-26 22:21:44 UTC
systemd-253~rc1-3 solved the selinux enforcing problem for me.

Comment 9 Petr Pisar 2023-02-01 08:40:58 UTC
I was able to overcome the SELinux failure with relabeling the whole file system. I had to boot with enforcing=0 for that. It seems that selinux=0 prevents from relabaling the file system.
Nevertheless, dracut run on systemd-0:253~rc1-3.fc38.x86_64 still creates a broken initramfs for me manifesting the same infinite wait on a block device. Tested with kernel-6.2.0-0.rc6.20230131git22b8077d0fce.45.fc38.x86_64.

Comment 10 Ben Cotton 2023-02-07 15:06:25 UTC
This bug appears to have been reported against 'rawhide' during the Fedora Linux 38 development cycle.
Changing version to 38.

Comment 11 Petr Pisar 2023-02-10 10:41:19 UTC
Still an issue for me (systemd-0:253~rc2-7.fc39.x86_64).

Comment 12 Zbigniew Jędrzejewski-Szmek 2023-02-21 10:02:21 UTC
This seems to be the same as https://github.com/systemd/systemd/issues/26488.
We discussed this with dracut maintainers and somebody will prep a patch for dracut.
But for now I'll apply the upstream PR to disable the sandbox in the initrd.

Comment 13 Fedora Update System 2023-02-21 11:11:33 UTC
FEDORA-2023-9e6007f165 has been submitted as an update to Fedora 39. https://bodhi.fedoraproject.org/updates/FEDORA-2023-9e6007f165

Comment 14 Fedora Update System 2023-02-21 11:14:04 UTC
FEDORA-2023-73fea9469f has been submitted as an update to Fedora 38. https://bodhi.fedoraproject.org/updates/FEDORA-2023-73fea9469f

Comment 15 Petr Pisar 2023-02-21 15:00:15 UTC
Thanks. I confirm that this fixes the problem for me in Fedora 39.

Comment 16 Fedora Update System 2023-02-21 15:58:29 UTC
FEDORA-2023-9e6007f165 has been pushed to the Fedora 39 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 17 Fedora Update System 2023-03-14 02:20:04 UTC
FEDORA-2023-5690f5f379 has been pushed to the Fedora 38 testing repository.

You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2023-5690f5f379

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 18 Fedora Update System 2023-03-15 00:17:56 UTC
FEDORA-2023-5690f5f379 has been pushed to the Fedora 38 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 19 Zbigniew Jędrzejewski-Szmek 2023-06-01 14:42:40 UTC
The patch in systemd was supposed to be temporary.
Does anyone know if dracut was updated?
I'd like to drop the patch from systemd.

Comment 20 Petr Pisar 2023-06-02 08:24:18 UTC
Upstream Dracut issue <https://github.com/dracutdevs/dracut/issues/2211> is closed, pull request implementing the fix <https://github.com/dracutdevs/dracut/pull/2270> is closed. The fix in upstream git tree <https://github.com/dracutdevs/dracut/commit/86c8a5a7c2573645e67537fb9975efab808d42c9>. No yet released. Maybe because it caused a regression <https://github.com/dracutdevs/dracut/issues/2349> which is still unresolved. So I guess Fedora's dracut is still affected.

Comment 21 Zbigniew Jędrzejewski-Szmek 2023-06-02 16:05:16 UTC
Thanks. I'll recheck after the next dracut release then.


Note You need to log in before you can comment on or make changes to this bug.