Fedora Account System
Red Hat Associate
Red Hat Customer
Description of problem: An amazon instance can be running either in an "ebs" store or an "instance" store. Only ebs instances are stopped, the instance store instances can be just terminated. The amazon_check_pre_retirement method has a typo it uses "instance_store" instead of "instance-store". This typo causes the script to be stuck in a retry loop preventing the retirement from progressing. Version-Release number of selected component (if applicable): 5.5 How reproducible: Very Steps to Reproduce: 1. Provision an Amazon instance on an instance store 2. Retire the VM 3. Actual results: The script gets stuck in the retry loop for instance-store backed amazon instances Expected results: The script should continue with the retirement Additional info:
https://github.com/ManageIQ/manageiq/pull/9673
https://github.com/ManageIQ/manageiq/pull/9675
New commit detected on ManageIQ/manageiq/master: https://github.com/ManageIQ/manageiq/commit/3975f927d53382dbda640ef96e2b0bb711f3f64e commit 3975f927d53382dbda640ef96e2b0bb711f3f64e Author: Madhu Kanoor <mkanoor> AuthorDate: Thu Jul 7 17:45:15 2016 -0400 Commit: Madhu Kanoor <mkanoor> CommitDate: Thu Jul 7 17:45:15 2016 -0400 Fixed root_device_type typo https://bugzilla.redhat.com/show_bug.cgi?id=1353632 Should be checking for instance-store and not instance_store .../Methods.class/__methods__/amazon_check_pre_retirement.rb | 2 +- spec/automation/unit/method_validation/amazon_pre_retirement_spec.rb | 2 +- .../unit/method_validation/check_amazon_pre_retirement_spec.rb | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
Created attachment 1225778 [details] bug
Kyrylo, Can I have access to your appliance ? I tried to re-create but it works for me. Thanks Billy
Please assess the impact of this issue and update the severity accordingly. Please refer to https://bugzilla.redhat.com/page.cgi?id=fields.html#bug_severity for a reminder on each severity's definition.
This is a high priority issue. There were 2 main issues uncovered (1) There was a typo in the Automate Method which was causing the retry loop (2) When an instance is provisioned outside of CFME we were not able to retire it. Marcel Hild had updated the Amazon gem to record the instance_types of EC2 instances provided outside CFME.
can you please check if you have set the lifecycle tags for the instance provisioned outside of CFME. Details in https://bugzilla.redhat.com/show_bug.cgi?id=1372772
Matous, with a little guidance from Milan, please retest this
Hi Matous, Are you able to reproduce this issue? Thanks, Tina
Can't reproduce neither on 5.6.3.3 nor on 5.7.0.17. Instance-store images were terminated after I tried to retire them.
The problem is with retirement or stop? I just reproduced steps which Kyrylo wrote here and I can retire it, but I can't stop it. Only terminate/retire works. As I can read in description of problem the problem is with stopping instance... When I stop instance I get this error: [----] E, [2017-01-26T04:01:56.996987 #11914:88d13c] ERROR -- : MIQ(MiqQueue#m_callback) Message id: [16520]: The instance 'i-0be3b54350b54c91d' does not have an 'ebs' root device type and cannot be stopped.
Hi Matous, I think one of the things you might want to try is provision instances directly in EC2 console instead of using our provisioning. Then try to retire it. If you want to retire instances provisioned outside of CFME, it is necessary that they have the lifecycle tag https://bugzilla.redhat.com/show_bug.cgi?id=1372772 Thanks, Madhu
I tried it and it also works. So I can set it to verified then?
Yes please
Verified in 5.7.1.0. Instance-store instance is retired correctly.