Description of problem: Retiring microsoft svcmm vm destroy ends in error. Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. provision svcmm vm 2. retire vm 3. error in evm.log Actual results: vm not destroy/removed Expected results: vm destroy/removed Additional info[----] I, [2016-01-15T15:09:29.119805 #13384:ddd998] INFO -- : <AutomationEngine> Followed Relationship [miqaedb:/System/Event/MiqEvent/POLICY/request_vm_destroy#create] [----] I, [2016-01-15T15:09:29.120577 #13384:ddd998] INFO -- : MIQ(MiqQueue#delivered) Message id: [196933], State: [ok], Delivered in [0.451096201] seconds [----] I, [2016-01-15T15:09:29.202213 #13384:ddd998] INFO -- : MIQ(MiqQueue#m_callback) Message id: [196933], Invoking Callback with args: [:raw_destroy, "ok", "Message delivered successfully", "#<MiqAeEngine::MiqAeWorkspaceRuntime:0x000000060cd5e0 @readonly=false, @nodes=[#<MiqAeEngine::MiqAeObject:0x00000005ffac80 @workspace=#<MiqAeEngine::MiqAeWorkspaceRuntime:0x000000060cd5e0 ...>, @namespace=\"ManageIQ2/System\", @klass=\"Process\", @instance=\"Event\", @attributes={\"event_stream_id\"=>\"45673\", \"event_type\"=>\"request_vm_destroy\", \"ext_management_system\"=>\"5\", \"host_id\"=>\"3\", \"miq_event_id\"=>\"45673\", \"object_name\"=>\"Event\", \"vm_id\"=>\"1364\", \"vmdb_object_type\"=>\"vm\", \"event_stream\"=>#<MiqAe..."] [----] I, [2016-01-15T15:09:29.206285 #13384:ddd998] INFO -- : MIQ(ManageIQ::Providers::Microsoft::InfraManager::Vm#run_command_via_parent) Invoking [vm_destroy] through EMS: [billy_mscvmm] [----] E, [2016-01-15T15:09:29.207567 #13384:ddd998] ERROR -- : MIQ(MiqQueue#m_callback) Message id: [196933]: undefined method `vm_destroy' for #<ManageIQ::Providers::Microsoft::InfraManager:0x000000032d3950> [----] E, [2016-01-15T15:09:29.207664 #13384:ddd998] ERROR -- : MIQ(MiqQueue#m_callback) backtrace: /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/activemodel-4.2.5/lib/active_model/attribute_methods.rb:433:in `method_missing' /var/www/miq/vmdb/app/models/vm_or_template.rb:329:in `run_command_via_parent' /var/www/miq/vmdb/app/models/vm_or_template/operations.rb:54:in `raw_destroy' /var/www/miq/vmdb/app/models/vm_or_template.rb:353:in `check_policy_prevent_callback' /var/www/miq/vmdb/app/models/miq_queue.rb:404:in `m_callback' /var/www/miq/vmdb/app/models/miq_queue.rb:373:in `delivered' /var/www/miq/vmdb/app/models/miq_queue_worker_base/runner.rb:117:in `deliver_queue_message' /var/www/miq/vmdb/app/models/miq_queue_worker_base/runner.rb:134:in `deliver_message' /var/www/miq/vmdb/app/models/miq_queue_worker_base/runner.rb:151:in `block in do_work' /var/www/miq/vmdb/app/models/miq_queue_worker_base/runner.rb:145:in `loop' /var/www/miq/vmdb/app/models/miq_queue_worker_base/runner.rb:145:in `do_work' /var/www/miq/vmdb/app/models/miq_worker/runner.rb:335:in `block in do_work_loop' /var/www/miq/vmdb/app/models/miq_worker/runner.rb:332:in `loop' /var/www/miq/vmdb/app/models/miq_worker/runner.rb:332:in `do_work_loop' /var/www/miq/vmdb/app/models/miq_worker/runner.rb:154:in `run' /var/www/miq/vmdb/app/models/miq_worker/runner.rb:129:in `start' /var/www/miq/vmdb/app/models/miq_worker/runner.rb:29:in `start_worker' /var/www/miq/vmdb/lib/workers/bin/worker.rb:2:in `<top (required)>' /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/railties-4.2.5/lib/rails/commands/runner.rb:60:in `load' /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/railties-4.2.5/lib/rails/commands/runner.rb:60:in `<top (required)>' /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/railties-4.2.5/lib/rails/commands/commands_tasks.rb:123:in `require' /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/railties-4.2.5/lib/rails/commands/commands_tasks.rb:123:in `require_command!' /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/railties-4.2.5/lib/rails/commands/commands_tasks.rb:90:in `runner' /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/railties-4.2.5/lib/rails/commands/commands_tasks.rb:39:in `run_command!' /opt/rubies/ruby-2.2.4/lib/ruby/gems/2.2.0/gems/railties-4.2.5/lib/rails/commands.rb:17:in `<top (required)>' /var/www/miq/vmdb/bin/rails:4:in `require' /var/www/miq/vmdb/bin/rails:4:in `<main>'
Vm_destroy is an existing method that is called from automate remove_from_disk
You can find more information in BZ: https://bugzilla.redhat.com/show_bug.cgi?id=1297351
https://github.com/ManageIQ/manageiq/pull/6306
New commit detected on ManageIQ/manageiq/master: https://github.com/ManageIQ/manageiq/commit/9768c089c7a5d0b43820ff7fe095a330bf2f967e commit 9768c089c7a5d0b43820ff7fe095a330bf2f967e Author: Bronagh Sorota <bsorota> AuthorDate: Fri Jan 22 14:34:40 2016 -0500 Commit: Bronagh Sorota <bsorota> CommitDate: Fri Jan 22 14:34:40 2016 -0500 Implementation of the vm_destroy method required for SCVMM VM retirement https://bugzilla.redhat.com/show_bug.cgi?id=1299069 https://bugzilla.redhat.com/show_bug.cgi?id=1299071 app/models/manageiq/providers/microsoft/infra_manager.rb | 7 +++++++ 1 file changed, 7 insertions(+)
This is working much better. Thanks for the extra changes. Moving to verified.
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-2016:1348