From 6db4fceba45b78b4a779b191756b1731ac65c5d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Han?= Date: Mon, 27 Aug 2018 11:02:59 -0700 Subject: [PATCH] purge: only purge /var/lib/ceph content MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sometime /var/lib/ceph is mounted on a device so we won't be able to remove it (device busy) so let's remove its content only. Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1615872 Signed-off-by: Sébastien Han (cherry picked from commit 38dc20e74b89c1833d45f677f405fe758fd10c04) --- infrastructure-playbooks/purge-cluster.yml | 4 +--- infrastructure-playbooks/purge-docker-cluster.yml | 4 +++- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/infrastructure-playbooks/purge-cluster.yml b/infrastructure-playbooks/purge-cluster.yml index e3c695352..9f3692abc 100644 --- a/infrastructure-playbooks/purge-cluster.yml +++ b/infrastructure-playbooks/purge-cluster.yml @@ -534,9 +534,7 @@ listen: "remove data" - name: remove data - file: - path: /var/lib/ceph - state: absent + command: rm -rf /var/lib/ceph/* listen: "remove data" tasks: diff --git a/infrastructure-playbooks/purge-docker-cluster.yml b/infrastructure-playbooks/purge-docker-cluster.yml index 6e4057986..b52c491df 100644 --- a/infrastructure-playbooks/purge-docker-cluster.yml +++ b/infrastructure-playbooks/purge-docker-cluster.yml @@ -651,9 +651,11 @@ state: absent with_items: - /etc/ceph - - /var/lib/ceph - /var/log/ceph + - name: remove data + command: rm -rf /var/lib/ceph/* + - name: purge fetch directory