From 9d694ba3515f6077d2f66b272d3df1ab082b7bea Mon Sep 17 00:00:00 2001 From: Jason Dillaman Date: Tue, 19 Feb 2019 15:48:38 -0500 Subject: [PATCH] qa/workunits/rbd: delete pools before stopping rbd-mirror This better mimics the behavior of teuthology and tests rbd-mirror daemon's ability to handle a pool deletion. Signed-off-by: Jason Dillaman --- qa/workunits/rbd/rbd_mirror_helpers.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/qa/workunits/rbd/rbd_mirror_helpers.sh b/qa/workunits/rbd/rbd_mirror_helpers.sh index 7d874d900e3..9d5c3c8fff4 100755 --- a/qa/workunits/rbd/rbd_mirror_helpers.sh +++ b/qa/workunits/rbd/rbd_mirror_helpers.sh @@ -323,6 +323,11 @@ cleanup() if [ -z "${RBD_MIRROR_NOCLEANUP}" ]; then local cluster instance + CEPH_ARGS='' ceph --cluster ${CLUSTER1} osd pool rm ${POOL} ${POOL} --yes-i-really-really-mean-it + CEPH_ARGS='' ceph --cluster ${CLUSTER2} osd pool rm ${POOL} ${POOL} --yes-i-really-really-mean-it + CEPH_ARGS='' ceph --cluster ${CLUSTER1} osd pool rm ${PARENT_POOL} ${PARENT_POOL} --yes-i-really-really-mean-it + CEPH_ARGS='' ceph --cluster ${CLUSTER2} osd pool rm ${PARENT_POOL} ${PARENT_POOL} --yes-i-really-really-mean-it + for cluster in "${CLUSTER1}" "${CLUSTER2}"; do stop_mirrors "${cluster}" done @@ -331,11 +336,6 @@ cleanup() cd ${CEPH_ROOT} CEPH_ARGS='' ${CEPH_SRC}/mstop.sh ${CLUSTER1} CEPH_ARGS='' ${CEPH_SRC}/mstop.sh ${CLUSTER2} - else - CEPH_ARGS='' ceph --cluster ${CLUSTER1} osd pool rm ${POOL} ${POOL} --yes-i-really-really-mean-it - CEPH_ARGS='' ceph --cluster ${CLUSTER2} osd pool rm ${POOL} ${POOL} --yes-i-really-really-mean-it - CEPH_ARGS='' ceph --cluster ${CLUSTER1} osd pool rm ${PARENT_POOL} ${PARENT_POOL} --yes-i-really-really-mean-it - CEPH_ARGS='' ceph --cluster ${CLUSTER2} osd pool rm ${PARENT_POOL} ${PARENT_POOL} --yes-i-really-really-mean-it fi test "${RBD_MIRROR_TEMDIR}" = "${TEMPDIR}" || rm -Rf ${TEMPDIR} fi -- 2.39.5