From ecef0b8d8be8f20225351b5af4448104937b2fea Mon Sep 17 00:00:00 2001
From: Chris Feist <cfeist@redhat.com>
Date: Wed, 7 Oct 2015 17:54:13 -0500
Subject: [PATCH] Remove all is-managed meta attributes when managing a
resource
---
pcs/resource.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pcs/resource.py b/pcs/resource.py
index 7f2d4c3..c1c5f50 100644
--- a/pcs/resource.py
+++ b/pcs/resource.py
@@ -2351,7 +2351,7 @@ def resource_manage(argv, set_managed):
else:
# Remove the meta attribute from the id specified (and all children)
xpath = "(//primitive|//group|//clone|//master)[@id='"+resource+"']//meta_attributes/nvpair[@name='is-managed']"
- utils.run(["cibadmin", "-D", "--xpath", xpath])
+ utils.run(["cibadmin", "-d", "--xpath", xpath, "--force"])
# Remove the meta attribute from the parent of the id specified, if the parent is a clone or master
xpath = "(//master|//clone)[(group|primitive)[@id='"+resource+"']]/meta_attributes/nvpair[@name='is-managed']"
utils.run(["cibadmin", "-D", "--xpath", xpath])
--
2.4.3