|
|
712866 |
From 0c81abbe79938423d41093b620175d97b435feb5 Mon Sep 17 00:00:00 2001
|
|
|
712866 |
From: Harald Hoyer <harald@redhat.com>
|
|
|
712866 |
Date: Thu, 3 Jul 2014 15:04:17 +0200
|
|
|
712866 |
Subject: [PATCH] lvm:module-setup.sh: check for existance of
|
|
|
712866 |
69-dm-lvm-metad.rules
|
|
|
712866 |
|
|
|
712866 |
fixup for 12819a579900b9691e2bfaf14e76fbb025851530
|
|
|
712866 |
|
|
|
712866 |
(cherry picked from commit fecc1d69e5a12c305d93e7dca64bd690a1fe8ff5)
|
|
|
712866 |
---
|
|
|
712866 |
modules.d/90lvm/module-setup.sh | 17 ++++++++++-------
|
|
|
712866 |
1 file changed, 10 insertions(+), 7 deletions(-)
|
|
|
712866 |
|
|
|
712866 |
diff --git a/modules.d/90lvm/module-setup.sh b/modules.d/90lvm/module-setup.sh
|
|
|
5c6c2a |
index 4a49fc7d..0c5890a7 100755
|
|
|
712866 |
--- a/modules.d/90lvm/module-setup.sh
|
|
|
712866 |
+++ b/modules.d/90lvm/module-setup.sh
|
|
|
712866 |
@@ -78,13 +78,16 @@ install() {
|
|
|
712866 |
inst_rules 11-dm-lvm.rules 69-dm-lvm-metad.rules
|
|
|
712866 |
|
|
|
712866 |
# Do not run lvmetad update via pvscan in udev rule - lvmetad is not running yet in dracut!
|
|
|
712866 |
- if [[ -f ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules ]] && \
|
|
|
712866 |
- grep -q SYSTEMD_WANTS ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules; then
|
|
|
712866 |
- sed -i -e 's/^ENV{SYSTEMD_ALIAS}=.*/# No LVM pvscan in dracut - lvmetad is not running yet/' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
- sed -i -e 's/^ENV{ID_MODEL}=.*//' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
- sed -i -e 's/^ENV{SYSTEMD_WANTS}=.*//' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
- else
|
|
|
712866 |
- sed -i -e 's/.*lvm pvscan.*/# No LVM pvscan for in dracut - lvmetad is not running yet/' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
+ if [[ -f ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules ]]; then
|
|
|
712866 |
+ if grep -q SYSTEMD_WANTS ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules; then
|
|
|
712866 |
+ sed -i -e 's/^ENV{SYSTEMD_ALIAS}=.*/# No LVM pvscan in dracut - lvmetad is not running yet/' \
|
|
|
712866 |
+ ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
+ sed -i -e 's/^ENV{ID_MODEL}=.*//' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
+ sed -i -e 's/^ENV{SYSTEMD_WANTS}=.*//' ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
+ else
|
|
|
712866 |
+ sed -i -e 's/.*lvm pvscan.*/# No LVM pvscan for in dracut - lvmetad is not running yet/' \
|
|
|
712866 |
+ ${initdir}/lib/udev/rules.d/69-dm-lvm-metad.rules
|
|
|
712866 |
+ fi
|
|
|
712866 |
fi
|
|
|
712866 |
|
|
|
712866 |
# Gentoo ebuild for LVM2 prior to 2.02.63-r1 doesn't install above rules
|