[FakeDriver] Live migration issue, power_state=NOSTATE
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
| OpenStack Compute (nova) |
Low
|
Stephen Finucane |
Bug Description
[nova master]
In FakeDrivers, when live-migrating an instance everything goes ok.
So, resources are allocated the correct way and instance's host has been changed, but instance Power State goes to NOSTATE.
This seems to be caused by get_info method which programmatically raises InstanceNotFound exception.
Instances list inside FakeDriver seems not to be updated accordingly.
I actually fixed the problem in my local code (nova.virt.
def live_migration(
++ name = instance['name']
++ del self.instances[
return
and
def post_live_
++ name = instance['name']
++ state = power_state.RUNNING
++ fake_instance = FakeInstance(name, state, instance['uuid'])
++ self.instances[
But I don't know if it is a satisfying solution.
With this solution the instance is live_migrated and in state ACTIVE and power state RUNNING after the operation.
Thank you
description: | updated |
description: | updated |
Davanum Srinivas (DIMS) (dims-v) wrote : | #1 |
Lorenzo Affetti (affox90) wrote : | #2 |
O yes, I think I will do it asap.
I think that my solution is a nitty gritty one and i hoped to find experts to write a more suitable code!
I have never bugfixed something.
I will try with pleasure.
Changed in nova: | |
status: | New → Confirmed |
tags: | added: low-hanging-fruit |
Changed in nova: | |
importance: | Undecided → Low |
Changed in nova: | |
assignee: | nobody → Lorenzo Affetti (affox90) |
Andrea Rosa (andrea-rosa-m) wrote : | #3 |
@Lorenzo are you still working on this bug? If not please change the assignee from you to 'nobody'
Lorenzo Affetti (affox90) wrote : | #4 |
@Andrea thank you for waking me up! I want to fix this in next weeks.
Fix proposed to branch: master
Review: https:/
Changed in nova: | |
status: | Confirmed → In Progress |
Changed in nova: | |
assignee: | Lorenzo Affetti (affox90) → Stephen Finucane (sfinucan) |
Anup (anup-d-navare) wrote : | #6 |
Is this bug fixed?
The age of this report and number of assignee changes suggest that this
isn't really a low-hanging-fruit. I'm removing the tag to not confuse
new folks who are searching for that tag.
tags: |
added: testing removed: low-hanging-fruit |
Change abandoned by Michael Still (<email address hidden>) on branch: master
Review: https:/
Reason: This patch is quite old, so I am abandoning it to keep the review queue manageable. Feel free to restore the change if you're still interested in working on it.
Changed in nova: | |
assignee: | Stephen Finucane (stephenfinucane) → nobody |
Changed in nova: | |
status: | In Progress → Confirmed |
Matt Riedemann (mriedem) wrote : | #9 |
I think this might be resolved in a few forms now:
https:/
https:/
https:/
If not, I had to do something similar for cold migration testing across different hosts:
https:/
Changed in nova: | |
assignee: | nobody → Matt Riedemann (mriedem) |
status: | Confirmed → In Progress |
Changed in nova: | |
assignee: | Matt Riedemann (mriedem) → Lorenzo Affetti (affox90) |
Changed in nova: | |
assignee: | Lorenzo Affetti (affox90) → Matt Riedemann (mriedem) |
Changed in nova: | |
assignee: | Matt Riedemann (mriedem) → Lorenzo Affetti (affox90) |
Changed in nova: | |
assignee: | Lorenzo Affetti (affox90) → Stephen Finucane (stephenfinucane) |
Reviewed: https:/
Committed: https:/
Submitter: Zuul
Branch: master
commit 14342d629b714f1
Author: Lorenzo Affetti <email address hidden>
Date: Tue Nov 10 12:56:59 2015 +0100
FakeDriver: adding and removing instances on live migration.
There was no code in FakeDriver that updated the internal
dict `self.instances` when a FakeInstance was live migrated.
This commit fills this gap. As a result, a couple of versioned
notification samples get updated since we are now properly
tracking a live migrated instance on the destination host as
running vs pending power state.
Closes-Bug: 1426433
Change-Id: I9562e1bcbb18c7
Changed in nova: | |
status: | In Progress → Fix Released |
Lorenzo, will you be filing a review? /wiki.openstack .org/wiki/ How_To_ Contribute
https:/