← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1908008] [NEW] Glance with cinder backend

 

Public bug reported:

Centos 8.2, Ussuri
I´m trying to configure cinder as a glance backend. 
Glance configuration:
stores = cinder
default_store = cinder
cinder_store_auth_address = http://xx.0.35.200:5000/v3
cinder_store_user_name = cinder
cinder_store_password = xxxxxx
cinder_catalog_info = volumev2::cinder:http://xx.0.35.200:8776/v3/%(tenant_id)s
cinder_store_project_name = service

Cinder configuration:
allowed_direct_url_schemes = cinder
image_upload_use_internal_tenant = True

But I´m receiving this message:

2020-12-13 21:42:31.481 134945 ERROR glance.api.v2.image_data [req-083c3f07-15dd-458c-bcce-95b8313a7260 - - - - -] Failed to upload image data due to internal error: cinderclient.exceptions.BadRequest: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi [req-083c3f07-15dd-458c-bcce-95b8313a7260 - - - - -] Caught error: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69): cinderclient.exceptions.BadRequest: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi Traceback (most recent call last):
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/common/wsgi.py", line 1349, in __call__
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     request, **action_args)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/common/wsgi.py", line 1392, in dispatch
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return method(*args, **kwargs)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/common/utils.py", line 416, in wrapped
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return func(self, req, *args, **kwargs)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/api/v2/image_data.py", line 299, in upload
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self._restore(image_repo, image)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self.force_reraise()
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     six.reraise(self.type_, self.value, self.tb)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/six.py", line 703, in reraise
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     raise value
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/api/v2/image_data.py", line 164, in upload
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     image.set_data(data, size, backend=backend)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/domain/proxy.py", line 198, in set_data
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self.base.set_data(data, size, backend=backend, set_active=set_active)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/notifier.py", line 501, in set_data
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     _send_notification(notify_error, 'image.upload', msg)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 220, in __exit__
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self.force_reraise()
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     six.reraise(self.type_, self.value, self.tb)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/six.py", line 703, in reraise
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     raise value
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/notifier.py", line 448, in set_data
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     set_active=set_active)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/api/policy.py", line 204, in set_data
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return self.image.set_data(*args, **kwargs)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/quota/__init__.py", line 319, in set_data
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     set_active=set_active)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/location.py", line 559, in set_data
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self._upload_to_store(data, verifier, backend, size)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/location.py", line 486, in _upload_to_store
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     verifier=verifier)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/backend.py", line 491, in add_to_backend_with_multihash
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     image_id, data, size, hashing_algo, store, context, verifier)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/backend.py", line 468, in store_add_to_backend_with_multihash
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     image_id, data, size, hashing_algo, context=context, verifier=verifier)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/driver.py", line 279, in add_adapter
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     metadata_dict) = store_add_fun(*args, **kwargs)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/capabilities.py", line 176, in op_checker
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return store_op_fun(store, *args, **kwargs)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/_drivers/cinder.py", line 747, in add
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     volume_type=volume_type)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/v3/volumes.py", line 125, in create
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return self._create('/volumes', body, 'volume')
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/base.py", line 302, in _create
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     resp, body = self.api.client.post(url, body=body)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/client.py", line 476, in post
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return self._cs_request(url, 'POST', **kwargs)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/client.py", line 429, in _cs_request
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     resp, body = self.request(url, method, **kwargs)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/client.py", line 411, in request
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     raise exceptions.from_response(resp, body)
2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi cinderclient.exceptions.BadRequest: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69)

** Affects: glance
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1908008

Title:
  Glance with cinder backend

Status in Glance:
  New

Bug description:
  Centos 8.2, Ussuri
  I´m trying to configure cinder as a glance backend. 
  Glance configuration:
  stores = cinder
  default_store = cinder
  cinder_store_auth_address = http://xx.0.35.200:5000/v3
  cinder_store_user_name = cinder
  cinder_store_password = xxxxxx
  cinder_catalog_info = volumev2::cinder:http://xx.0.35.200:8776/v3/%(tenant_id)s
  cinder_store_project_name = service

  Cinder configuration:
  allowed_direct_url_schemes = cinder
  image_upload_use_internal_tenant = True

  But I´m receiving this message:

  2020-12-13 21:42:31.481 134945 ERROR glance.api.v2.image_data [req-083c3f07-15dd-458c-bcce-95b8313a7260 - - - - -] Failed to upload image data due to internal error: cinderclient.exceptions.BadRequest: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi [req-083c3f07-15dd-458c-bcce-95b8313a7260 - - - - -] Caught error: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69): cinderclient.exceptions.BadRequest: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi Traceback (most recent call last):
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/common/wsgi.py", line 1349, in __call__
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     request, **action_args)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/common/wsgi.py", line 1392, in dispatch
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return method(*args, **kwargs)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/common/utils.py", line 416, in wrapped
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return func(self, req, *args, **kwargs)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/api/v2/image_data.py", line 299, in upload
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self._restore(image_repo, image)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 220, in __exit__
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self.force_reraise()
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     six.reraise(self.type_, self.value, self.tb)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/six.py", line 703, in reraise
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     raise value
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/api/v2/image_data.py", line 164, in upload
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     image.set_data(data, size, backend=backend)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/domain/proxy.py", line 198, in set_data
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self.base.set_data(data, size, backend=backend, set_active=set_active)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/notifier.py", line 501, in set_data
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     _send_notification(notify_error, 'image.upload', msg)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 220, in __exit__
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self.force_reraise()
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/oslo_utils/excutils.py", line 196, in force_reraise
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     six.reraise(self.type_, self.value, self.tb)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/six.py", line 703, in reraise
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     raise value
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/notifier.py", line 448, in set_data
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     set_active=set_active)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/api/policy.py", line 204, in set_data
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return self.image.set_data(*args, **kwargs)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/quota/__init__.py", line 319, in set_data
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     set_active=set_active)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/location.py", line 559, in set_data
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     self._upload_to_store(data, verifier, backend, size)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance/location.py", line 486, in _upload_to_store
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     verifier=verifier)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/backend.py", line 491, in add_to_backend_with_multihash
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     image_id, data, size, hashing_algo, store, context, verifier)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/backend.py", line 468, in store_add_to_backend_with_multihash
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     image_id, data, size, hashing_algo, context=context, verifier=verifier)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/driver.py", line 279, in add_adapter
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     metadata_dict) = store_add_fun(*args, **kwargs)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/capabilities.py", line 176, in op_checker
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return store_op_fun(store, *args, **kwargs)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/glance_store/_drivers/cinder.py", line 747, in add
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     volume_type=volume_type)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/v3/volumes.py", line 125, in create
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return self._create('/volumes', body, 'volume')
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/base.py", line 302, in _create
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     resp, body = self.api.client.post(url, body=body)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/client.py", line 476, in post
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     return self._cs_request(url, 'POST', **kwargs)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/client.py", line 429, in _cs_request
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     resp, body = self.request(url, method, **kwargs)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi   File "/usr/lib/python3.6/site-packages/cinderclient/client.py", line 411, in request
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi     raise exceptions.from_response(resp, body)
  2020-12-13 21:42:31.508 134945 ERROR glance.common.wsgi cinderclient.exceptions.BadRequest: Invalid input for field/attribute image_owner. Value: None. None is not of type 'string' (HTTP 400) (Request-ID: req-e0e72f00-27bd-4ed6-b8c2-018623be7a69)

To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1908008/+subscriptions


Follow ups