Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
This project is now read‑only. Starting Monday, February 2, please use https://ibm-ceph.atlassian.net/ for all bug tracking management.

Bug 1929155

Summary: [cephadm][RGW]: Cannot use external zonegroup with cephadm
Product: [Red Hat Storage] Red Hat Ceph Storage Reporter: Tejas <tchandra>
Component: CephadmAssignee: Daniel Pivonka <dpivonka>
Status: CLOSED NOTABUG QA Contact: Vasishta <vashastr>
Severity: urgent Docs Contact: Karen Norteman <knortema>
Priority: unspecified    
Version: 5.0CC: vereddy
Target Milestone: ---   
Target Release: 5.0   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-03-11 20:37:04 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: 1933981    

Description Tejas 2021-02-16 10:20:04 UTC
Description of problem:
  There is no provision in cephadm to use a user created zonegroup for RGW. 

Version-Release number of selected component (if applicable):
ceph version 16.0.0-7953.el8cp (aac7c5c7d5f82d2973c366730f65255afd66e515) pacific (dev)


We create a realm,ZG and zone as per user specifications

 /]# radosgw-admin realm create --rgw-realm=rh --default
/]# radosgw-admin zonegroup create --rgw-zonegroup=redhat --master --default
/]# radosgw-admin zone create --rgw-zonegroup=redhat --rgw-zone=internal --master --default
 /]# radosgw-admin period update --rgw-realm=rh --commit


To start a RGW in this specification is not possible in cephadm right  now.

 /]# ceph orch apply rgw rh redhat internal --placement="ceph-tejas-1612942326361-node7-rgw-node-exporter"
Scheduled rgw.rh.redhat.internal update...

/]# radosgw-admin zonegroup list
{
    "default_info": "361e41c5-58ec-4df4-b8f4-5fd59b7148eb",
    "zonegroups": [
        "redhat",
        "default"
    ]
}

 /]# radosgw-admin zone list
{
    "default_info": "1c0d0b65-ad73-449e-ab54-1f95b34005f1",
    "zones": [
        "redhat",
        "internal"
    ]
}


Or through a spec file either 
/]# ceph orch apply -i rgw1.yaml 
Error EINVAL: ServiceSpec: __init__() got an unexpected keyword argument 'rgw_zonegroup'

Comment 1 Daniel Pivonka 2021-03-11 20:37:04 UTC
You can use a user created zonegroup. 

radosgw-admin realm create --rgw-realm=rh --default
radosgw-admin zonegroup create --rgw-zonegroup=redhat --master --default
radosgw-admin zone create --rgw-zonegroup=redhat --rgw-zone=internal --master --default
radosgw-admin period update --rgw-realm=rh --commit
ceph orch apply rgw rh internal

That ^ would use the zonegroup “redhat”


please be aware of changes from

upstream fix PR: https://github.com/ceph/ceph/pull/39877/files

* The ``ceph orch apply rgw`` syntax and behavior have changed.  RGW
  services can now be arbitrarily named (it is no longer forced to be
  `realm.zone`).  The ``--rgw-realm=...`` and ``--rgw-zone=...``
  arguments are now optional, which means that if they are omitted, a
  vanilla single-cluster RGW will be deployed.  When the realm and
  zone are provided, the user is now responsible for setting up the
  multisite configuration beforehand--cephadm no longer attempts to
  create missing realms or zones.