Bug 2030839 - Concecutive dashes in OBC name
Summary: Concecutive dashes in OBC name
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenShift Data Foundation
Classification: Red Hat Storage
Component: Multi-Cloud Object Gateway
Version: 4.7
Hardware: All
OS: All
unspecified
low
Target Milestone: ---
: ODF 4.10.0
Assignee: Danny
QA Contact: Mugdha Soni
URL:
Whiteboard:
Depends On:
Blocks: 2037497
TreeView+ depends on / blocked
 
Reported: 2021-12-09 20:39 UTC by swilson
Modified: 2023-08-09 16:49 UTC (History)
10 users (show)

Fixed In Version: 4.10.0-79
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 2037497 (view as bug list)
Environment:
Last Closed: 2022-04-13 18:50:40 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github kube-object-storage lib-bucket-provisioner pull 220 0 None Merged fixed bug in generateBucketName 2022-01-19 09:55:00 UTC
Github noobaa noobaa-operator pull 831 0 None Merged updated dependency to latest lib-bucket-provisioner 2022-01-19 09:55:02 UTC
Red Hat Product Errata RHSA-2022:1372 0 None None None 2022-04-13 18:51:13 UTC

Description swilson 2021-12-09 20:39:55 UTC
NooBaa seems to be allowing the provisioning of some buckets with consecutive dashes in the OBC name. The OBC name generates a OB with the same name and a random suffix. From within the NooBaa UI, a bucket cannot be provisioned with consecutive dashes. However, in OCP you can use an OBC name with consecutive dashes and the bucket is provisioned.

Version of all relevant components (if applicable): All


Does this issue impact your ability to continue to work with the product
(please explain in detail what is the user impact)? No


Is there any workaround available to the best of your knowledge? Do not provision bucket with consecutive dashes


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


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: Unknown


Steps to Reproduce:
1. Provision OBC in OCP UI with consecutive dashes
2. Try to provision bucket with consecutive dashes in NooBaa UI
3. The OBC will provision in OCP
4. The bucket will not be provisioned from within the NooBaa UI


Actual results:
OBCs provisioned in OCP with consecutive dashes.


Expected results:
OBCs not provisioned with consecutive dashes


Additional info:

Comment 3 swilson 2021-12-13 23:46:07 UTC
Update:

Cannot provision bucket with name analytics-data-sync--bucket. Can provision OBC named analytics-data-sync--bucket2

Comment 4 Danny 2022-01-04 11:18:10 UTC
This is a bug in lib-bucket-provisioner. it is not related to consecutive dashes. 
when the prefix length is exactly 27, the prefix is not truncated. as a result, when adding a UUID, the generated bucket name is invalid.
I issued a fix here https://github.com/kube-object-storage/lib-bucket-provisioner/pull/220. once it is merged I will update the dependency in noobaa-operator

Comment 9 Mugdha Soni 2022-02-01 08:51:00 UTC
Hi Danny 

Below i have mentioned the steps to validate the fix . Please correct me if am wrong or if am missing any point.

1. Create an OBC named "analytics-data-sync--bucket", or any other 27-char long str .
2. The OBC should bind, and the last char of the name should be truncated.

Thanks 
Mugdha Soni

Comment 10 Danny 2022-02-02 10:04:52 UTC
Hi Mugdha,

1 is correct. regarding 2, it's not the OBC name that should be truncated, but the prefix of the name of the underlying bucket in noobaa that is truncated. this prefix is based on the OBC name, and AFAIR can be found in the ob spec (not OBC but the ObjectBucket corresponding with the OBC).

Thanks,
Danny

Comment 11 Mugdha Soni 2022-02-02 13:42:07 UTC
Thanks Danny . Will share the inputs by tomorrow EOD .

Comment 16 Mugdha Soni 2022-03-01 06:37:08 UTC
Hi 

After discussion with the assignee and comment#15 moving this bug to verified state .

Thanks 
Mugdha Soni

Comment 18 errata-xmlrpc 2022-04-13 18:50:40 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 (Important: Red Hat OpenShift Data Foundation 4.10.0 enhancement, security & bug fix 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/RHSA-2022:1372


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