yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #93610
[Bug 2055700] [NEW] server rebuild with reimage-boot-volume and is_volume_backed fails with BuildAbortException
Public bug reported:
Description
===========
More specifically the following tempest test in master fails with:
tempest.api.compute.servers.test_server_actions.ServerActionsV293TestJSON.test_rebuild_volume_backed_server
Even with patch for https://review.opendev.org/c/openstack/nova/+/910627
Technically though, it should be unrelated to the driver implementation
as...
The `ComputeManager._rebuild_default_impl` calls first destroy on the VM in both branches:
- https://opendev.org/openstack/nova/src/branch/master/nova/compute/manager.py#L3695-L3701
And in the case of a volume backed VM with `reimage_boot_volume=True` calls `ComputeManager._rebuild_volume_backed_instance` here
- https://opendev.org/openstack/nova/src/branch/master/nova/compute/manager.py#L3710-L3715
The function tries to detach the volume from the destroyed instance and at least in the VMware driver raises an `InstanceNotFound`, which I'd argue would be expected.
- https://opendev.org/openstack/nova/src/branch/master/nova/compute/manager.py#L3596-L3607
Steps to reproduce
==================
* Install Devstack from master
* Run tempest test `tempest.api.compute.servers.test_server_actions.ServerActionsV293TestJSON.test_rebuild_volume_backed_server`
Or as a bash script:
```
IMAGE=$(openstack image list -c ID -f value)
ID1=$(openstack server create --flavor 1 --image $IMAGE --boot-from-volume 1 rebuild-1 -c id -f value)
ID2=$(openstack server create --flavor 1 --image $IMAGE --boot-from-volume 1 rebuild-2 -c id -f value)
# Wait for servers to be ready
# Works
openstack server rebuild --os-compute-api-version 2.93 --image $IMAGE $ID1
# Fails
openstack server rebuild --os-compute-api-version 2.93 --reimage-boot-volume --image $IMAGE $ID1
```
Expected result
===============
The test succeeds.
Actual result
=============
Environment
===========
1. Patch proposed in https://review.opendev.org/c/openstack/nova/+/909474
+ Patch proposed in https://review.opendev.org/c/openstack/nova/+/910627
2. Which hypervisor did you use? What's the version of that?
vmwareapi (VSphere 7.0.3 & ESXi 7.0.3)
2. Which storage type did you use?
vmdk on NFS 4.1
3. Which networking type did you use?
networking-nsx-t (https://github.com/sapcc/networking-nsx-t)
Logs & Configs
==============
** Affects: nova
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/2055700
Title:
server rebuild with reimage-boot-volume and is_volume_backed fails
with BuildAbortException
Status in OpenStack Compute (nova):
New
Bug description:
Description
===========
More specifically the following tempest test in master fails with:
tempest.api.compute.servers.test_server_actions.ServerActionsV293TestJSON.test_rebuild_volume_backed_server
Even with patch for https://review.opendev.org/c/openstack/nova/+/910627
Technically though, it should be unrelated to the driver
implementation as...
The `ComputeManager._rebuild_default_impl` calls first destroy on the VM in both branches:
- https://opendev.org/openstack/nova/src/branch/master/nova/compute/manager.py#L3695-L3701
And in the case of a volume backed VM with `reimage_boot_volume=True` calls `ComputeManager._rebuild_volume_backed_instance` here
- https://opendev.org/openstack/nova/src/branch/master/nova/compute/manager.py#L3710-L3715
The function tries to detach the volume from the destroyed instance and at least in the VMware driver raises an `InstanceNotFound`, which I'd argue would be expected.
- https://opendev.org/openstack/nova/src/branch/master/nova/compute/manager.py#L3596-L3607
Steps to reproduce
==================
* Install Devstack from master
* Run tempest test `tempest.api.compute.servers.test_server_actions.ServerActionsV293TestJSON.test_rebuild_volume_backed_server`
Or as a bash script:
```
IMAGE=$(openstack image list -c ID -f value)
ID1=$(openstack server create --flavor 1 --image $IMAGE --boot-from-volume 1 rebuild-1 -c id -f value)
ID2=$(openstack server create --flavor 1 --image $IMAGE --boot-from-volume 1 rebuild-2 -c id -f value)
# Wait for servers to be ready
# Works
openstack server rebuild --os-compute-api-version 2.93 --image $IMAGE $ID1
# Fails
openstack server rebuild --os-compute-api-version 2.93 --reimage-boot-volume --image $IMAGE $ID1
```
Expected result
===============
The test succeeds.
Actual result
=============
Environment
===========
1. Patch proposed in https://review.opendev.org/c/openstack/nova/+/909474
+ Patch proposed in https://review.opendev.org/c/openstack/nova/+/910627
2. Which hypervisor did you use? What's the version of that?
vmwareapi (VSphere 7.0.3 & ESXi 7.0.3)
2. Which storage type did you use?
vmdk on NFS 4.1
3. Which networking type did you use?
networking-nsx-t (https://github.com/sapcc/networking-nsx-t)
Logs & Configs
==============
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/2055700/+subscriptions
Follow ups