Missing os_region_name for mult-region cinder with nova

Bug #1468306 reported by Ante Karamatić on 2015-06-24
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
cinder (Juju Charms Collection)
High
Billy Olsen
nova-cloud-controller (Juju Charms Collection)
High
Billy Olsen
nova-compute (Juju Charms Collection)
High
Billy Olsen

Bug Description

When multiple regions are used, nova api doesn't know to which cinder to reach out:

2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack Traceback (most recent call last):
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/__init__.py", line 124, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return req.get_response(self.application)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1320, in send
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack application, catch_exc_info=False)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1284, in call_application
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack app_iter = application(self.environ, start_response)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return resp(environ, start_response)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/keystoneclient/middleware/auth_token.py", line 663, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return self.app(env, start_response)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return resp(environ, start_response)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return resp(environ, start_response)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/routes/middleware.py", line 131, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack response = self.app(environ, start_response)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return resp(environ, start_response)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack resp = self.call_func(req, *args, **self.kwargs)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return self.func(req, *args, **kwargs)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/wsgi.py", line 910, in __call__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack content_type, body, accept)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/wsgi.py", line 975, in _process_stack
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack action_result = self.dispatch(meth, request, action_args)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/wsgi.py", line 1059, in dispatch
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return method(req=request, **action_args)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/api/openstack/compute/contrib/volumes.py", line 418, in create
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack volume_id, device)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/compute/api.py", line 221, in wrapped
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return func(self, context, target, *args, **kwargs)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/compute/api.py", line 211, in inner
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return function(self, context, instance, *args, **kwargs)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/compute/api.py", line 192, in inner
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack return f(self, context, instance, *args, **kw)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/compute/api.py", line 2947, in attach_volume
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack disk_bus, device_type)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/compute/api.py", line 2928, in _attach_volume
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack volume_bdm.destroy(context)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/openstack/common/excutils.py", line 82, in __exit__
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack six.reraise(self.type_, self.value, self.tb)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/compute/api.py", line 2921, in _attach_volume
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack volume = self.volume_api.get(context, volume_id)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/volume/cinder.py", line 185, in wrapper
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack res = method(self, ctx, volume_id, *args, **kwargs)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/volume/cinder.py", line 283, in get
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack item = cinderclient(context).volumes.get(volume_id)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/volume/cinder.py", line 92, in cinderclient
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack version = get_cinder_client_version(context)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/nova/volume/cinder.py", line 254, in get_cinder_client_version
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack endpoint_type=endpoint_type)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/cinderclient/service_catalog.py", line 86, in url_for
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack raise cinderclient.exceptions.AmbiguousEndpoints(endpoints=eplist)
2015-06-24 10:43:47.964 1170 TRACE nova.api.openstack AmbiguousEndpoints: AmbiguousEndpoints: [{u'adminURL': u'http://172.16.20.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478', u'region': u'Chassis1', u'internalURL':
u'http://172.16.20.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478', 'serviceName': u'cinder', u'id': u'65776036ee7745b89483b992d1d41d73', u'publicURL': u'http://172.16.20.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478'},
{u'adminURL': u'http://172.16.30.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478', u'region': u'Chassis2', u'internalURL': u'http://172.16.30.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478', 'serviceName': u'cinder', u'id'
: u'1e8916d776414e6da4d7bf1b4ada5fc1', u'publicURL': u'http://172.16.30.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478'}, {u'adminURL': u'http://172.16.40.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478', u'region': u'Chas
sis3', u'internalURL': u'http://172.16.40.4:8776/v1/9eb8fcc4d6114834b8716f3209c05478', 'serviceName': u'cinder', u'id': u'0e42b2c9322a49f3842a088b630accd9', u'publicURL': u'http://172.16.40.4:8776/v1/9eb8fcc4d6114
834b8716f3209c05478'}]

It's missing:

== nova.conf (nova-cloud-controller and nova-compute nodes) ==

[cinder]
os_region_name = <region>

== cinder.conf ==

[DEFAULT]
os_region_name = <region>

Unfortunately the config-flags option does not yet support non-DEFAULT sections so only the cinder entry can be added this way.

Related branches

Ante Karamatić (ivoks) wrote :

It's needed on both nova-cloud-controller and nova-compute nodes.

James Page (james-page) on 2015-12-14
Changed in nova-compute (Juju Charms Collection):
milestone: none → 16.01
Changed in nova-cloud-controller (Juju Charms Collection):
milestone: none → 16.01
status: New → Triaged
Changed in nova-compute (Juju Charms Collection):
status: New → Triaged
Changed in nova-cloud-controller (Juju Charms Collection):
importance: Undecided → High
Changed in nova-compute (Juju Charms Collection):
importance: Undecided → High
description: updated
summary: - Missing region setting in nova.conf
+ Missing os_region_name for mult-region cinder with nova
James Page (james-page) wrote :

region is a config option for cinder and nova-cloud-controller so that should be trivial to add - nova-compute does not, but its related to nova-cc which does know the region, so it should be passed over that relation.

Changed in cinder (Juju Charms Collection):
status: New → Triaged
importance: Undecided → High
milestone: none → 16.04
Changed in nova-cloud-controller (Juju Charms Collection):
milestone: 16.01 → 16.04
Changed in nova-compute (Juju Charms Collection):
milestone: 16.01 → 16.04
tags: added: openstack sts
James Page (james-page) on 2016-02-09
tags: added: hitlist
Changed in cinder (Juju Charms Collection):
assignee: nobody → Billy Olsen (billy-olsen)
status: Triaged → In Progress
Changed in nova-cloud-controller (Juju Charms Collection):
status: Triaged → In Progress
Changed in nova-compute (Juju Charms Collection):
status: Triaged → In Progress
Changed in nova-cloud-controller (Juju Charms Collection):
assignee: nobody → Billy Olsen (billy-olsen)
Changed in nova-compute (Juju Charms Collection):
assignee: nobody → Billy Olsen (billy-olsen)
James Page (james-page) on 2016-02-17
Changed in cinder (Juju Charms Collection):
status: In Progress → Fix Committed
James Page (james-page) on 2016-02-18
Changed in nova-compute (Juju Charms Collection):
status: In Progress → Fix Committed
James Page (james-page) on 2016-02-19
Changed in nova-cloud-controller (Juju Charms Collection):
status: In Progress → Fix Committed
James Page (james-page) on 2016-04-22
Changed in nova-cloud-controller (Juju Charms Collection):
status: Fix Committed → Fix Released
Changed in nova-compute (Juju Charms Collection):
status: Fix Committed → Fix Released
Changed in cinder (Juju Charms Collection):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers