yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #93024
[Bug 2041511] [NEW] nova api returns 500 when creating a volume booted instance with memory enryption enabled
Public bug reported:
Description
===========
When creating an instance with an volume created from an image with
hw_mem_encryption: true, nova-api returns 500 and the creation request
is not accepted.
Steps to reproduce
==================
* Create an image with hw_mem_encryption=True
$ openstack image create encrypted ...
$ openstack image set encrypted --property hw_mem_encryption=True
* Create a volume from the image
$ openstack volume create bootvolume --image encrypted ...
* Create an instance
$ openstack server create --volume bootvolume ...
Expected result
===============
Instance creation is accepted and processed by nova, without errors
Actual result
=============
Nova api returns 500 error and does not accept the request
Environment
===========
1. Exact version of OpenStack you are running. See the following
list for all releases: http://docs.openstack.org/releases/
Ubuntu 22.04 and UCA bobcat.
# dpkg -l | grep nova
ii nova-api 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - API frontend
ii nova-common 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - common files
ii nova-compute 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node base
ii nova-compute-kvm 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node (KVM)
ii nova-compute-libvirt 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node libvirt support
ii nova-conductor 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - conductor service
ii nova-novncproxy 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - NoVNC proxy
ii nova-scheduler 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - virtual machine scheduler
ii python3-nova 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute Python 3 libraries
ii python3-novaclient 2:18.4.0-0ubuntu1~cloud0 all client library for OpenStack Compute API - 3.x
2. Which hypervisor did you use?
Libvirt + KVM
3. Which storage type did you use?
LVM
4. Which networking type did you use?
ml2 + ovs
Logs & Configs
==============
The following traceback is found in nova-api.log
```
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi [None req-f55255c7-5829-4f89-bee9-ab34a6c02faf 69d6ccfef7e240398970c80f0be8ccf7 5a2803c4cdb1412fa1e83738d7821904 - - default default] Unexpected exception in API method: NotImplementedError: Cannot load 'id' in the base class
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi Traceback (most recent call last):
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/openstack/wsgi.py", line 658, in wrapped
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return f(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi [Previous line repeated 11 more times]
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/openstack/compute/servers.py", line 786, in create
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi instances, resv_id = self.compute_api.create(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 2207, in create
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return self._create_instance(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 1725, in _create_instance
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._checks_for_create_and_rebuild(context, image_id, boot_meta,
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 1020, in _checks_for_create_and_rebuild
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._validate_flavor_image(context, image_id, image,
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 684, in _validate_flavor_image
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._validate_flavor_image_nostatus(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 830, in _validate_flavor_image_nostatus
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi API._validate_flavor_image_numa_pci(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 880, in _validate_flavor_image_numa_pci
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi hardware.get_mem_encryption_constraint(flavor, image_meta)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/virt/hardware.py", line 1195, in get_mem_encryption_constraint
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi image_meta.id)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/oslo_versionedobjects/base.py", line 67, in getter
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self.obj_load_attr(name)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/oslo_versionedobjects/base.py", line 600, in obj_load_attr
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi raise NotImplementedError(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi NotImplementedError: Cannot load 'id' in the base class
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi
```
** Affects: nova
Importance: Undecided
Status: New
** Description changed:
Description
===========
When creating an instance with an volume created from an image with
hw_mem_encryption: true, nova-api returns 500 and the creation request
is not accepted.
-
Steps to reproduce
==================
* Create an image with hw_mem_encryption=True
- $ openstack image create encrypted ...
- $ openstack image set encrypted --property hw_mem_encryption=True
+ $ openstack image create encrypted ...
+ $ openstack image set encrypted --property hw_mem_encryption=True
* Create a volume from the image
- $ openstack volume create bootvolume --image encrypted ...
+ $ openstack volume create bootvolume --image encrypted ...
- * Create an instance
- $ openstack server create --volume bootvolume ...
-
+ * Create an instance
+ $ openstack server create --volume bootvolume ...
Expected result
===============
Instance creation is accepted and processed by nova, without errors
Actual result
=============
Nova api returns 500 error and does not accept the request
Environment
===========
- This issue was initially found in a deployment using Ubuntu 22.04 and UCA bobcat.
1. Exact version of OpenStack you are running. See the following
- list for all releases: http://docs.openstack.org/releases/
+ list for all releases: http://docs.openstack.org/releases/
Ubuntu 22.04 and UCA bobcat.
# dpkg -l | grep nova
ii nova-api 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - API frontend
ii nova-common 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - common files
ii nova-compute 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node base
ii nova-compute-kvm 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node (KVM)
ii nova-compute-libvirt 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node libvirt support
ii nova-conductor 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - conductor service
ii nova-novncproxy 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - NoVNC proxy
ii nova-scheduler 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - virtual machine scheduler
ii python3-nova 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute Python 3 libraries
ii python3-novaclient 2:18.4.0-0ubuntu1~cloud0 all client library for OpenStack Compute API - 3.x
-
2. Which hypervisor did you use?
Libvirt + KVM
3. Which storage type did you use?
LVM
4. Which networking type did you use?
ml2 + ovs
Logs & Configs
==============
The following traceback is found in nova-api.log
```
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi [None req-f55255c7-5829-4f89-bee9-ab34a6c02faf 69d6ccfef7e240398970c80f0be8ccf7 5a2803c4cdb1412fa1e83738d7821904 - - default default] Unexpected exception in API method: NotImplementedError: Cannot load 'id' in the base class
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi Traceback (most recent call last):
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/openstack/wsgi.py", line 658, in wrapped
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return f(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi [Previous line repeated 11 more times]
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/openstack/compute/servers.py", line 786, in create
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi instances, resv_id = self.compute_api.create(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 2207, in create
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return self._create_instance(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 1725, in _create_instance
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._checks_for_create_and_rebuild(context, image_id, boot_meta,
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 1020, in _checks_for_create_and_rebuild
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._validate_flavor_image(context, image_id, image,
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 684, in _validate_flavor_image
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._validate_flavor_image_nostatus(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 830, in _validate_flavor_image_nostatus
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi API._validate_flavor_image_numa_pci(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 880, in _validate_flavor_image_numa_pci
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi hardware.get_mem_encryption_constraint(flavor, image_meta)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/virt/hardware.py", line 1195, in get_mem_encryption_constraint
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi image_meta.id)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/oslo_versionedobjects/base.py", line 67, in getter
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self.obj_load_attr(name)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/oslo_versionedobjects/base.py", line 600, in obj_load_attr
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi raise NotImplementedError(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi NotImplementedError: Cannot load 'id' in the base class
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi
```
--
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/2041511
Title:
nova api returns 500 when creating a volume booted instance with
memory enryption enabled
Status in OpenStack Compute (nova):
New
Bug description:
Description
===========
When creating an instance with an volume created from an image with
hw_mem_encryption: true, nova-api returns 500 and the creation request
is not accepted.
Steps to reproduce
==================
* Create an image with hw_mem_encryption=True
$ openstack image create encrypted ...
$ openstack image set encrypted --property hw_mem_encryption=True
* Create a volume from the image
$ openstack volume create bootvolume --image encrypted ...
* Create an instance
$ openstack server create --volume bootvolume ...
Expected result
===============
Instance creation is accepted and processed by nova, without errors
Actual result
=============
Nova api returns 500 error and does not accept the request
Environment
===========
1. Exact version of OpenStack you are running. See the following
list for all releases: http://docs.openstack.org/releases/
Ubuntu 22.04 and UCA bobcat.
# dpkg -l | grep nova
ii nova-api 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - API frontend
ii nova-common 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - common files
ii nova-compute 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node base
ii nova-compute-kvm 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node (KVM)
ii nova-compute-libvirt 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - compute node libvirt support
ii nova-conductor 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - conductor service
ii nova-novncproxy 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - NoVNC proxy
ii nova-scheduler 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute - virtual machine scheduler
ii python3-nova 3:28.0.0-0ubuntu1~cloud0 all OpenStack Compute Python 3 libraries
ii python3-novaclient 2:18.4.0-0ubuntu1~cloud0 all client library for OpenStack Compute API - 3.x
2. Which hypervisor did you use?
Libvirt + KVM
3. Which storage type did you use?
LVM
4. Which networking type did you use?
ml2 + ovs
Logs & Configs
==============
The following traceback is found in nova-api.log
```
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi [None req-f55255c7-5829-4f89-bee9-ab34a6c02faf 69d6ccfef7e240398970c80f0be8ccf7 5a2803c4cdb1412fa1e83738d7821904 - - default default] Unexpected exception in API method: NotImplementedError: Cannot load 'id' in the base class
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi Traceback (most recent call last):
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/openstack/wsgi.py", line 658, in wrapped
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return f(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/validation/__init__.py", line 110, in wrapper
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return func(*args, **kwargs)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi [Previous line repeated 11 more times]
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/api/openstack/compute/servers.py", line 786, in create
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi instances, resv_id = self.compute_api.create(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 2207, in create
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi return self._create_instance(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 1725, in _create_instance
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._checks_for_create_and_rebuild(context, image_id, boot_meta,
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 1020, in _checks_for_create_and_rebuild
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._validate_flavor_image(context, image_id, image,
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 684, in _validate_flavor_image
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self._validate_flavor_image_nostatus(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 830, in _validate_flavor_image_nostatus
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi API._validate_flavor_image_numa_pci(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/compute/api.py", line 880, in _validate_flavor_image_numa_pci
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi hardware.get_mem_encryption_constraint(flavor, image_meta)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/nova/virt/hardware.py", line 1195, in get_mem_encryption_constraint
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi image_meta.id)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/oslo_versionedobjects/base.py", line 67, in getter
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi self.obj_load_attr(name)
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi File "/usr/lib/python3/dist-packages/oslo_versionedobjects/base.py", line 600, in obj_load_attr
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi raise NotImplementedError(
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi NotImplementedError: Cannot load 'id' in the base class
2023-10-27 07:46:56.878 381436 ERROR nova.api.openstack.wsgi
```
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/2041511/+subscriptions
Follow ups