Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 775671 - sys-kernel/dracut-053 doesn't activate root LVM volume
Summary: sys-kernel/dracut-053 doesn't activate root LVM volume
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Patrick McLean
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks:
 
Reported: 2021-03-12 18:58 UTC by Victor Mataré
Modified: 2021-06-17 15:02 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Victor Mataré 2021-03-12 18:58:03 UTC
Basically as the title says. System doesn't boot because the the root volume doesn't come up. If I drop into a rescue shell I can activate it manually, but for some reason dracut just won't do it.

dracut 050 or 051 are working fine.

Can't debug this further right now, just wanted to report the issue so that devs are aware that 053 is probably not ready for stable.

Reproducible: Always
Comment 1 Lars Wendler (Polynomial-C) (RETIRED) gentoo-dev 2021-03-12 19:44:08 UTC
For the record, my LVM-root, that contains a LUKS2 container, gets activated by initrd produced by dracut-053 just fine. So this might be an issue that does not affect all LVM2 users.
Comment 2 Laurent Marciniszyn 2021-03-19 07:38:10 UTC
(In reply to Victor Mataré from comment #0)
> Basically as the title says. System doesn't boot because the the root volume
> doesn't come up. If I drop into a rescue shell I can activate it manually,
> but for some reason dracut just won't do it.
> 
> dracut 050 or 051 are working fine.
> 
> Can't debug this further right now, just wanted to report the issue so that
> devs are aware that 053 is probably not ready for stable.
> 
> Reproducible: Always

Same problem here.
Comment 3 Alexander Tsoy 2021-03-30 20:35:39 UTC
I also cannot reproduce, so we need your help to debug this problem. Please append "rd.debug" to the kernel cmdline. When you are dropped to an emergency shell, the file /run/initramfs/rdsosreport.txt is created. Copy this file to some persistent storage and attach to this bug report.
Comment 4 David 2021-06-16 19:41:06 UTC
Same issue for me, fixed with the following patch

https://github.com/dracutdevs/dracut/commit/ba4bcf5f4f11ad624c647ddf4f566997186135e7


See more info at the bug from RH bugzilla:

https://bugzilla.redhat.com/show_bug.cgi?id=1945596
Comment 5 David 2021-06-16 19:53:41 UTC
Oups, wrong link for the RH related bug. The good one is here:

https://bugzilla.redhat.com/show_bug.cgi?id=1946074

I know that the patch is related to a NetworkManager service, and seems not related with the LVM issue, but it strangely fix my setup (SD -> LUKS -> lvm-root). Hope it will fix the issue for you too.
Comment 6 Mike Gilbert gentoo-dev 2021-06-16 20:01:24 UTC
As you said, that patch has nothing to do with LVM, and would only affect network booting with systemd. I would guess your issue is sporadic and this did not actually resolve the root cause.

If anyone is experiencing difficulty with LVM and dracut-053, I would suggest giving dracut-055 a try.
Comment 7 Alexander Tsoy 2021-06-16 20:31:54 UTC
I was able to reproduce this bug by just including "network" module into initramfs. And patch from comment #4 indeed fixes it.
Comment 8 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2021-06-16 20:36:41 UTC
(In reply to Alexander Tsoy from comment #7)
> I was able to reproduce this bug by just including "network" module into
> initramfs. And patch from comment #4 indeed fixes it.

It made it upstream in 054: https://github.com/dracutdevs/dracut/commit/ba4bcf5f4f11ad624c647ddf4f566997186135e7.
Comment 9 Mike Gilbert gentoo-dev 2021-06-16 20:43:41 UTC
I suppose a dependency loop might cause the boot process to fail without mounting the root filesystem.
Comment 10 David 2021-06-17 13:37:18 UTC
Ok, I think the common point is the network plugin indeed. I use it for unlocking my root LUKS volume remotely. As Mike said, LVM volumes are not activated because of this dependency issue with the network plugin after the LUKS volume unlocking.
Comment 11 Larry the Git Cow gentoo-dev 2021-06-17 15:02:59 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=1e5c3786ee37ebca4e26bc2df7ce32541a46146a

commit 1e5c3786ee37ebca4e26bc2df7ce32541a46146a
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2021-06-17 15:01:51 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2021-06-17 15:01:51 +0000

    sys-kernel/dracut: backport fix for Network Manager
    
    Closes: https://bugs.gentoo.org/775671
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 .../{dracut-053.ebuild => dracut-053-r1.ebuild}    |  1 +
 sys-kernel/dracut/files/053-network-manager.patch  | 24 ++++++++++++++++++++++
 2 files changed, 25 insertions(+)