[Libvirt]Evacuate fail may cause disk image be deleted

Bug #1550919 reported by leehom on 2016-02-28
88
This bug affects 16 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Medium
Lee Yarwood
Queens
Medium
Lee Yarwood
Rocky
Medium
Lee Yarwood
Stein
Medium
Lee Yarwood
Train
Medium
Lee Yarwood
Ussuri
Medium
Lee Yarwood

Bug Description

I checked latest source of nova on master branch, this problem is still exists.

When we are doing evacuate, eventually _do_rebuild_instance will be called.
As rebuild is not implemented in libvirt driver, in fact _rebuild_default_impl is called.

        try:
            with instance.mutated_migration_context():
                self.driver.rebuild(**kwargs)
        except NotImplementedError:
            # NOTE(rpodolyaka): driver doesn't provide specialized version
            # of rebuild, fall back to the default implementation
            self._rebuild_default_impl(**kwargs)

_rebuild_default_impl will call self.driver.spawn to boot up the instance, and spawn will in turn call _create_domain_and_network
when VirtualInterfaceCreateException or Timeout happen, self.cleanup will be called.

        except exception.VirtualInterfaceCreateException:
            # Neutron reported failure and we didn't swallow it, so
            # bail here
            with excutils.save_and_reraise_exception():
                if guest:
                    guest.poweroff()
                self.cleanup(context, instance, network_info=network_info,
                             block_device_info=block_device_info)
        except eventlet.timeout.Timeout:
            # We never heard from Neutron
            LOG.warn(_LW('Timeout waiting for vif plugging callback for '
                         'instance %(uuid)s'), {'uuid': instance.uuid},
                     instance=instance)
            if CONF.vif_plugging_is_fatal:
                if guest:
                    guest.poweroff()
                self.cleanup(context, instance, network_info=network_info,
                             block_device_info=block_device_info)
                raise exception.VirtualInterfaceCreateException()

Because default value for parameter destroy_disks is True
    def cleanup(self, context, instance, network_info, block_device_info=None,
                destroy_disks=True, migrate_data=None, destroy_vifs=True):

So if error occur when doing evacuate during wait neutron's event, instance's disk file will be deleted unexpectedly

leehom (feli5) on 2016-02-28
Changed in nova:
assignee: nobody → leehom (feli5)
Matt Riedemann (mriedem) on 2016-03-03
tags: added: evacuate libvirt rebuild
Changed in nova:
status: New → Triaged
importance: Undecided → Medium
Matt Riedemann (mriedem) wrote :

Are you using shared storage or local disks? In the case of evacuate/rebuild, we're completely rebuilding the instance from the old image ref, flavor, network information and attached volumes (if any). So I'm not sure there is any guarantee (or point) that if nova fails to spawn the rebuilt instance it should keep the disk it created as part of the rebuild.

tags: added: compute
Changed in nova:
status: Triaged → Incomplete
Matt Riedemann (mriedem) wrote :

In fact, there is a preserve_ephemeral flag passed to the _rebuild_default_impl method and if that's true the rebuild fails because rebuild by design can't rebuild ephemeral storage, it's presumably gone and that's why you're rebuilding the instance on another host (in the case of evacuate).

Fix proposed to branch: master
Review: https://review.openstack.org/288109

Changed in nova:
assignee: leehom (feli5) → Matt Riedemann (mriedem)
status: Incomplete → In Progress
Matt Riedemann (mriedem) wrote :

I've posted a patch here: https://review.openstack.org/#/c/288109/

Please let me know if that resolves your issue (it assumes you have disks on shared storage).

leehom (feli5) wrote :

I'm using shared storage. And I will do the verify.

Matt Riedemann (mriedem) wrote :

Can you be more specific? Shared storage with Ceph, NFS, GlusterFS, other?

leehom (feli5) wrote :

Hi Matt.

It's NFS.

Change abandoned by Matt Riedemann (<email address hidden>) on branch: master
Review: https://review.openstack.org/288109

Matt Riedemann (mriedem) on 2016-05-13
Changed in nova:
assignee: Matt Riedemann (mriedem) → nobody
status: In Progress → New

Solving inconsistency: changing bug status from "New" to "Confirmed" as it has assignee.

Changed in nova:
status: New → Confirmed
Shunli Zhou (shunliz) wrote :

Disk image be deleted on ceph also, I tested on ceph

Fix proposed to branch: master
Review: https://review.openstack.org/578846

Changed in nova:
assignee: nobody → Matthew Booth (mbooth-9)
status: Confirmed → In Progress

Related fix proposed to branch: master
Review: https://review.openstack.org/602174

Related fix proposed to branch: master
Review: https://review.openstack.org/604400

Reviewed: https://review.openstack.org/591733
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=bbe88786fc90c2106f9fae0156ee7b09ece9a83b
Submitter: Zuul
Branch: master

commit bbe88786fc90c2106f9fae0156ee7b09ece9a83b
Author: Matthew Booth <email address hidden>
Date: Tue Aug 14 16:05:11 2018 +0100

    Add regression test for bug 1550919

    This adds a failing test, which we fix in change I76448196.

    Related-Bug: #1550919
    Change-Id: I5619728d5bd684e9167495dd4550ee4f5fbb87a7

Change abandoned by Matt Riedemann (<email address hidden>) on branch: master
Review: https://review.opendev.org/604400

Changed in nova:
assignee: Matthew Booth (mbooth-9) → Lee Yarwood (lyarwood)

Reviewed: https://review.opendev.org/631294
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=90e0e874bde38937380d09ab27a7defbb5475cc2
Submitter: Zuul
Branch: master

commit 90e0e874bde38937380d09ab27a7defbb5475cc2
Author: Matthew Booth <email address hidden>
Date: Tue Aug 14 16:05:11 2018 +0100

    Add functional test for bug 1550919

    This adds a failing test, which we fix in change I76448196.

    An earlier version of this change was previously merged as
    change I5619728d. This was later reverted, as it was failing in the
    gate. However, on inspection these failures seem to have been simply
    timeouts due to load.

    Changes from previous version:

    - Increase the timeouts which were previously triggering, and
      serialise server creation to reduce the chance of this recurring.
    - Add an LVM test, which highlights the requirement to flag the
      creation of ephemeral and swap disks.
    - Add an Qcow2 test, essentially the same as the Flat test but ensures
      coverage of the most common backends.
    - Each test now uses a separate instances_path allowing for cleanup
      without racing against other active tests.
    - Some nits addressed.

    For the time being this test does not make use of the recently improved
    nova.tests.functional.libvirt.base.ServersTestBase class to ease
    backports. Future changes should be made to use this class removing some
    of the common setUp logic from _LibvirtEvacuateTest.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Related-Bug: #1550919
    Change-Id: I1062b3e74382734edbb2142a09ff0073c66af8db

Changed in nova:
status: In Progress → Fix Released

Reviewed: https://review.opendev.org/578846
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=497360b0ea970f1e68912be8229ef8c3f5454e9e
Submitter: Zuul
Branch: master

commit 497360b0ea970f1e68912be8229ef8c3f5454e9e
Author: Matthew Booth <email address hidden>
Date: Wed Aug 15 14:39:48 2018 +0100

    libvirt: Don't delete disks on shared storage during evacuate

    When evacuating an instance between compute hosts on shared storage,
    during the rebuild operation we call spawn() on the destination
    compute. spawn() currently assumes that it should cleanup all
    resources on failure, which results in user data being deleted in the
    evacuate case.

    This change modifies spawn in the libvirt driver such that it only
    cleans up resources it created.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Closes-Bug: #1550919
    Change-Id: I764481966c96a67d993da6e902dc9fc3ad29ee36
    (cherry picked from commit 083df01a4d90e155c1b4ef9e954d8be14a02d830)

Reviewed: https://review.opendev.org/731247
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=6ccd13f8aeeb97c2139c1abc93cb976fd57d57dd
Submitter: Zuul
Branch: stable/ussuri

commit 6ccd13f8aeeb97c2139c1abc93cb976fd57d57dd
Author: Matthew Booth <email address hidden>
Date: Tue Aug 14 16:05:11 2018 +0100

    Add functional test for bug 1550919

    This adds a failing test, which we fix in change I76448196.

    An earlier version of this change was previously merged as
    change I5619728d. This was later reverted, as it was failing in the
    gate. However, on inspection these failures seem to have been simply
    timeouts due to load.

    Changes from previous version:

    - Increase the timeouts which were previously triggering, and
      serialise server creation to reduce the chance of this recurring.
    - Add an LVM test, which highlights the requirement to flag the
      creation of ephemeral and swap disks.
    - Add an Qcow2 test, essentially the same as the Flat test but ensures
      coverage of the most common backends.
    - Each test now uses a separate instances_path allowing for cleanup
      without racing against other active tests.
    - Some nits addressed.

    For the time being this test does not make use of the recently improved
    nova.tests.functional.libvirt.base.ServersTestBase class to ease
    backports. Future changes should be made to use this class removing some
    of the common setUp logic from _LibvirtEvacuateTest.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Related-Bug: #1550919
    Change-Id: I1062b3e74382734edbb2142a09ff0073c66af8db
    (cherry picked from commit 90e0e874bde38937380d09ab27a7defbb5475cc2)

tags: added: in-stable-ussuri

Reviewed: https://review.opendev.org/731248
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=8b48ca672d9c0eb108c71b7f9f3f089d9ecf688a
Submitter: Zuul
Branch: stable/ussuri

commit 8b48ca672d9c0eb108c71b7f9f3f089d9ecf688a
Author: Matthew Booth <email address hidden>
Date: Wed Aug 15 14:39:48 2018 +0100

    libvirt: Don't delete disks on shared storage during evacuate

    When evacuating an instance between compute hosts on shared storage,
    during the rebuild operation we call spawn() on the destination
    compute. spawn() currently assumes that it should cleanup all
    resources on failure, which results in user data being deleted in the
    evacuate case.

    This change modifies spawn in the libvirt driver such that it only
    cleans up resources it created.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Closes-Bug: #1550919
    Change-Id: I764481966c96a67d993da6e902dc9fc3ad29ee36
    (cherry picked from commit 497360b0ea970f1e68912be8229ef8c3f5454e9e)

Reviewed: https://review.opendev.org/731272
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=172eb21dee1d93b140c2b691cb8dfbc68b721bfe
Submitter: Zuul
Branch: stable/train

commit 172eb21dee1d93b140c2b691cb8dfbc68b721bfe
Author: Matthew Booth <email address hidden>
Date: Tue Aug 14 16:05:11 2018 +0100

    Add functional test for bug 1550919

    This adds a failing test, which we fix in change I76448196.

    An earlier version of this change was previously merged as
    change I5619728d. This was later reverted, as it was failing in the
    gate. However, on inspection these failures seem to have been simply
    timeouts due to load.

    Changes from previous version:

    - Increase the timeouts which were previously triggering, and
      serialise server creation to reduce the chance of this recurring.
    - Add an LVM test, which highlights the requirement to flag the
      creation of ephemeral and swap disks.
    - Add an Qcow2 test, essentially the same as the Flat test but ensures
      coverage of the most common backends.
    - Each test now uses a separate instances_path allowing for cleanup
      without racing against other active tests.
    - Some nits addressed.

    For the time being this test does not make use of the recently improved
    nova.tests.functional.libvirt.base.ServersTestBase class to ease
    backports. Future changes should be made to use this class removing some
    of the common setUp logic from _LibvirtEvacuateTest.

    NOTE(lyarwood): Calls to _wait_for_state_change and
    _wait_for_server_parameter now provide self.api as required prior to
    I8c96b337f32148f8f5899c9b87af331b1fa41424 landing in Ussuri.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Related-Bug: #1550919
    Change-Id: I1062b3e74382734edbb2142a09ff0073c66af8db
    (cherry picked from commit 90e0e874bde38937380d09ab27a7defbb5475cc2)
    (cherry picked from commit 6ccd13f8aeeb97c2139c1abc93cb976fd57d57dd)

tags: added: in-stable-train

Reviewed: https://review.opendev.org/731273
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=1a320f2a0e0918de6afcce5cf23b7de178ec3a49
Submitter: Zuul
Branch: stable/train

commit 1a320f2a0e0918de6afcce5cf23b7de178ec3a49
Author: Matthew Booth <email address hidden>
Date: Wed Aug 15 14:39:48 2018 +0100

    libvirt: Don't delete disks on shared storage during evacuate

    When evacuating an instance between compute hosts on shared storage,
    during the rebuild operation we call spawn() on the destination
    compute. spawn() currently assumes that it should cleanup all
    resources on failure, which results in user data being deleted in the
    evacuate case.

    This change modifies spawn in the libvirt driver such that it only
    cleans up resources it created.

    Conflicts:
        nova/tests/unit/virt/libvirt/test_driver.py

    NOTE(lyarwood): Conflicts due to I08cd4787ab4c9539574237e26ba5bf6d4246b32e
    and I5a9e5532c46a5f7064441ae644125d21efe5fda1 not being present in
    stable/train.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Closes-Bug: #1550919
    Change-Id: I764481966c96a67d993da6e902dc9fc3ad29ee36
    (cherry picked from commit 497360b0ea970f1e68912be8229ef8c3f5454e9e)
    (cherry picked from commit 8b48ca672d9c0eb108c71b7f9f3f089d9ecf688a)

Reviewed: https://review.opendev.org/732695
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=d7a1cb57247c4b1faa09b9c81c5cd2fbd4639095
Submitter: Zuul
Branch: stable/stein

commit d7a1cb57247c4b1faa09b9c81c5cd2fbd4639095
Author: Matthew Booth <email address hidden>
Date: Tue Aug 14 16:05:11 2018 +0100

    Add functional test for bug 1550919

    This adds a failing test, which we fix in change I76448196.

    An earlier version of this change was previously merged as
    change I5619728d. This was later reverted, as it was failing in the
    gate. However, on inspection these failures seem to have been simply
    timeouts due to load.

    Changes from previous version:

    - Increase the timeouts which were previously triggering, and
      serialise server creation to reduce the chance of this recurring.
    - Add an LVM test, which highlights the requirement to flag the
      creation of ephemeral and swap disks.
    - Add an Qcow2 test, essentially the same as the Flat test but ensures
      coverage of the most common backends.
    - Each test now uses a separate instances_path allowing for cleanup
      without racing against other active tests.
    - Some nits addressed.

    For the time being this test does not make use of the recently improved
    nova.tests.functional.libvirt.base.ServersTestBase class to ease
    backports. Future changes should be made to use this class removing some
    of the common setUp logic from _LibvirtEvacuateTest.

    NOTE(lyarwood): The following changes are required for stable/stein:

    * [libvirt]/rbd_user is now set within LibvirtRbdEvacuateTest due to
      I361af845d6a733618ecd056aa7df973191184ae9 not being present.

    * CinderFixtureNewAttachFlow is used by all tests due to
      I6a777b4b7a5729488f939df8c40e49bd40aec3dd not being present.

    * _get_vcpu_total is used instead of _get_vcpu_available due to
      I98efdc61fd456fc7f9e1a85238c9ef9bc04a1252 not being present.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Related-Bug: #1550919
    Change-Id: I1062b3e74382734edbb2142a09ff0073c66af8db
    (cherry picked from commit 90e0e874bde38937380d09ab27a7defbb5475cc2)
    (cherry picked from commit 6ccd13f8aeeb97c2139c1abc93cb976fd57d57dd)
    (cherry picked from commit 172eb21dee1d93b140c2b691cb8dfbc68b721bfe)

tags: added: in-stable-stein

Reviewed: https://review.opendev.org/732696
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=a7d8aa699793e1d60ece4e03920e6041337f9a43
Submitter: Zuul
Branch: stable/stein

commit a7d8aa699793e1d60ece4e03920e6041337f9a43
Author: Matthew Booth <email address hidden>
Date: Wed Aug 15 14:39:48 2018 +0100

    libvirt: Don't delete disks on shared storage during evacuate

    When evacuating an instance between compute hosts on shared storage,
    during the rebuild operation we call spawn() on the destination
    compute. spawn() currently assumes that it should cleanup all
    resources on failure, which results in user data being deleted in the
    evacuate case.

    This change modifies spawn in the libvirt driver such that it only
    cleans up resources it created.

    Conflicts:
        nova/tests/functional/libvirt/base.py
        nova/tests/functional/regressions/test_bug_1595962.py
        nova/virt/libvirt/driver.py

    Changes:
        nova/tests/functional/libvirt/test_pci_sriov_servers.py

    NOTE(lyarwood): Conflicts on stable/stein due to the following:

    - nova/tests/functional/libvirt/base.py
      Due to I5895865751e8e1fb08b3515bc9f8119cfcb9f35e not being present
      on stable/stein.

    - nova/tests/functional/regressions/test_bug_1595962.py
      Due to I8e5a122cc547222249973cf595d90c2d8d5658d4 not being present
      on stable/stein.

    - nova/virt/libvirt/driver.py
      Due to I725deb0312c930087c9e60115abe68b4e06e6804 and
      I6929c588dd2e0e805f2e30b2e30d29967469d756 not being present on
      stable/stein.

    NOTE(lyarwood): Changes on stable/stein due to
    I5895865751e8e1fb08b3515bc9f8119cfcb9f35e ("libvirt: Mock libvirt'y
    things in setUp") not being present on stable/stein.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Closes-Bug: #1550919
    Change-Id: I764481966c96a67d993da6e902dc9fc3ad29ee36
    (cherry picked from commit 497360b0ea970f1e68912be8229ef8c3f5454e9e)
    (cherry picked from commit 8b48ca672d9c0eb108c71b7f9f3f089d9ecf688a)
    (cherry picked from commit 1a320f2a0e0918de6afcce5cf23b7de178ec3a49)

Reviewed: https://review.opendev.org/732707
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=6118101cbae56e80a22a35a5ffcb07a0ed259b99
Submitter: Zuul
Branch: stable/rocky

commit 6118101cbae56e80a22a35a5ffcb07a0ed259b99
Author: Matthew Booth <email address hidden>
Date: Tue Aug 14 16:05:11 2018 +0100

    Add functional test for bug 1550919

    This adds a failing test, which we fix in change I76448196.

    An earlier version of this change was previously merged as
    change I5619728d. This was later reverted, as it was failing in the
    gate. However, on inspection these failures seem to have been simply
    timeouts due to load.

    Changes from previous version:

    - Increase the timeouts which were previously triggering, and
      serialise server creation to reduce the chance of this recurring.
    - Add an LVM test, which highlights the requirement to flag the
      creation of ephemeral and swap disks.
    - Add an Qcow2 test, essentially the same as the Flat test but ensures
      coverage of the most common backends.
    - Each test now uses a separate instances_path allowing for cleanup
      without racing against other active tests.
    - Some nits addressed.

    For the time being this test does not make use of the recently improved
    nova.tests.functional.libvirt.base.ServersTestBase class to ease
    backports. Future changes should be made to use this class removing some
    of the common setUp logic from _LibvirtEvacuateTest.

    NOTE(lyarwood): The following changes are required for stable/rocky:

    * uuidsentinel is imported from nova.tests as we don't have access to
      oslo.utils 3.37.0 that introduced uuidsentinel as used by
      I7f5f08691ca3f73073c66c29dddb996fb2c2b266 in openstack/nova during
      stable/stein.

    * Use nova.tests.fixtures.PlacementFixture due to
      Idaed39629095f86d24a54334c699a26c218c6593 not being present in
      stable/rocky.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Related-Bug: #1550919
    Change-Id: I1062b3e74382734edbb2142a09ff0073c66af8db
    (cherry picked from commit 90e0e874bde38937380d09ab27a7defbb5475cc2)
    (cherry picked from commit 6ccd13f8aeeb97c2139c1abc93cb976fd57d57dd)
    (cherry picked from commit 172eb21dee1d93b140c2b691cb8dfbc68b721bfe)
    (cherry picked from commit d7a1cb57247c4b1faa09b9c81c5cd2fbd4639095)

tags: added: in-stable-rocky

Reviewed: https://review.opendev.org/732708
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=ae7602c1206de23439d6c3609b5872831138aa99
Submitter: Zuul
Branch: stable/rocky

commit ae7602c1206de23439d6c3609b5872831138aa99
Author: Matthew Booth <email address hidden>
Date: Wed Aug 15 14:39:48 2018 +0100

    libvirt: Don't delete disks on shared storage during evacuate

    When evacuating an instance between compute hosts on shared storage,
    during the rebuild operation we call spawn() on the destination
    compute. spawn() currently assumes that it should cleanup all
    resources on failure, which results in user data being deleted in the
    evacuate case.

    This change modifies spawn in the libvirt driver such that it only
    cleans up resources it created.

    Conflicts:
        nova/tests/functional/libvirt/test_pci_sriov_servers.py

    NOTE(stephenfin): Conflicts due to
    Id4d8ecb8fee46b21590ebcc62a2850030cef6508 ("objects: Store
    InstancePCIRequest.numa_policy in DB") not being present on
    stable/rocky.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Closes-Bug: #1550919
    Change-Id: I764481966c96a67d993da6e902dc9fc3ad29ee36
    (cherry picked from commit 497360b0ea970f1e68912be8229ef8c3f5454e9e)
    (cherry picked from commit 8b48ca672d9c0eb108c71b7f9f3f089d9ecf688a)
    (cherry picked from commit 1a320f2a0e0918de6afcce5cf23b7de178ec3a49)
    (cherry picked from commit a7d8aa699793e1d60ece4e03920e6041337f9a43)

Reviewed: https://review.opendev.org/732715
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=0730aba7aef493dfa160381a534aec4ca1b497fd
Submitter: Zuul
Branch: stable/queens

commit 0730aba7aef493dfa160381a534aec4ca1b497fd
Author: Matthew Booth <email address hidden>
Date: Tue Aug 14 16:05:11 2018 +0100

    Add functional test for bug 1550919

    This adds a failing test, which we fix in change I76448196.

    An earlier version of this change was previously merged as
    change I5619728d. This was later reverted, as it was failing in the
    gate. However, on inspection these failures seem to have been simply
    timeouts due to load.

    Changes from previous version:

    - Increase the timeouts which were previously triggering, and
      serialise server creation to reduce the chance of this recurring.
    - Add an LVM test, which highlights the requirement to flag the
      creation of ephemeral and swap disks.
    - Add an Qcow2 test, essentially the same as the Flat test but ensures
      coverage of the most common backends.
    - Each test now uses a separate instances_path allowing for cleanup
      without racing against other active tests.
    - Some nits addressed.

    For the time being this test does not make use of the recently improved
    nova.tests.functional.libvirt.base.ServersTestBase class to ease
    backports. Future changes should be made to use this class removing some
    of the common setUp logic from _LibvirtEvacuateTest.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Related-Bug: #1550919
    Change-Id: I1062b3e74382734edbb2142a09ff0073c66af8db
    (cherry picked from commit 90e0e874bde38937380d09ab27a7defbb5475cc2)
    (cherry picked from commit 6ccd13f8aeeb97c2139c1abc93cb976fd57d57dd)
    (cherry picked from commit 172eb21dee1d93b140c2b691cb8dfbc68b721bfe)
    (cherry picked from commit d7a1cb57247c4b1faa09b9c81c5cd2fbd4639095)
    (cherry picked from commit 6118101cbae56e80a22a35a5ffcb07a0ed259b99)

tags: added: in-stable-queens

Reviewed: https://review.opendev.org/732717
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=a54f51b0d2089e7f79db23875e9ff74e212b3435
Submitter: Zuul
Branch: stable/queens

commit a54f51b0d2089e7f79db23875e9ff74e212b3435
Author: Matthew Booth <email address hidden>
Date: Wed Aug 15 14:39:48 2018 +0100

    libvirt: Don't delete disks on shared storage during evacuate

    When evacuating an instance between compute hosts on shared storage,
    during the rebuild operation we call spawn() on the destination
    compute. spawn() currently assumes that it should cleanup all
    resources on failure, which results in user data being deleted in the
    evacuate case.

    This change modifies spawn in the libvirt driver such that it only
    cleans up resources it created.

    Conflicts:
            nova/virt/libvirt/driver.py

    NOTE(lyarwood): Conflicts due to
    I51673e58fc8d5f051df911630f6d7a928d123a5b ("Revert resize: wait for
    events according to hybrid plug") not being present in stable/queens.

    Co-Authored-By: Lee Yarwood <email address hidden>
    Closes-Bug: #1550919
    Change-Id: I764481966c96a67d993da6e902dc9fc3ad29ee36
    (cherry picked from commit 497360b0ea970f1e68912be8229ef8c3f5454e9e)
    (cherry picked from commit 8b48ca672d9c0eb108c71b7f9f3f089d9ecf688a)
    (cherry picked from commit 1a320f2a0e0918de6afcce5cf23b7de178ec3a49)
    (cherry picked from commit a7d8aa699793e1d60ece4e03920e6041337f9a43)
    (cherry picked from commit ae7602c1206de23439d6c3609b5872831138aa99)

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers