Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 538558 - sys-kernel/dracut built with USE=systemd is incapable of handling lvm/dmcrypt devices
Summary: sys-kernel/dracut built with USE=systemd is incapable of handling lvm/dmcrypt...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Amadeusz Żołnowski (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-02-02 16:15 UTC by Justus Ranvier
Modified: 2015-03-31 11:44 UTC (History)
2 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 Justus Ranvier 2015-02-02 16:15:09 UTC
I have several systems which boot from dmcrypt (luks) -> mdraid -> lvm volumes.

Dracuts boots these systems with no problems whatsoever as long as it is built with USE=udev.

If dracut is built with USE=systemd instead (without changing any other dracut configuration), the boot process hangs forever because the start jobs for the luks and lvm devices will never finish.

By using the debug shell, I can see that the devices do get created successfully but somehow systemd fails to notice (problem with udev rules / uevents?)

I've experienced this problem with every dracut/lvm/cryptsetup version since >systemd-208

Reproducible: Always
Comment 1 Amadeusz Żołnowski (RETIRED) gentoo-dev 2015-02-02 19:13:43 UTC
Dracut doesn't have udev flag. What do you mean by "built with USE=udev"?
Comment 2 Justus Ranvier 2015-02-02 22:27:55 UTC
Right, that was a mistake.

I mean with dracut built with USE="-systemd", and the other relevant packages like cryptsetup, etc. build with USE="udev"

Toggling USE="systemd" on dracut involves changing a lot of other package's USE flags too, since you can't have udev and systemd installed at the same time.
Comment 3 Amadeusz Żołnowski (RETIRED) gentoo-dev 2015-02-03 07:18:28 UTC
If you have systemd on board then you must enable systemd flag.
Comment 4 Amadeusz Żołnowski (RETIRED) gentoo-dev 2015-03-25 09:54:24 UTC
Is everything working fine if USE=systemd is enabled? Can we close the bug report?
Comment 5 Alexander Tsoy 2015-03-27 12:20:33 UTC
If dracut with systemd can't handle your setup properly, please try patch from the following merge request:
https://github.com/haraldh/dracut/compare/master...dracut-mailing-devs:1425455385-28495-1-git-send-email-jsynacek@redhat.com
Comment 6 Alexander Tsoy 2015-03-30 17:29:14 UTC
Also it would be very nice if you provide debug log. Please append 'rd.break rd.debug log_buf_len=1M rd.retry=4 systemd.log_level=debug' to the kernel cmdline. You will be dropped to an emergency shell. Copy "/run/initramfs/rdsosreport.txt" to persistent storage (e.g. /boot) and attach it to this bug report.
Comment 7 Justus Ranvier 2015-03-31 03:10:28 UTC
The problem may be resolved.

I created a replica of my system as a QEMU/KVM virtual machine so that I could log all output to a serial console in the success case and in the failure case.

Now, I can no longer replicate the failure. One thing that changed since I filed this bug is that the ebuilds now require cryptsetup to be built with USE="-static-libs" when USE="systemd" is set.

Perhaps that was the original problem.
Comment 8 Amadeusz Żołnowski (RETIRED) gentoo-dev 2015-03-31 10:48:13 UTC
Thank you a lot for testing it! I'll add your suggestion to postinst message.
Comment 9 Alexander Tsoy 2015-03-31 11:44:05 UTC
(In reply to Amadeusz Żołnowski from comment #8)
> I'll add your suggestion to postinst message.

I'm not sure it is really needed. virtual/libudev forbids USE="systemd static-libs" since 04 Aug 2014.