Bug 1826701

Summary: Can't deprovision and can't delete a powered off baremetal node
Product: OpenShift Container Platform Reporter: Udi Kalifon <ukalifon>
Component: Console Metal3 PluginAssignee: Jiri Tomasek <jtomasek>
Status: CLOSED ERRATA QA Contact: Udi Kalifon <ukalifon>
Severity: high Docs Contact:
Priority: high    
Version: 4.4CC: aos-bugs, tjelinek, yanpzhan
Target Milestone: ---   
Target Release: 4.5.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-07-13 17:30:08 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Udi Kalifon 2020-04-22 11:13:03 UTC
Description of problem:
If a node is in power off state, clicking on "Deprovision" yields no results, and the option to delete the baremetal node is totally missing


Version-Release number of selected component (if applicable):
4.4.0-0.nightly-2020-04-18-095545


How reproducible:
100%


Steps to Reproduce:
1. Power off a baremetal host without doing a graceful shutdown. It should still be in "Provisioned" state, and powered off.
2. Try to delete the bmh - but the command to delete the host is not even available in the kebab menu.
3. From the kebab menu, click on "Deprovision". Nothing happens.


Actual results:
Now there is no more "Deprovision" and also no way to delete the host.

Comment 1 Udi Kalifon 2020-04-22 11:21:17 UTC
I also can't start maintenance on a powered off host; the status changes to "Starting maintenance", and just hangs on that and the node is not powered on.

Comment 2 Jiri Tomasek 2020-05-15 09:52:24 UTC
Deleting the host is disabled because it is not safe to do so. Deleting the host resource which has node assigned and runs workloads would lead to inconsistency. Only deprovisioned host can be deleted.

We'll investigate deprovision action, most likely the deprovision is stuck due to host being off. I think we should disable deprovision action for powered off host.

Comment 5 Yanping Zhang 2020-06-17 03:12:21 UTC
Checked on IPI BM cluster with payload 4.5.0-0.nightly-2020-06-11-183238.
Power off a baremetal host, check the host's action list, there is no "Deprovision" item now. Delete the host by clicking "Delete Bare Metal Host", could succeed.

Comment 6 errata-xmlrpc 2020-07-13 17:30:08 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHBA-2020:2409