Bug 1533097 - CephPools parameter does not add CephX permission for openstack user
Summary: CephPools parameter does not add CephX permission for openstack user
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-tripleo-heat-templates
Version: 12.0 (Pike)
Hardware: All
OS: Linux
medium
low
Target Milestone: z2
: 12.0 (Pike)
Assignee: Giulio Fidente
QA Contact: Yogev Rabl
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-01-10 13:14 UTC by Gregory Charot
Modified: 2018-03-28 17:17 UTC (History)
5 users (show)

Fixed In Version: openstack-tripleo-heat-templates-7.0.9-1.el7ost
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-03-28 17:16:42 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2018:0602 None None None 2018-03-28 17:17:11 UTC
OpenStack gerrit 537343 None stable/pike: MERGED tripleo-heat-templates: Set permissions for openstack keyring on CephPools (I4a8d185f0a1ff205525247719abb3b27aa187800) 2018-02-16 17:56:50 UTC
Launchpad 1742647 None None None 2018-01-11 09:49:01 UTC

Description Gregory Charot 2018-01-10 13:14:45 UTC
Description of problem:

CephPools parameter can be used to create additional Ceph Pools via tripleO

  CephPools:
    - name: tier2
      pg_num: 64

Pool's creation works fine but the openstack's user Ceph key is not updated therefore it is not usable by openstack unless an operator add the caps manually on the ceph cluster.

One could say this is a feature request, i would say that if a user uses director to deploy Ceph and create an extra pool it much likely means he plans on using it with openstack (new cinder backend, etc).

If for any reason this BZ is declined, please update the doc[1] to mention that users need to update ceph key caps manually.


https://access.redhat.com/documentation/en-us/red_hat_openstack_platform/12/html-single/deploying_an_overcloud_with_containerized_red_hat_ceph/#custom-ceph-pools

Version-Release number of selected component (if applicable):

12

How reproducible:

Always

Steps to Reproduce:
1. 
  CephPools:
    - name: tier2
      pg_num: 64
2. Deploy 
3. 

Actual results:
ceph auth get  client.openstack
exported keyring for client.openstack
[client.openstack]
        key = AQC79lNaAAAAABAAxYvFr+ENT0vI79fCoyquHg==
        caps mon = "allow r"
        caps osd = "allow rwx pool=volumes, allow rwx pool=backups, allow rwx pool=vms, allow rwx pool=images, allow rwx pool=metrics

Expected results:

ceph auth get  client.openstack
exported keyring for client.openstack
[client.openstack]
        key = AQC79lNaAAAAABAAxYvFr+ENT0vI79fCoyquHg==
        caps mon = "allow r"
        caps osd = "allow rwx pool=volumes, allow rwx pool=backups, allow rwx pool=vms, allow rwx pool=images, allow rwx pool=metrics, allow rwx pool=tier2"

Additional info:


the custom pool(s) are included as part of openstack_pools but not as part of the openstack_keys.

          openstack_pools:
            list_concat_unique:
              - repeat:
                  template:
                    name: <%pool%>
                    pg_num: {get_param: CephPoolDefaultPgNum}
                    rule_name: ""
                  for_each:
                    <%pool%>:
                      - {get_param: CinderRbdPoolName}
                      - {get_param: CinderBackupRbdPoolName}
                      - {get_param: NovaRbdPoolName}
                      - {get_param: GlanceRbdPoolName}
                      - {get_param: GnocchiRbdPoolName}
              - {get_param: CephPools} # <- HERE

          openstack_keys: &openstack_keys
          - name:
              list_join:
              - '.'
              - - client
                - {get_param: CephClientUserName}
            key: {get_param: CephClientKey}
            mon_cap: "allow r"
            osd_cap:
              str_replace:
               template: "allow class-read object_prefix rbd_children, allow rwx pool=CINDER_POOL, allow rwx pool=CINDERBACKUP_POOL, allow rwx pool=NOVA_POOL, allow rwx pool=GLANCE_POOL, allow rwx pool=GNOCCHI_POOL"   # <- NO CephPools inclusion
               params:
                 NOVA_POOL: {get_param: NovaRbdPoolName}
                 CINDER_POOL: {get_param: CinderRbdPoolName}
                 CINDERBACKUP_POOL: {get_param: CinderBackupRbdPoolName}
                 GLANCE_POOL: {get_param: GlanceRbdPoolName}
                 GNOCCHI_POOL: {get_param: GnocchiRbdPoolName}
            mode: "0644"

Comment 4 Yogev Rabl 2018-03-14 17:43:13 UTC
verified

Comment 7 errata-xmlrpc 2018-03-28 17:16:42 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://access.redhat.com/errata/RHSA-2018:0602


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