Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions crmsh/ui_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -510,6 +510,9 @@ def do_clearstate(self, context, node=None):
if cib_elem is None:
return False
crmd = cib_elem.xpath("//node_state[@uname=\"%s\"]/@crmd" % node)
if not crmd:
logger.error("Node '%s' not found in CIB", node)
return False
if crmd == ["online"] or (crmd[0].isdigit() and int(crmd[0]) != 0):
return utils.ext_cmd(self.node_cleanup_resources % node) == 0
in_ccm = cib_elem.xpath("//node_state[@uname=\"%s\"]/@in_ccm" % node)
Expand Down