Bug 2179235 - [Fusion-aaS][4.12.z clone] Within 'prometheus-ceph-rules' the namespace for 'rook-ceph-mgr' jobs should be configurable.
Summary: [Fusion-aaS][4.12.z clone] Within 'prometheus-ceph-rules' the namespace for '...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenShift Data Foundation
Classification: Red Hat Storage
Component: ceph-monitoring
Version: 4.12
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: ODF 4.12.3
Assignee: arun kumar mohan
QA Contact: Filip Balák
URL:
Whiteboard:
Depends On: 2168840
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-03-17 05:44 UTC by Nitin Goyal
Modified: 2023-08-09 16:37 UTC (History)
12 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of: 2168840
Environment:
Last Closed: 2023-05-23 09:17:28 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github red-hat-storage ocs-operator pull 2020 0 None open Bug 2179235:[release-4.12] Change any embedded namespace to current one 2023-04-20 08:12:28 UTC
Github red-hat-storage ocs-operator pull 2021 0 None open Bug 2179235:[release-4.12] Added 'namespace' tag to queries 2023-04-20 08:12:37 UTC
Red Hat Product Errata RHSA-2023:3265 0 None None None 2023-05-23 09:18:05 UTC

Description Nitin Goyal 2023-03-17 05:44:07 UTC
+++ This bug was initially created as a clone of Bug #2168840 +++

Description of problem (please be detailed as possible and provide log
snippets):

The namespace openshift-storage is hardcoded for rook-ceph-mgr jobs under the prometheus-ceph-rules. This will only search for jobs in the openshift-storage namespace. We wanted to make this name configurable for Rosa because MS will not be using openshift-storage namespace anymore. It should be the namespace of storagecluster.


Version of all relevant components (if applicable):


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


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


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


Can this issue reproducible?


Can this issue reproduce from the UI?


If this is a regression, please provide more details to justify this:


Steps to Reproduce:
1.
2.
3.


Actual results:


Expected results:


Additional info:

link to the rule: https://github.com/red-hat-storage/ocs-operator/blob/83103d3b3f0bfbdd7446db1f7230de0e15ebbe02/controllers/storagecluster/prometheus/localcephrules.yaml#L45

Comment 9 Filip Balák 2023-05-02 11:33:00 UTC
The rule for alert CephMgrIsAbsent is still hardcoded in odf-operator v4.12.3-12:

label_replace((up{job="rook-ceph-mgr"} == 0 or absent(up{job="rook-ceph-mgr"})), "namespace", "openshift-storage", "", "")

--> ASSIGNED

Comment 10 arun kumar mohan 2023-05-03 10:35:42 UTC
@fbalak , can you just confirm the namespace where the StorageSystem (or ODF Cluster) was installed.
If we install it under 'openshift-storage' namespace, we will still see the same ('openshift-storage') namespace hardcoded in the alerts.

So if we want to see any change, we should be installing cluster under different namespace (so that ocs-operator will put/apply all the 'PrometheusRules' yaml files in a different namespace)

Comment 11 Filip Balák 2023-05-03 11:25:06 UTC
The namespace is no longer hardcoded as verified by Jilju.

Comment 18 errata-xmlrpc 2023-05-23 09:17:28 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 (Moderate: Red Hat OpenShift Data Foundation 4.12.3 Security and 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-2023:3265


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