commit aa87b9c288d316b85079e681e0df24354ec1912c
Author: Matt Riedemann <email address hidden>
Date: Tue Aug 21 15:32:13 2018 -0400
libvirt: check job status for VIR_DOMAIN_EVENT_SUSPENDED_MIGRATED event
Change Ic5cab99944df9e501ba2032eb96911c36304494d added handling for
the VIR_DOMAIN_EVENT_SUSPENDED_MIGRATED event during live migration
but failed to distinguish between the live migration actually succeeding
or failing before queueing the EVENT_LIFECYCLE_MIGRATION_COMPLETED
up into the ComputeManager.handle_lifecycle_event method.
As a result, failed live migrations will inadvertantly trigger
activation of the port bindings on the destination host, which
deactivates the source host port bindings, and then
_rollback_live_migration will delete those activated dest host port
bindings and leave the source host port bindings deactivated.
In this change, if we get the VIR_DOMAIN_EVENT_SUSPENDED_MIGRATED
event, we attempt to get the job status to determine the course to
take and only queue the EVENT_LIFECYCLE_MIGRATION_COMPLETED event,
which triggers the dest host port activation, if we can determine
the live migration job completed successfully. Otherwise we simply
report the guest as paused, the same as before Ic5cab9994.
Reviewed: https:/ /review. opendev. org/594527 /git.openstack. org/cgit/ openstack/ nova/commit/ ?id=aa87b9c288d 316b85079e681e0 df24354ec1912c
Committed: https:/
Submitter: Zuul
Branch: master
commit aa87b9c288d316b 85079e681e0df24 354ec1912c
Author: Matt Riedemann <email address hidden>
Date: Tue Aug 21 15:32:13 2018 -0400
libvirt: check job status for VIR_DOMAIN_ EVENT_SUSPENDED _MIGRATED event
Change Ic5cab99944df9e 501ba2032eb9691 1c36304494d added handling for EVENT_SUSPENDED _MIGRATED event during live migration _MIGRATION_ COMPLETED handle_ lifecycle_ event method.
the VIR_DOMAIN_
but failed to distinguish between the live migration actually succeeding
or failing before queueing the EVENT_LIFECYCLE
up into the ComputeManager.
As a result, failed live migrations will inadvertantly trigger live_migration will delete those activated dest host port
activation of the port bindings on the destination host, which
deactivates the source host port bindings, and then
_rollback_
bindings and leave the source host port bindings deactivated.
In this change, if we get the VIR_DOMAIN_ EVENT_SUSPENDED _MIGRATED _MIGRATION_ COMPLETED event,
event, we attempt to get the job status to determine the course to
take and only queue the EVENT_LIFECYCLE
which triggers the dest host port activation, if we can determine
the live migration job completed successfully. Otherwise we simply
report the guest as paused, the same as before Ic5cab9994.
Change-Id: I6a4252b0c12c41 c233299f30ce829 4fef21c7b40
Closes-Bug: #1788014