From 2596ddc584d4bf1e7efb8201174aa1639afeacbc Mon Sep 17 00:00:00 2001 From: Adrien Bourmault Date: Sun, 22 May 2022 00:54:36 +0200 Subject: [PATCH] =?UTF-8?q?Ne=20pas=20tra=C3=AEter=20les=20images=20sans?= =?UTF-8?q?=20snapshot?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- blockcommit_all.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/blockcommit_all.sh b/blockcommit_all.sh index 092fc71..19d0d72 100755 --- a/blockcommit_all.sh +++ b/blockcommit_all.sh @@ -8,7 +8,7 @@ do path_vda=$(sudo virsh domblklist $vm | grep vda | cut -d" " -f 8) path_vdb=$(sudo virsh domblklist $vm | grep vdb | cut -d" " -f 8) - if [ ! -z "$path_vda" ] + if [ ! -z "$path_vda" ] && [[ ! "$path_vda" =~ ".raw" ]] then echo "-- BLOCKCOMMITTING $vm disk vda ..." retour=$(sudo virsh blockcommit $vm vda --active --verbose --pivot --delete 2>&1 | tee /dev/tty) @@ -21,7 +21,7 @@ do fi fi - if [ ! -z "$path_vdb" ] + if [ ! -z "$path_vdb" ] && [[ ! "$path_vda" =~ ".raw" ]] then echo "-- BLOCKCOMMITTING $vm disk vdb ..." retour=$(sudo virsh blockcommit $vm vdb --active --verbose --pivot --delete 2>&1 | tee /dev/tty)