From: Harald Hoyer Date: Fri, 23 Jul 2010 10:16:11 +0000 (+0200) Subject: lvm: wait for all rd_LVM_LV and rd_LVM_VG specified to appear X-Git-Tag: 007~64 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=3ad4f77cef57565977c10514e80a9992060e84f0;p=thirdparty%2Fdracut.git lvm: wait for all rd_LVM_LV and rd_LVM_VG specified to appear --- diff --git a/modules.d/90lvm/parse-lvm.sh b/modules.d/90lvm/parse-lvm.sh index 2d453e867..5e93d3ef1 100755 --- a/modules.d/90lvm/parse-lvm.sh +++ b/modules.d/90lvm/parse-lvm.sh @@ -1,10 +1,18 @@ -if getarg rd_NO_LVM; then - info "rd_NO_LVM: removing LVM activation" - rm -f /etc/udev/rules.d/64-lvm*.rules -fi - if [ -e /etc/lvm/lvm.conf ] && getarg rd_NO_LVMCONF; then rm -f /etc/lvm/lvm.conf fi +if getarg rd_NO_LVM; then + info "rd_NO_LVM: removing LVM activation" + rm -f /etc/udev/rules.d/64-lvm*.rules +else + for dev in $(getargs rd_LVM_VG=) $(getargs rd_LVM_LV=); do + printf '[ -e "/dev/%s" ] || exit 1\n' $dev \ + >> /initqueue-finished/lvm.sh + { + printf '[ -e "/dev/%s" ] || ' $dev + printf 'warn "LVM "%s" not found"\n' $dev + } >> /emergency/00-lvm.sh + done +fi