Blame SOURCES/0014-lvm-mdraid-Fix-LVM-on-MD-activation.patch

712866
From 32b970339f5439300fe6155352ec1f17c5e48d78 Mon Sep 17 00:00:00 2001
712866
From: Peter Rajnoha <prajnoha@redhat.com>
712866
Date: Fri, 4 Oct 2013 10:41:24 +0200
712866
Subject: [PATCH] lvm/mdraid: Fix LVM on MD activation
712866
712866
The 69-dm-lvm-metad.rules set some udev env. variables that makes it
712866
possible to detect the right time to activate LVM on MD. The MD is very
712866
similar to DM during activation - it's usable only after proper device
712866
activation - the CHANGE event. We need to make a difference between a
712866
CHANGE event that comes from this activation and CHANGE event that is
712866
the outcome of the WATCH udev rule (otherwise we'd end up with LVM
712866
activation done on each CHANGE event - which is wrong).
712866
712866
So we need the udev databse to be persistent during pivot to root fs
712866
even for MD devices.
712866
---
712866
 modules.d/90lvm/module-setup.sh                   | 2 +-
712866
 modules.d/90mdraid/59-persistent-storage-md.rules | 1 +
712866
 2 files changed, 2 insertions(+), 1 deletion(-)
712866
712866
diff --git a/modules.d/90lvm/module-setup.sh b/modules.d/90lvm/module-setup.sh
5c6c2a
index 2ef9a514..f98ffffd 100755
712866
--- a/modules.d/90lvm/module-setup.sh
712866
+++ b/modules.d/90lvm/module-setup.sh
712866
@@ -82,7 +82,7 @@ install() {
712866
         } > "${initdir}/etc/lvm/lvm.conf"
712866
     fi
712866
 
712866
-    inst_rules 11-dm-lvm.rules
712866
+    inst_rules 11-dm-lvm.rules 69-dm-lvm-metad.rules
712866
     # Gentoo ebuild for LVM2 prior to 2.02.63-r1 doesn't install above rules
712866
     # files, but provides the one below:
712866
     inst_rules 64-device-mapper.rules
712866
diff --git a/modules.d/90mdraid/59-persistent-storage-md.rules b/modules.d/90mdraid/59-persistent-storage-md.rules
5c6c2a
index bea93257..6ef858aa 100644
712866
--- a/modules.d/90mdraid/59-persistent-storage-md.rules
712866
+++ b/modules.d/90mdraid/59-persistent-storage-md.rules
712866
@@ -20,4 +20,5 @@ IMPORT{program}="/sbin/mdadm --detail --export $tempnode"
712866
 IMPORT BLKID
712866
 OPTIONS+="link_priority=100"
712866
 OPTIONS+="watch"
712866
+OPTIONS+="db_persist"
712866
 LABEL="md_end"