yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #60543
[Bug 1657095] [NEW] Failed to upload image to Vmware vcenter backend
Public bug reported:
Failing to upload images to vmware vcenter backend on Glance Liberty.
Glance Liberty
python-glance-11.0.1-6.el7ost.noarch
python-glance-store-0.9.1-3.el7ost.noarch
python-glanceclient-1.1.1-2.el7ost.noarch
openstack-glance-11.0.1-6.el7ost.noarch
Vmware vcenter 5.5u3 (VCSA)
Glance config
stores=file,http,vmware (unsure if need to add vmware yes/no?)
default_store = vsphere
vmware_server_host=x.y.z.w
vmware_server_username=root
vmware_server_password=xxxxxxxxx
vmware_datastores=dc1:datastore1
vmware_api_insecure=true
vmware_task_poll_interval=5
vmware_store_image_dir=/openstack_glance
Error I get:
# glance --debug image-create --name test.vmdk --container-format bare --disk-format vmdk --file /root/cirros-0.3.4-x86_64-disk.vmdk
Request returned failure status 500.
+------------------+--------------------------------------+
| Property | Value |
+------------------+--------------------------------------+
| checksum | None |
| container_format | bare |
| created_at | 2017-01-17T10:50:40Z |
| disk_format | vmdk |
| id | 169ae026-3222-4956-8a14-69309cfa3988 |
| min_disk | 0 |
| min_ram | 0 |
| name | test.vmdk |
| owner | f0f5b951090d497daa62c7bf0cc28dd2 |
| protected | False |
| size | None |
| status | queued |
| tags | [] |
| updated_at | 2017-01-17T10:50:40Z |
| virtual_size | None |
| visibility | private |
+------------------+--------------------------------------+
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/glanceclient/shell.py", line 688, in main
args.func(client, args)
File "/usr/lib/python2.7/site-packages/glanceclient/common/utils.py", line 98, in func_wrapper
return func(gc, args)
File "/usr/lib/python2.7/site-packages/glanceclient/v2/shell.py", line 85, in do_image_create
do_image_upload(gc, args)
File "/usr/lib/python2.7/site-packages/glanceclient/v2/shell.py", line 318, in do_image_upload
gc.images.upload(args.id, image_data, args.size)
File "/usr/lib/python2.7/site-packages/glanceclient/v2/images.py", line 221, in upload
self.http_client.put(url, headers=hdrs, data=body)
File "/usr/lib/python2.7/site-packages/keystoneclient/adapter.py", line 179, in put
return self.request(url, 'PUT', **kwargs)
File "/usr/lib/python2.7/site-packages/glanceclient/common/http.py", line 333, in request
return self._handle_response(resp)
File "/usr/lib/python2.7/site-packages/glanceclient/common/http.py", line 89, in _handle_response
raise exc.from_response(resp, resp.content)
HTTPInternalServerError: 500 Internal Server Error: The server has either erred or is incapable of performing the requested operation. (HTTP 500)
500 Internal Server Error: The server has either erred or is incapable of performing the requested operation. (HTTP 500)
Api.log
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi File "/usr/lib/python2.7/site-packages/glance_store/backend.py", line 340, in store_add_to_backend
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi context=context)
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi File "/usr/lib/python2.7/site-packages/glance_store/capabilities.py", line 226, in op_checker
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi return store_op_fun(store, *args, **kwargs)
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi File "/usr/lib/python2.7/site-packages/glance_store/_drivers/vmware_datastore.py", line 536, in add
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi raise exceptions.BackendException(msg)
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi BackendException: Failed to upload content of image 169ae026-3222-4956-8a14-69309cfa3988. The request returned an unexpected status: 3
01.
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi The response body:
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi None
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi
Under vcenter I have a folder called "openstack_glance".
In the recent releases I noticed when I configure Nova/Cinder with vcenter they create a folder under vcenter root called Openstack under which a sub folder called: Project (f0f5b951090d497daa62c7bf0cc28dd2) -> Admin tenant's ID.
Having nothing to lose I also created a sub folder here called openstack_glance.
Tested below two versions as well, same error on image upload.
vmware_store_image_dir='/openstack/Project (f0f5b951090d497daa62c7bf0cc28dd2)/openstack_glance'
vmware_store_image_dir="/openstack/Project (f0f5b951090d497daa62c7bf0cc28dd2)/openstack_glance"
Not ruling out possible config errors on my part either on Openstack or VMware.
I was able to upload images boot instance and created volumes with Glance (kilo) release on this same vmware backend.
** Affects: glance
Importance: Undecided
Status: New
** Attachment added: "GLance API registry logs"
https://bugs.launchpad.net/bugs/1657095/+attachment/4805319/+files/glance.tar.gz
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1657095
Title:
Failed to upload image to Vmware vcenter backend
Status in Glance:
New
Bug description:
Failing to upload images to vmware vcenter backend on Glance Liberty.
Glance Liberty
python-glance-11.0.1-6.el7ost.noarch
python-glance-store-0.9.1-3.el7ost.noarch
python-glanceclient-1.1.1-2.el7ost.noarch
openstack-glance-11.0.1-6.el7ost.noarch
Vmware vcenter 5.5u3 (VCSA)
Glance config
stores=file,http,vmware (unsure if need to add vmware yes/no?)
default_store = vsphere
vmware_server_host=x.y.z.w
vmware_server_username=root
vmware_server_password=xxxxxxxxx
vmware_datastores=dc1:datastore1
vmware_api_insecure=true
vmware_task_poll_interval=5
vmware_store_image_dir=/openstack_glance
Error I get:
# glance --debug image-create --name test.vmdk --container-format bare --disk-format vmdk --file /root/cirros-0.3.4-x86_64-disk.vmdk
Request returned failure status 500.
+------------------+--------------------------------------+
| Property | Value |
+------------------+--------------------------------------+
| checksum | None |
| container_format | bare |
| created_at | 2017-01-17T10:50:40Z |
| disk_format | vmdk |
| id | 169ae026-3222-4956-8a14-69309cfa3988 |
| min_disk | 0 |
| min_ram | 0 |
| name | test.vmdk |
| owner | f0f5b951090d497daa62c7bf0cc28dd2 |
| protected | False |
| size | None |
| status | queued |
| tags | [] |
| updated_at | 2017-01-17T10:50:40Z |
| virtual_size | None |
| visibility | private |
+------------------+--------------------------------------+
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/glanceclient/shell.py", line 688, in main
args.func(client, args)
File "/usr/lib/python2.7/site-packages/glanceclient/common/utils.py", line 98, in func_wrapper
return func(gc, args)
File "/usr/lib/python2.7/site-packages/glanceclient/v2/shell.py", line 85, in do_image_create
do_image_upload(gc, args)
File "/usr/lib/python2.7/site-packages/glanceclient/v2/shell.py", line 318, in do_image_upload
gc.images.upload(args.id, image_data, args.size)
File "/usr/lib/python2.7/site-packages/glanceclient/v2/images.py", line 221, in upload
self.http_client.put(url, headers=hdrs, data=body)
File "/usr/lib/python2.7/site-packages/keystoneclient/adapter.py", line 179, in put
return self.request(url, 'PUT', **kwargs)
File "/usr/lib/python2.7/site-packages/glanceclient/common/http.py", line 333, in request
return self._handle_response(resp)
File "/usr/lib/python2.7/site-packages/glanceclient/common/http.py", line 89, in _handle_response
raise exc.from_response(resp, resp.content)
HTTPInternalServerError: 500 Internal Server Error: The server has either erred or is incapable of performing the requested operation. (HTTP 500)
500 Internal Server Error: The server has either erred or is incapable of performing the requested operation. (HTTP 500)
Api.log
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi File "/usr/lib/python2.7/site-packages/glance_store/backend.py", line 340, in store_add_to_backend
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi context=context)
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi File "/usr/lib/python2.7/site-packages/glance_store/capabilities.py", line 226, in op_checker
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi return store_op_fun(store, *args, **kwargs)
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi File "/usr/lib/python2.7/site-packages/glance_store/_drivers/vmware_datastore.py", line 536, in add
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi raise exceptions.BackendException(msg)
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi BackendException: Failed to upload content of image 169ae026-3222-4956-8a14-69309cfa3988. The request returned an unexpected status: 3
01.
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi The response body:
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi None
2017-01-17 12:50:40.754 12199 ERROR glance.common.wsgi
Under vcenter I have a folder called "openstack_glance".
In the recent releases I noticed when I configure Nova/Cinder with vcenter they create a folder under vcenter root called Openstack under which a sub folder called: Project (f0f5b951090d497daa62c7bf0cc28dd2) -> Admin tenant's ID.
Having nothing to lose I also created a sub folder here called openstack_glance.
Tested below two versions as well, same error on image upload.
vmware_store_image_dir='/openstack/Project (f0f5b951090d497daa62c7bf0cc28dd2)/openstack_glance'
vmware_store_image_dir="/openstack/Project (f0f5b951090d497daa62c7bf0cc28dd2)/openstack_glance"
Not ruling out possible config errors on my part either on Openstack or VMware.
I was able to upload images boot instance and created volumes with Glance (kilo) release on this same vmware backend.
To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1657095/+subscriptions