Bug 1183946

Summary: Glance's default_store parameter is set in the wrong section
Product: Red Hat OpenStack Reporter: Yogev Rabl <yrabl>
Component: openstack-foreman-installerAssignee: Crag Wolfe <cwolfe>
Status: CLOSED DUPLICATE QA Contact: Ami Jeain <ajeain>
Severity: urgent Docs Contact:
Priority: high    
Version: 6.0 (Juno)CC: bjayavel, gchamoul, kschinck, mburns, morazi, rhos-maint, srevivo, yeylon
Target Milestone: z2Keywords: UserExperience, ZStream
Target Release: Installer   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-03-04 16:32:21 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:

Description Yogev Rabl 2015-01-20 09:16:55 UTC
Description of problem:
In the Glnace configuration the 'default_store' parameter is set in the glance_store section. 
- This parameter should be set in the DEFAULT section.
- In the glance_store section the store is set with the 'store' parameter. 

This changes of sections cause post installation changes harder due to misplaced parameters. 

Version-Release number of selected component (if applicable):
ruby193-rubygem-staypuft-0.5.12-1.el7ost.noarch

How reproducible:
100%

Steps to Reproduce:
1. Install Glance with staypuft

Actual results:
The 'default_store' is set in the wrong section.

Expected results:
The 'default_store' parameter should not be used at all (not in the DEFAULT section and neither in the glance_store section) and the store is set in the glance_store section in the 'store' parameter.

Additional info:

Comment 3 Mike Burns 2015-01-20 12:55:28 UTC
Yogev, 

does the configuration work as is?  or are things broken?

Comment 4 Crag Wolfe 2015-01-28 19:22:13 UTC
The configuration in question takes place in

https://github.com/redhat-openstack/openstack-puppet-modules/blob/master/glance/manifests/backend/rbd.pp 

Specifically, it looks like

'glance_store/default_store': value => 'rbd';

should be changed to

'glance_store/stores': value => 'glance.store.rbd.Store';

Comment 5 Mike Burns 2015-01-28 19:28:56 UTC
*** Bug 1186881 has been marked as a duplicate of this bug. ***

Comment 6 Shai Revivo 2015-01-29 14:24:51 UTC
i am suggesting it for A1 as it looks like ROI is very high here.
current state is install finish with configuration problems that might prevent backend from working and by config change we can make it right (and consistent with pack stack)

Comment 8 Gaël Chamoulaud 2015-03-04 16:18:17 UTC
Well, we have to use the $know_stores parameter (glance::api class) to get the default_stores/stores well-configured [1].

By default $know_stores is false [2], you need to add $know_stores = ['glance.store.rbd.Store'] to the glance::api call!

So it's not an openstack-puppet-modules bug.

[1] - https://github.com/redhat-openstack/openstack-puppet-modules/blob/master/glance/manifests/api.pp#L298-L307
[2] - https://github.com/redhat-openstack/openstack-puppet-modules/blob/master/glance/manifests/api.pp#L213

Comment 10 Gaël Chamoulaud 2015-03-04 16:32:21 UTC
Jayg already proposed the fix in https://bugzilla.redhat.com/show_bug.cgi?id=1192862#c9 as proposed in my last comment.

So I think this one should be closed as duplicate of 1192862

*** This bug has been marked as a duplicate of bug 1192862 ***