Bug 1857304 - [Independent Mode]Make --rgw-endpoint an optional parameter in ceph-external-cluster-details-exporter.py script
Summary: [Independent Mode]Make --rgw-endpoint an optional parameter in ceph-external-...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenShift Container Storage
Classification: Red Hat Storage
Component: rook
Version: 4.5
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: OCS 4.5.0
Assignee: Sébastien Han
QA Contact: Sidhant Agrawal
URL:
Whiteboard:
Depends On:
Blocks: 1862133 1862449 1866155
TreeView+ depends on / blocked
 
Reported: 2020-07-15 15:59 UTC by Neha Berry
Modified: 2020-09-23 09:07 UTC (History)
6 users (show)

Fixed In Version: 4.5.0-515.ci
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1862133 1862449 (view as bug list)
Environment:
Last Closed: 2020-09-15 10:18:18 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift rook pull 93 0 None closed Bug 1857304: ceph: make 'rgw_endpoint' check/validation also optional 2020-12-02 19:36:33 UTC
Github rook rook pull 5899 0 None closed ceph: make rgw option on external script 2020-12-02 19:37:02 UTC
Red Hat Product Errata RHBA-2020:3754 0 None None None 2020-09-15 10:18:47 UTC

Description Neha Berry 2020-07-15 15:59:29 UTC
Description of problem (please be detailed as possible and provide log
snippests):
----------------------------------------------------------------------
OCS 4.5 + OCP 4.5+ External Mode deployment : Using below command to gather RHCS information in json format:

>> python ceph-external-cluster-details-exporter.py --rgw-endpoint <rgw-endpoint IP:port> --rbd-data-pool-name <rbd block pool name>

Some RHCS customers  might not have RGW. Hence, requesting the param "--rgw-endpoint" to be optional. 

Impact on OCS deployment: AFAIU, this should ensure the following(there might be other impacts, but some of the following are:)

1. The json would not have RGW endpoint, hence ocs-operator should not create the RGW storageclass
2. The cephObjectstoreUser CRD should not be deployed. Then noobaa backingstore would fall-back to using local-PV




Version of all relevant components (if applicable):
----------------------------------------------------------------------
OCP = 4.5.0-0.nightly-2020-07-06-211538
OCS = ocs-operator.v4.5.0-487.ci



Does this issue impact your ability to continue to work with the product
(please explain in detail what is the user impact)?
----------------------------------------------------------------------
Yes. In current implementation, For clusters not having an RGW configured, we pass a dummy IP. The Storagecluster gets created with an incorrect RGW endpoint, and the CSV stays in Installing state forever (doesnt reach Succeeded state)


Is there any workaround available to the best of your knowledge?
----------------------------------------------------------------------
Not sure


Rate from 1 - 5 the complexity of the scenario you performed that caused this
bug (1 - very simple, 5 - very complex)?
----------------------------------------------------------------------
4

Can this issue reproducible?
----------------------------------------------------------------------
Yes

Can this issue reproduce from the UI?
----------------------------------------------------------------------
Yes

If this is a regression, please provide more details to justify this:
----------------------------------------------------------------------
No.. External Mode is a new feature of OCS in OCS 4.5


Steps to Reproduce:
----------------------------------------------------------------------
1. Create an RHCS cluster (probably without an RGW endpoint configured)
2. Run the script but without passing --rgw-endpoint

i.e. >> python ceph-external-cluster-details-exporter.py --rbd-data-pool-name <rbd block pool name>

Current Output
--------------------
# python3 ceph-external.py --rbd-data-pool-name ocs-cephblockpool-dc8
usage: ceph-external.py [-h] [--verbose] [--ceph-conf CEPH_CONF]
                        [--run-as-user RUN_AS_USER] [--format {json,bash}]
                        [--cluster-name CLUSTER_NAME] [--output OUTPUT]
                        [--cephfs-filesystem-name CEPHFS_FILESYSTEM_NAME]
                        [--cephfs-data-pool-name CEPHFS_DATA_POOL_NAME]
                        --rbd-data-pool-name RBD_DATA_POOL_NAME
                        [--namespace NAMESPACE]
                        [--rgw-pool-prefix RGW_POOL_PREFIX] --rgw-endpoint
                        RGW_ENDPOINT
>> Ceph-external.py: error: the following arguments are required: --rgw-endpoint





Actual results:
----------------------------------------------------------------------
If we run the script without --rgw-endpoint, following error is thrown: "Ceph-external.py: error: the following arguments are required: --rgw-endpoint"

Expected results:
----------------------------------------------------------------------
Customers might have an RHCS cluster without RGW. Hence, --rgw-endpoint should be optional parameter.

Additional info:
----------------------------------------------------------------------

We have one more BZ for having correct check for --rgw-endpoint(in case one uses the param but with a wrong input) - https://bugzilla.redhat.com/show_bug.cgi?id=1850704

Comment 2 Neha Berry 2020-07-15 16:00:31 UTC
Proposing as a blocker as it would be a good user experience to not have this field mandatory.

Comment 3 Neha Berry 2020-07-15 16:20:05 UTC
@arun wi

Comment 4 Sébastien Han 2020-07-17 07:01:06 UTC
Neha, I don't think there is such use case as rgw not being deployed, unless we run on the Cloud but independent mode won't be supported then (until we support ocs to ocs).
Eran, please confirm. Thanks

Comment 5 Neha Berry 2020-07-17 07:11:58 UTC
(In reply to leseb from comment #4)
> Neha, I don't think there is such use case as rgw not being deployed, unless
> we run on the Cloud but independent mode won't be supported then (until we
> support ocs to ocs).
> Eran, please confirm. Thanks

@Sebastien, I tried to confirm the same in this chat thread (https://chat.google.com/room/AAAAqKX_vdQ/vmxr_zlAOg4) and it seems

--------------------------------------------------------------------------------------------------------
About 80% of core Ceph customer base (non openstack) uses RGW . 
-------------------------------------------------------------------------------------------------------

So there can be customers without RGW.. AFAIU.. Either we have to strongly enforce presence of RGW in External cluster OR we have to let OCS install succeed even in the absence of RGW

Will Wait for Eran's confirmation too.

Comment 6 Eran Tamir 2020-07-22 15:37:51 UTC
If it's simple, let's make it optional, as we have fallback in place with NooBaa.

Comment 7 Sébastien Han 2020-07-22 15:45:22 UTC
Thanks Eran, now that I think about it I'm not sure if the UI will fail to validate the JSON if the endpoint is not present.

Bipul, can you help on this? Thanks!

Comment 8 Bipul Adhikari 2020-07-27 07:28:09 UTC
Will send a PR on OCS Operator to make rgw optional as the UI validation is based on the anootation provided by the OCS Operator.

Comment 9 Mudit Agarwal 2020-07-31 12:53:56 UTC
We don't have any acks on this bug but the downstream PR seems to be merged. We should have merged it after getting all the acks.

@Seb, please provide the dev ack. Also, is some work still required in this or can it be moved to ON_QA once we have all the acks?

Comment 12 Sébastien Han 2020-08-03 07:52:39 UTC
Acked. This can be moved to ON_QA.

Comment 19 errata-xmlrpc 2020-09-15 10:18:18 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 (Red Hat OpenShift Container Storage 4.5.0 bug fix and enhancement update), 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/RHBA-2020:3754


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