nova work with glance SSL

Bug #1266974 reported by Liping Mao on 2014-01-08
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Glance Client
Undecided
Unassigned
OpenStack Compute (nova)
Undecided
Unassigned

Bug Description

My environment is :
Nova api --https--> haproxy(SSL proxy)----http----> Glance api1
                                       |--http----> Glance api2

I use centos + rdo rpm package(havana), my haproxy is 1.5_dev21.

It can work well if I config in nova.conf as following:
glance_api_servers=glanceapi1_ip:9292,glanceapi2_ip:9292

But when I want nova api talk with glance api in https, it can't work. My config is as following:
glance_api_servers=https://Glanceapi_VIP:443 in nova.conf,

When I boot VM, I will get the error as below:
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/nova/compute/api.py", line 1220, in create
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack legacy_bdm=legacy_bdm)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/nova/compute/api.py", line 840, in _create_instance
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack image_id, boot_meta = self._get_image(context, image_href)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/nova/compute/api.py", line 620, in _get_image
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack image = image_service.show(context, image_id)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/nova/image/glance.py", line 292, in show
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack _reraise_translated_image_exception(image_id)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/nova/image/glance.py", line 290, in show
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack image = self._client.call(context, 1, 'get', image_id)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/nova/image/glance.py", line 214, in call
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack return getattr(client.images, method)(*args, **kwargs)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/glanceclient/v1/images.py", line 114, in get
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack % urllib.quote(str(image_id)))
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/glanceclient/common/http.py", line 293, in raw_request
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack return self._http_request(url, method, **kwargs)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/glanceclient/common/http.py", line 244, in _http_request
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack body_str = ''.join([chunk for chunk in body_iter])
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/glanceclient/common/http.py", line 499, in __iter__
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack chunk = self.next()
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/glanceclient/common/http.py", line 515, in next
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack chunk = self._resp.read(CHUNKSIZE)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib64/python2.6/httplib.py", line 518, in read
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack self.close()
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib64/python2.6/httplib.py", line 499, in close
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack self.fp.close()
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib64/python2.6/socket.py", line 278, in close
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack self._sock.close()
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack File "/usr/lib/python2.6/site-packages/eventlet/greenio.py", line 145, in __getattr__
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack attr = getattr(self.fd, name)
2014-01-08 04:39:01.480 6011 TRACE nova.api.openstack AttributeError: 'GreenSocket' object has no attribute 'close'

Liping Mao (limao) on 2014-01-08
description: updated
description: updated

You need a newer version of eventlet. This was reported in [1] and fixed with the patch in [2]. I'll try to update the packages in RDO but in the meanwhile, could you open a bug in [3] for tracking it? Thanks.

[1] https://bitbucket.org/eventlet/eventlet/issue/136
[2] https://bitbucket.org/eventlet/eventlet/commits/609f230
[3] https://bugzilla.redhat.com/enter_bug.cgi?product=RDO&component=openstack-nova

Changed in nova:
status: New → Invalid
Changed in python-glanceclient:
status: New → Invalid
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers