[readonly/geninitrd: 497/1068] - another fix to avoid lvdisplay failure to kill /linuxrc
draenog
draenog at pld-linux.org
Sat Nov 2 19:54:10 CET 2013
commit 4cd0639e505c7ed59314c7ad5d501f175a4c8888
Author: Elan Ruusamäe <glen at pld-linux.org>
Date: Fri Nov 2 01:02:31 2007 +0000
- another fix to avoid lvdisplay failure to kill /linuxrc
svn-id: @8956
geninitrd | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/geninitrd b/geninitrd
index 6aed54f..bb4cb08 100755
--- a/geninitrd
+++ b/geninitrd
@@ -1694,10 +1694,11 @@ initrd_gen_lvm() {
# Find out major/minor
attrs="$(lvm.static lvdisplay --ignorelockingfailure -c $LVM_ROOTDEV 2>/dev/null)"
if [ "$attrs" ]; then
- majmin="${attrs#*/}"
- majmin="${majmin#*:*:*:*:*:*:*:*:*:*:*:*}"
- major="${majmin%:*}"
- minor="${majmin#*:}"
+ majmin="${attrs#*$LVM_ROOTDEV*:*:*:*:*:*:*:*:*:*:*:*}"
+ if [ "$majmin" != "$attrs" ]; then
+ major="${majmin%:*}"
+ minor="${majmin#*:}"
+ fi
fi
if [ "$major" -a "$minor" ]; then
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/readonly/geninitrd.git/commitdiff/147754ca159d40ca5eb541074dc043d8cbd92090
More information about the pld-cvs-commit
mailing list