From f0c137f8f2570b08d5f3e3f40928de19f81c6bd9 Mon Sep 17 00:00:00 2001 From: Javi Fontan Date: Tue, 1 Mar 2016 13:03:10 +0100 Subject: [PATCH] bug #4138: do not use rbd ls -l deleting ceph volumes --- src/datastore_mad/remotes/ceph/ceph_utils.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/datastore_mad/remotes/ceph/ceph_utils.sh b/src/datastore_mad/remotes/ceph/ceph_utils.sh index b79d6bb467..0bd13b8870 100644 --- a/src/datastore_mad/remotes/ceph/ceph_utils.sh +++ b/src/datastore_mad/remotes/ceph/ceph_utils.sh @@ -129,7 +129,7 @@ rbd_top_parent() { pool=$(echo $1 | cut -f1 -d'/') volume=$(echo $1 | cut -f2 -d'/') - snap0=$($RBD ls -l $pool | awk '{print $1}' | grep -E "$volume(-.+)?@0") + snap0=$($RBD ls $pool | grep -E "$volume(-.+)?@0") if [ -n "$snap0" ]; then volume=$pool/${snap0%%@*}