X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=sbin%2Flvremove;h=69f5709eb1ca83f20301f9a071f8a5e3d4835c1f;hb=HEAD;hp=c99accdcf36b83aef0fd0bd282d8f738796fd84c;hpb=75ebe056d92d9d6add8ae4038cf0ac9bf5e67e82;p=ganeti-extstorage-zfs diff --git a/sbin/lvremove b/sbin/lvremove index c99accd..69f5709 100755 --- a/sbin/lvremove +++ b/sbin/lvremove @@ -1,4 +1,4 @@ -#!/bin/sh -x +#!/bin/sh -e . /usr/share/ganeti/extstorage/zfs/defaults.sh @@ -7,14 +7,13 @@ if echo $* | grep -q $EXTP_VG ; then while [ ! -z "$1" ] ; do if echo $1 | grep -q $EXTP_VG ; then - VOL_NAME=`echo $1 | sed -e "s:$EXTP_VG/::" -e 's/\.snap$/@snap/'` + VOL_NAME=`echo $1 | sed -e "s:$EXTP_VG/::"` # FIXME -e 's/\.snap$/@snap/'` fi shift; done # destroy snapshot and clone - zfs destroy -R $EXTP_ZFS/$VOL_NAME || exit 0 # FIXME - test -e /dev/$EXTP_VG/$VOL_NAME && rm /dev/$EXTP_VG/$VOL_NAME + $dir/remove else /sbin/lvm lvrename $* fi