RDO tickets are now tracked in Jira https://issues.redhat.com/projects/RDO/issues/
Bug 1074724 - Glance api ssl issue
Summary: Glance api ssl issue
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: RDO
Classification: Community
Component: openstack-glance
Version: unspecified
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
: ---
Assignee: RHOS Maint
QA Contact: Dafna Ron
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-03-11 01:05 UTC by Liping Mao
Modified: 2017-06-18 06:06 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-06-18 06:06:38 UTC
Embargoed:


Attachments (Terms of Use)

Description Liping Mao 2014-03-11 01:05:38 UTC
Description of problem:
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.

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'


https://bugs.launchpad.net/nova/+bug/1266974
---------------------------------------------

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

Comment 1 Kashyap Chamarthy 2014-03-11 06:45:50 UTC
Liping, I just confirmed -- the patch mentioned above in the 2nd URL[*] by Xavier is in the below version of python-eventlet Fedora package:

  $ koji latest-build rawhide python-eventlet | awk '{print $1}' 
  Build                                     
  ----------------------------------------  
  python-eventlet-0.14.0-1.fc21           


Can you please try with the above python-eventlet and report the status here? 


[*] https://bitbucket.org/eventlet/eventlet/commits/609f23

Comment 2 Liping Mao 2014-03-11 06:51:23 UTC
I test this in CentOS6.3, and in el6 the latest version of python-eventlet is 0.9.17:
python-eventlet.noarch  0.9.17-2.el6

RDO can support CentOS, so I think it seems need to upgrade the python-eventlet to 0.14.0 in el6.

Comment 3 Liping Mao 2014-03-12 05:17:22 UTC
I build python-eventlet 0.14.0 rpm package in centos 6.3 and find it can work well. I think for support glance-api ssl, python-eventlet in epel6 should be upgraded to 0.14.0 .

(In reply to Kashyap Chamarthy from comment #1)
> Liping, I just confirmed -- the patch mentioned above in the 2nd URL[*] by
> Xavier is in the below version of python-eventlet Fedora package:
> 
>   $ koji latest-build rawhide python-eventlet | awk '{print $1}' 
>   Build                                     
>   ----------------------------------------  
>   python-eventlet-0.14.0-1.fc21           
> 
> 
> Can you please try with the above python-eventlet and report the status
> here? 
> 
> 
> [*] https://bitbucket.org/eventlet/eventlet/commits/609f23

Comment 4 Mike McCune 2016-03-28 23:26:37 UTC
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions

Comment 5 Christopher Brown 2017-06-17 19:25:35 UTC
This can be closed now I think?


Note You need to log in before you can comment on or make changes to this bug.