From d7f61aa5071483ac8be940432473ac272b47a4ae Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Apr 09 2021 00:29:47 +0000 Subject: Backport upstream change to fix boot on encrypted LVM (#1946074) --- diff --git a/0001-fix-network-manager-no-default-deps-for-nm-run.servi.patch b/0001-fix-network-manager-no-default-deps-for-nm-run.servi.patch new file mode 100644 index 0000000..38c06cd --- /dev/null +++ b/0001-fix-network-manager-no-default-deps-for-nm-run.servi.patch @@ -0,0 +1,27 @@ +From ba4bcf5f4f11ad624c647ddf4f566997186135e7 Mon Sep 17 00:00:00 2001 +From: Harald Hoyer +Date: Wed, 31 Mar 2021 16:11:41 +0200 +Subject: [PATCH] fix(network-manager): no default deps for nm-run.service + +Otherwise nm-run.service will run only in basic.target, which is too +late in the initramfs. +--- + modules.d/35network-manager/nm-run.service | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/modules.d/35network-manager/nm-run.service b/modules.d/35network-manager/nm-run.service +index 63fe7564..f3493c41 100644 +--- a/modules.d/35network-manager/nm-run.service ++++ b/modules.d/35network-manager/nm-run.service +@@ -2,6 +2,8 @@ + # SPDX-License-Identifier: GPL-2.0-or-later + + [Unit] ++DefaultDependencies=no ++ + #make sure all devices showed up + Wants=systemd-udev-settle.service + After=systemd-udev-settle.service +-- +2.31.1 + diff --git a/dracut.spec b/dracut.spec index 95c5f05..0fd54ac 100644 --- a/dracut.spec +++ b/dracut.spec @@ -5,7 +5,7 @@ # strip the automatically generated dep here and instead co-own the # directory. %global __requires_exclude pkg-config -%define dist_free_release 1 +%define dist_free_release 2 Name: dracut Version: 053 @@ -31,6 +31,12 @@ Source0: http://www.kernel.org/pub/linux/utils/boot/dracut/dracut-%{version}.tar Source1: https://www.gnu.org/licenses/lgpl-2.1.txt +# https://github.com/dracutdevs/dracut/commit/ba4bcf5f4f11ad624c647ddf4f566997186135e7 +# Fixes boot failure with some encrypted LVM configurations, see: +# https://bugzilla.redhat.com/show_bug.cgi?id=1946074 +# https://bugzilla.redhat.com/show_bug.cgi?id=1945596 +Patch0: 0001-fix-network-manager-no-default-deps-for-nm-run.servi.patch + BuildRequires: bash BuildRequires: git-core BuildRequires: pkgconfig(libkmod) >= 23 @@ -479,6 +485,9 @@ echo 'dracut_rescue_image="yes"' > $RPM_BUILD_ROOT%{dracutlibdir}/dracut.conf.d/ %{_prefix}/lib/kernel/install.d/51-dracut-rescue.install %changelog +* Thu Apr 08 2021 Adam Williamson - 053-2 +- Backport upstream change reported to fix boot on some encrypted LVM setups (#1946074) + * Tue Feb 23 2021 Harald Hoyer - 053-1 - version 053