Bug 1264769 - set show_multiple_locations = true in glance configuration file
set show_multiple_locations = true in glance configuration file
Status: CLOSED ERRATA
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-tripleo-heat-templates (Show other bugs)
7.0 (Kilo)
x86_64 Linux
medium Severity medium
: rc
: 10.0 (Newton)
Assigned To: Giulio Fidente
Yogev Rabl
: Triaged
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-09-21 03:35 EDT by Yogev Rabl
Modified: 2016-12-14 10:16 EST (History)
7 users (show)

See Also:
Fixed In Version: openstack-tripleo-heat-templates-5.0.0-0.6.0rc3.el7ost
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-12-14 10:16:04 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
OpenStack gerrit 384926 None None None 2016-10-13 17:22 EDT

  None (edit)
Description Yogev Rabl 2015-09-21 03:35:34 EDT
Description of problem:
The parameter show_multiple_locations enables adding locations to images in glance. At the moment OSP Director sets the Glance configuration file according to default settings which set 
show_multiple_locations = false

Version-Release number of selected component (if applicable):
openstack-tripleo-0.0.7-0.1
openstack-tripleo-heat-templates-0.8.6-64
openstack-tripleo-puppet-elements-0.0.1-5

How reproducible:
100%

Steps to Reproduce:
1. Create an image 
2. Add a location to the image
# glance --os-image-api-version 2 location-add --url <url path> <image id>


Actual results:
the parameter show_multiple_locations is set to false by the OSP Director 
and when trying to add a location to an image an error massage says that administrator blocked this feature

Expected results:
the parameter is set as true. 
An additional location was added to the image
Comment 3 Emilien Macchi 2015-09-22 12:59:00 EDT
I have a doubt if we should enable the feature, it exposes some security risks.
https://github.com/openstack/glance/blob/master/glance/common/config.py#L119-L132

I would like some thoughts from Glance experts.
Comment 4 Flavio Percoco 2015-09-23 03:13:05 EDT
Enabling this feature by default is fine as long as the policies[0] are set to admin-only by default as well. Since I believe these policies should be set as admin-only by default, regardless, I think we should set them in OSPD and then we can enable this feature in the config file.

[0] https://github.com/openstack/glance/blob/master/etc/policy.json#L16-L18
Comment 6 Mike Burns 2016-04-07 16:50:54 EDT
This bug did not make the OSP 8.0 release.  It is being deferred to OSP 10.
Comment 10 Tzach Shefi 2016-11-13 03:34:06 EST
Verified
Build openstack-tripleo-heat-templates-5.0.0-1.4.el7ost.noarch


[root@controller-0 ~]# grep -i show_multiple /etc/glance/glance-api.conf 
#       ``show_multiple_locations`` MUST be set to ``False``.
#     * show_multiple_locations
#show_multiple_locations = false
show_multiple_locations = True ----> good for us, it's a CEPH backend. 


#glance image-create --name cirros --disk-format qcow2 --container-format bare --file cirros-0.3.4-x86_64-disk.img 
....
                                             |
| locations        | [{"url": "rbd://babb8e64-a67b-                                                   |
|                  | 11e6-8819-525400b77709/images/337a1573-a775-4153-a883-4764f22245ac/snap",        |

Image-show also shows image location
# glance image-show 337a1573-a775-4153-a883-4764f22245ac

a1573-a775-4153-a883-4764f22245ac                                             |
| locations        | [{"url": "rbd://babb8e64-a67b-                                                   |
|                  | 11e6-8819-525400b77709/images/337a1573-a775-4153-a883-4764f22245ac/snap",        |
Comment 12 errata-xmlrpc 2016-12-14 10:16:04 EST
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/RHEA-2016-2948.html

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