[Ovirt-devel] [PATCH node] Fix hang when cleaning dirty storage

Mike Burns mburns at redhat.com
Thu Mar 11 19:55:09 UTC 2010


Code that scanned for dirty storage was accidentally grepping the
contents of an entire partition.  This led to an apparent hang in
situations where partitions were large.

Signed-off-by: Mike Burns <mburns at redhat.com>
---
 scripts/ovirt-config-storage |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/scripts/ovirt-config-storage b/scripts/ovirt-config-storage
index aea73f8..92d79dd 100755
--- a/scripts/ovirt-config-storage
+++ b/scripts/ovirt-config-storage
@@ -550,7 +550,7 @@ wipe_lvm_on_disk()
     unmount_logging
     for vg in $(pvs -o vg_name --noheadings $HOSTVGDRIVE* 2>/dev/null|sort -u); do
         if pvs -o pv_name,vg_name --noheadings | \
-            grep $vg | grep -v -q $dev* 2>/dev/null; then
+            grep $vg | egrep -v -q "${dev}p?[0-9]*" 2>/dev/null; then
             log "The volume group \"$vg\" spans multiple disks."
             log "This operation cannot complete.  Please manullay"
             log "cleanup the storage using standard linux tools."
-- 
1.6.6.1




More information about the ovirt-devel mailing list