Bug 1394429

Summary: Openstack nodes power on/off fails if provision state is "active"
Product: Red Hat CloudForms Management Engine Reporter: Richard Su <rwsu>
Component: ProvidersAssignee: Richard Su <rwsu>
Status: CLOSED DUPLICATE QA Contact: Dave Johnson <dajohnso>
Severity: high Docs Contact:
Priority: high    
Version: unspecifiedCC: cpelland, jfrey, jhardy, obarenbo, tzumainn
Target Milestone: GAKeywords: TestOnly
Target Release: cfme-future   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1394941 1400341 (view as bug list) Environment:
Last Closed: 2017-01-13 00:07:54 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:
Bug Depends On:    
Bug Blocks: 1394941, 1400341    

Description Richard Su 2016-11-11 23:53:53 UTC
Description of problem:
Nodes cannot be powered on/off if its provision state is "active". Power on/off works if provision state is "manageable" or "available."

When state is "active", this error is logged if on/off is initiated.

==> evm.log <==
[----] E, [2016-11-11T15:39:39.233866 #3497:7b1998] ERROR -- : <Fog> excon.error     #<URI::InvalidComponentError: bad component(expected absolute path component): /nodes/b09df20a-f958-432c-8119-90ec9ebe1db9 (NovaCompute)/states/power>

In the UI, it indicates that power on or power off has been initiated but it is not actually carried out.

The problem doesn't appear to be in fog-openstack, as I could power on or off nodes using the library directly.

Version-Release number of selected component (if applicable):
ManageIQ master
OSP-10 release
fog-openstack 0.1.15

How reproducible:
always

Steps to Reproduce:
1. In ManageIQ, select a OpenStack node that is in "active" state.
2. Click the "Power On" or "Power Off" button in the "Power" menu bar.
3.

Actual results:
power operations fails

Expected results:
power operations succeed.

Comment 2 Richard Su 2016-11-12 00:57:12 UTC
The problem is name cannot be used as the uuid. Should use uid_ems.

Proposed fix: https://github.com/ManageIQ/manageiq/pull/12601

Comment 3 CFME Bot 2016-11-14 18:46:00 UTC
New commit detected on ManageIQ/manageiq/euwe:
https://github.com/ManageIQ/manageiq/commit/ee8d7afdf91071633a2741ea0276256331ed4389

commit ee8d7afdf91071633a2741ea0276256331ed4389
Author:     Adam Grare <agrare>
AuthorDate: Mon Nov 14 13:03:06 2016 -0500
Commit:     Oleg Barenboim <chessbyte>
CommitDate: Mon Nov 14 13:43:40 2016 -0500

    Merge pull request #12601 from rwsu/node-power-on-off-uid-fix
    
    Fix OpenStack node power operations
    (cherry picked from commit 762be2540fb6e8bb73f5f5b618becb5164652868)
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1394429

 .../manageiq/providers/openstack/infra_manager/host_operations_mixin.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comment 5 Richard Su 2017-01-13 00:07:54 UTC

*** This bug has been marked as a duplicate of bug 1394941 ***