Bug 1225121 - Vmware VM retirement - undefined method `call_ws' for #<HostVmwareEsx:0xXXXXXXXXXXXXXX>
Summary: Vmware VM retirement - undefined method `call_ws' for #<HostVmwareEsx:0xXXXXX...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: Automate
Version: 5.4.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: GA
: 5.5.0
Assignee: Lucy Fu
QA Contact: Jan Krocil
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-05-26 15:43 UTC by Jan Krocil
Modified: 2019-11-14 06:44 UTC (History)
8 users (show)

Fixed In Version: 5.5.0.1
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-12-08 13:12:14 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2015:2551 0 normal SHIPPED_LIVE Moderate: CFME 5.5.0 bug fixes and enhancement update 2015-12-08 17:58:09 UTC

Comment 2 Joe Rafaniello 2015-05-26 15:59:31 UTC
Greg, can you take a look, of most importance:

We deleted call_ws here:
https://github.com/ManageIQ/manageiq/commit/681518f6adc8e519d60a1e9020c9e899ba5adfea#diff-28b9e9029f09539d88f5585b51ab42d7

Meanwhile, if we get to here, we're expecting the host to respond to this method:
https://github.com/ManageIQ/manageiq/blob/8f78e0e324f8e4a72218e4de45008590dbbd6bf6/vmdb/app/models/vm_or_template.rb#L349

In Jan's case, this is a new queue item:
MIQ(MiqQueue.get_via_drb) Message id: [1284505], MiqWorker id: [16882], Zone: [default], Role: [ems_operations], Server: [], Ident: [generic], Targe
t id: [], Instance id: [104], Task id: [], Command: [VmVmware.vm_destroy]

I see only the server smart proxy defining this method now:
https://github.com/ManageIQ/manageiq/blob/2eb001ff935d013a2b87b1c9941a0aa803c91e3e/vmdb/app/models/miq_server/server_smart_proxy.rb#L72

Comment 4 Greg McCullough 2015-05-26 16:24:56 UTC
Jan - It looks like the method run_command_via_parent does need some cleanup after the call_ws method was removed from the host model.  The call only gets to that point if the VM does not have a provider (orphaned or archived) or the status of the provider credentials are not valid for a VMware VM.

Looking at your test environment the provider for the specified VM has "Unreachable" listed for the default credentials.  If you are able to correct this the VM retirement should work.

Note: We still to fixup the run_command_via_parent so it does not call the call_ws method anymore.

Comment 8 CFME Bot 2015-06-08 17:51:01 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/d9485f81871289a467b69d65c00aabe3ef0f2a3c

commit d9485f81871289a467b69d65c00aabe3ef0f2a3c
Author:     Lucy Fu <lufu>
AuthorDate: Thu May 28 17:50:54 2015 -0400
Commit:     Lucy Fu <lufu>
CommitDate: Fri Jun 5 13:13:49 2015 -0400

    Remove methods used by miqhost.rb which is no longer a component.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1225121

 vmdb/app/models/host.rb | 191 ------------------------------------------------
 1 file changed, 191 deletions(-)

Comment 9 CFME Bot 2015-06-08 17:51:07 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/60fed87a1788e052609030d76c056f23c1cd2f7c

commit 60fed87a1788e052609030d76c056f23c1cd2f7c
Author:     Lucy Fu <lufu>
AuthorDate: Thu May 28 17:37:26 2015 -0400
Commit:     Lucy Fu <lufu>
CommitDate: Fri Jun 5 13:13:50 2015 -0400

    Cleanup method run_command_via_parent.
    
    Take the logic that works only for ScanMetadata and SyncMetadata out of run_command_via_parent
    and put them into methods for ScanMetadata and SyncMetadata handling.
    https://bugzilla.redhat.com/show_bug.cgi?id=1225121

 vmdb/app/models/vm_or_template.rb          | 46 ++++--------------------------
 vmdb/app/models/vm_or_template/scanning.rb | 24 +++++++++-------
 2 files changed, 20 insertions(+), 50 deletions(-)

Comment 11 errata-xmlrpc 2015-12-08 13:12:14 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/RHSA-2015:2551


Note You need to log in before you can comment on or make changes to this bug.