Skip to content
This repository was archived by the owner on Jun 25, 2026. It is now read-only.
This repository was archived by the owner on Jun 25, 2026. It is now read-only.

<AEMethod release_ip_address> Can not handle vmdb_object_type: vm_retire_task #148

Description

@sigbjornaib

An error occurs when attempting to retire vms. The error occur in https://github.com/RedHatOfficial/miq-Utilities/blob/master/Automate/RedHatConsulting_Utilities/Infrastructure/Network/Operations/Methods.class/__methods__/release_ip_address.rb

Line 98 logs the vmdb_object_type to be vm_retire_task. The case statement in line 99 does not have an option for vm_retire_task, and default to the error in the else statement at line 141, causing the retirement of the vm to fail.

Se below for log output from automation.log.

[----] I, [2019-03-11T20:47:21.019419 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) <AEMethod [/ManageIQ/Infrastructure/VM/Retirement/StateMachines/VMRetirement/update_retirement_status]> Ending
[----] I, [2019-03-11T20:47:21.019538 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Method exited with rc=MIQ_OK
[----] I, [2019-03-11T20:47:21.019858 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Processing State=[ReleaseIPAddress]
[----] I, [2019-03-11T20:47:21.020026 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Following Relationship [miqaedb:/Infrastructure/Network/Operations/Methods/ReleaseIPAddress#create]
[----] I, [2019-03-11T20:47:21.482404 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Updated namespace [miqaedb:/Infrastructure/Network/Operations/Methods/ReleaseIPAddress#create Example_Override/Infrastructure/Network/Operations]
[----] I, [2019-03-11T20:47:21.895110 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Updated namespace [Infrastructure/Network/Operations/Methods/release_ip_address Example_Override/Infrastructure/Network/Operations]
[----] I, [2019-03-11T20:47:21.900738 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Invoking [inline] method [/Example_Override/Infrastructure/Network/Operations/Methods/release_ip_address] with inputs [{}]
[----] I, [2019-03-11T20:47:21.901686 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) <AEMethod [/Example_Override/Infrastructure/Network/Operations/Methods/release_ip_address]> Starting
[----] I, [2019-03-11T20:47:22.243566 #19088:12533b0] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) $evm.root['vmdb_object_type'] => 'vm_retire_task'.
[----] E, [2019-03-11T20:47:22.245193 #19088:12533b0] ERROR -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Can not handle vmdb_object_type: vm_retire_task
[----] I, [2019-03-11T20:47:22.267972 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) <AEMethod [/Example_Override/Infrastructure/Network/Operations/Methods/release_ip_address]> Ending
[----] I, [2019-03-11T20:47:22.268343 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Stopping instantiation because [Method exited with rc=MIQ_STOP]
[----] I, [2019-03-11T20:47:22.268511 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Followed Relationship [miqaedb:/Infrastructure/Network/Operations/Methods/ReleaseIPAddress#create]
[----] I, [2019-03-11T20:47:22.268584 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Processed State=[ReleaseIPAddress] with Result=[error]
[----] W, [2019-03-11T20:47:22.268675 #19088:1160f5c] WARN -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Error in State=[ReleaseIPAddress]
[----] I, [2019-03-11T20:47:22.268776 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) In State=[ReleaseIPAddress], invoking [on_error] method=[update_retirement_status(status => 'Error Releasing IP Address')]
[----] I, [2019-03-11T20:47:23.936432 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Updated namespace [Infrastructure/VM/Retirement/StateMachines/VMRetirement/update_retirement_status ManageIQ/Infrastructure/VM/Retirement/StateMachines]
[----] I, [2019-03-11T20:47:24.090002 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) Invoking [inline] method [/ManageIQ/Infrastructure/VM/Retirement/StateMachines/VMRetirement/update_retirement_status] with inputs [{"status"=>"Error Releasing IP Address"}]
[----] I, [2019-03-11T20:47:24.090912 #19088:1160f5c] INFO -- : Q-task_id([r1000000000387_vm_retire_task_1000000000509]) <AEMethod [/ManageIQ/Infrastructure/VM/Retirement/StateMachines/VMRetirement/update_retirement_status]> Starting
[----] I, [2019-03-11T20:47:24.527413 #19088:126d92c] INFO -- : Validating Notification type: automate_user_error

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions