In different location we assume system_metadata.image_base_image_ref
exists, because it is set during instance creation in method
_populate_instance_for_create
But once instance is rebuild, all system_metadata image property a dropped
and replace by new image property and without setting back
image_base_image_ref.
This change propose to set image_base_image_ref during rebuild.
In specific case of shelve/unshelve in Qcow2 backend, image_base_image_ref is
used to rebase disk image, so we ensure this property is set as instance may
have been rebuild before the fix was apply.
Related-Bug: #1732428
Closes-Bug: #1893618
Change-Id: Ia3031ea1f7db8b398f02d2080ca603ded8970200
(cherry picked from commit fe52b6c25bebdd1b459c7a59fbb8d9f6de200c9d)
(cherry picked from commit 560414036d9f2ebcfeb8626029d0bd849d6cad44)
Reviewed: https:/ /review. opendev. org/c/openstack /nova/+ /787945 /opendev. org/openstack/ nova/commit/ 8a01a58a60e7f4f 2c189f8ca065d8c 21ccbde04f
Committed: https:/
Submitter: "Zuul (22348)"
Branch: stable/train
commit 8a01a58a60e7f4f 2c189f8ca065d8c 21ccbde04f
Author: Alexandre Arents <email address hidden>
Date: Tue Sep 1 08:26:25 2020 +0000
Update image_base_ image_ref during rebuild.
In different location we assume system_ metadata. image_base_ image_ref instance_ for_create
exists, because it is set during instance creation in method
_populate_
But once instance is rebuild, all system_metadata image property a dropped base_image_ ref.
and replace by new image property and without setting back
image_
This change propose to set image_base_ image_ref during rebuild.
In specific case of shelve/unshelve in Qcow2 backend, image_base_ image_ref is
used to rebase disk image, so we ensure this property is set as instance may
have been rebuild before the fix was apply.
Related-Bug: #1732428 398f02d2080ca60 3ded8970200 b459c7a59fbb8d9 f6de200c9d) cfeb8626029d0bd 849d6cad44)
Closes-Bug: #1893618
Change-Id: Ia3031ea1f7db8b
(cherry picked from commit fe52b6c25bebdd1
(cherry picked from commit 560414036d9f2eb