diff options
author | CoprDistGit <infra@openeuler.org> | 2023-09-19 03:22:19 +0000 |
---|---|---|
committer | CoprDistGit <infra@openeuler.org> | 2023-09-19 03:22:19 +0000 |
commit | bb2d27c6843d99793e50a67e20e64852c3dd4d85 (patch) | |
tree | 74f3f8647e43cc7f39873fb2ba713cebe9862c1d /backport-fix-lvm-restore-setting-LVM_MD_PV_ACTIVATED.patch | |
parent | ff3056a5eddb9b203fdd900eeecc0771d981d138 (diff) |
automatic import of dracutopeneuler20.03
Diffstat (limited to 'backport-fix-lvm-restore-setting-LVM_MD_PV_ACTIVATED.patch')
-rw-r--r-- | backport-fix-lvm-restore-setting-LVM_MD_PV_ACTIVATED.patch | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/backport-fix-lvm-restore-setting-LVM_MD_PV_ACTIVATED.patch b/backport-fix-lvm-restore-setting-LVM_MD_PV_ACTIVATED.patch new file mode 100644 index 0000000..72083da --- /dev/null +++ b/backport-fix-lvm-restore-setting-LVM_MD_PV_ACTIVATED.patch @@ -0,0 +1,38 @@ +From 164e5ebb1199ea3e3d641ce402d8257f0055a529 Mon Sep 17 00:00:00 2001 +From: David Teigland <teigland@redhat.com> +Date: Fri, 17 Dec 2021 12:14:51 -0600 +Subject: [PATCH] fix(lvm): restore setting LVM_MD_PV_ACTIVATED + +The 69-dm-lvm-metad.rules udev rule has been removed from +the initrd, because it's been dropped by recent upstream +lvm versions, and it never performed any primary function +within the initrd. But, it did have the job of setting +LVM_MD_PV_ACTIVATED=1 for active md devices used by PVs. +That step needs to be restored, and is now included in +64-lvm.rules. +--- + modules.d/90lvm/64-lvm.rules | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/modules.d/90lvm/64-lvm.rules b/modules.d/90lvm/64-lvm.rules +index ca718ce..1ad4911 100644 +--- a/modules.d/90lvm/64-lvm.rules ++++ b/modules.d/90lvm/64-lvm.rules +@@ -6,6 +6,14 @@ + + SUBSYSTEM!="block", GOTO="lvm_end" + ACTION!="add|change", GOTO="lvm_end" ++ ++# If the md device is active (indicated by array_state), then set the flag ++# LVM_MD_PV_ACTIVATED=1 indicating that the md device for the PV is ready ++# to be used. The lvm udev rule running in root will check that this flag ++# is set before it will process the md device (it wants to avoid ++# processing an md device that exists but is not yet ready to be used.) ++KERNEL=="md[0-9]*", ACTION=="change", ENV{ID_FS_TYPE}=="LVM2_member", ENV{LVM_MD_PV_ACTIVATED}!="1", TEST=="md/array_state", ENV{LVM_MD_PV_ACTIVATED}="1" ++ + # Also don't process disks that are slated to be a multipath device + ENV{DM_MULTIPATH_DEVICE_PATH}=="1", GOTO="lvm_end" + KERNEL=="dm-[0-9]*", ACTION=="add", GOTO="lvm_end" +-- +1.8.3.1 + |