Bug 1306547

Summary: nova_catalog_admin_info and nova_catalog_info incorrectly configured during a packstack install
Product: Red Hat OpenStack Reporter: Lee Yarwood <lyarwood>
Component: openstack-packstackAssignee: Martin Magr <mmagr>
Status: CLOSED ERRATA QA Contact: Yogev Rabl <yrabl>
Severity: high Docs Contact:
Priority: unspecified    
Version: 8.0 (Liberty)CC: aortega, apevec, gcharot, ichavero, jschluet, lyarwood, mmagr, mnadeem, nlevinki, sgordon, tshefi, yeylon
Target Milestone: gaKeywords: Regression, TestOnly, ZStream
Target Release: 8.0 (Liberty)Flags: tshefi: automate_bug-
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: openstack-packstack-7.0.0-0.13.dev1702.g490e674.el7ost Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1425968 (view as bug list) Environment:
Last Closed: 2016-04-15 13:47:15 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1425968    

Description Lee Yarwood 2016-02-11 09:18:19 UTC
Description of problem:

# openstack-config --get /etc/cinder/cinder.conf DEFAULT nova_catalog_admin_info
compute:Compute Service:adminURL

# openstack-config --get /etc/cinder/cinder.conf DEFAULT nova_catalog_info
compute:Compute Service:publicURL

# grep -rin nova_catalog /usr/share/openstack-puppet/modules/cinder/
/usr/share/openstack-puppet/modules/cinder/manifests/api.pp:70:# [*nova_catalog_info*]
/usr/share/openstack-puppet/modules/cinder/manifests/api.pp:75:# [*nova_catalog_admin_info*]
/usr/share/openstack-puppet/modules/cinder/manifests/api.pp:76:#   (optional) Same as nova_catalog_info, but for admin endpoint.
/usr/share/openstack-puppet/modules/cinder/manifests/api.pp:169:  $nova_catalog_info           = 'compute:Compute Service:publicURL',
/usr/share/openstack-puppet/modules/cinder/manifests/api.pp:170:  $nova_catalog_admin_info     = 'compute:Compute Service:adminURL',
/usr/share/openstack-puppet/modules/cinder/manifests/api.pp:248:    'DEFAULT/nova_catalog_info':       value => $nova_catalog_info;
/usr/share/openstack-puppet/modules/cinder/manifests/api.pp:249:    'DEFAULT/nova_catalog_admin_info': value => $nova_catalog_admin_info;


Version-Release number of selected component (if applicable):
openstack-puppet-modules-7.0.6-2.el7ost.noarch
openstack-packstack-puppet-7.0.0-0.11.dev1692.g1b5e83b.el7ost.noarch

How reproducible:
Always

Steps to Reproduce:
1. Install an environment using packstack.

Actual results:
nova_catalog_admin_info and nova_catalog_info incorrectly configured. All novaclient calls from Cinder to Nova will fail as a result with EndpointNotFound, for example :

2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/volume/manager.py", line 1650, in _migrate_volume_generic
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher     new_volume['id'])
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/compute/nova.py", line 173, in update_server_volume
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher     novaclient(context).volumes.update_server_volume(server_id,
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/cinder/compute/nova.py", line 137, in novaclient
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher     **region_filter)
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher   File "/usr/lib/python2.7/site-packages/novaclient/service_catalog.py", line 84, in url_for
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher     raise novaclient.exceptions.EndpointNotFound()
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher EndpointNotFound
2016-02-10 10:13:43.010 23111 ERROR oslo_messaging.rpc.dispatcher

Expected results:
nova_catalog_admin_info and nova_catalog_info correctly configured allowing calls between Cinder and Nova to succeed.

Additional info:

Comment 2 Lee Yarwood 2016-02-11 09:21:46 UTC
Apologies, the following workaround should be listed under additional info :

# openstack catalog list
+------------+--------------+-------------------------------------------------------------------------------------+
| Name       | Type         | Endpoints                                                                           |
+------------+--------------+-------------------------------------------------------------------------------------+
| nova       | compute      | RegionOne                                                                           |
|            |              |   publicURL: http://192.168.122.204:8774/v2/eb29e1b11a604a0b82e1ad3ac38262b6        |
|            |              |   internalURL: http://192.168.122.204:8774/v2/eb29e1b11a604a0b82e1ad3ac38262b6      |
|            |              |   adminURL: http://192.168.122.204:8774/v2/eb29e1b11a604a0b82e1ad3ac38262b6         |
|            |              |                                                                                     |
[..]
# openstack-config --set /etc/cinder/cinder.conf DEFAULT nova_catalog_admin_info 'compute:nova:adminURL'
# openstack-config --set /etc/cinder/cinder.conf DEFAULT nova_catalog_info 'compute:nova:publicURL'
# openstack-service restart cinder

Comment 3 Alan Pevec 2016-02-18 17:48:01 UTC
Bug description is missing what's the actual impact!
IIUC from Martin this affects live migration which is OSP7 Packstack feature so this would be a regression hence blocker by definition.

Comment 4 Lee Yarwood 2016-02-18 18:12:50 UTC
(In reply to Alan Pevec from comment #3)
> Bug description is missing what's the actual impact!
> IIUC from Martin this affects live migration which is OSP7 Packstack feature
> so this would be a regression hence blocker by definition.

Apologies if it wasn't clear but the impact is well documented in the Actual results section, _any_ novaclient call from Cinder results in an EndpointNotFound exception being thrown. The example documented in c#0 shows Cinder attempting to update Nova after a volume retype/migration has completed.

Comment 9 Yogev Rabl 2016-04-10 13:14:24 UTC
verified on 
openstack-packstack-puppet-2015.1-0.16.dev1589.g1d6372f.el7ost.noarch

Comment 11 errata-xmlrpc 2016-04-15 13:47:15 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2016-0636.html

Comment 14 Gorka Eguileor 2018-03-23 09:47:04 UTC
*** Bug 1558897 has been marked as a duplicate of this bug. ***

Comment 15 Tzach Shefi 2019-07-18 08:55:50 UTC
Packstack isn't supported any longer as a deployment tool. 
Nothing to automate/test per close loop.