Bug 1966153 - Conditional gathering
Summary: Conditional gathering
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Insights Operator
Version: 4.9
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 4.9.0
Assignee: Serhii Zakharov
QA Contact: Dmitry Misharov
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-05-31 14:22 UTC by Serhii Zakharov
Modified: 2021-11-02 22:42 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
This PR implements a new gatherer needed by CCXDEV-4431. Right now it collects logs and image streams of namespace "openshift-cluster-samples-operator" if alert "SamplesImagestreamImportFailing" is firing, but it designed in a way that it can be further extended to run X gatherer with Y params on Z condition.
Clone Of:
Environment:
Last Closed: 2021-10-26 17:22:37 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift insights-operator pull 433 0 None Merged Conditional gathering 2021-11-02 22:40:39 UTC
Red Hat Product Errata RHBA-2021:3935 0 None None None 2021-10-26 17:22:48 UTC

Description Serhii Zakharov 2021-05-31 14:22:23 UTC
This PR implements a new gatherer needed by CCXDEV-4431. Right now it collects logs and image streams of namespace "openshift-cluster-samples-operator" if alert "SamplesImagestreamImportFailing" is firing, but it designed in a way that it can be further extended to run X gatherer with Y params on Z condition.

Comment 7 Dmitry Misharov 2021-10-20 08:20:24 UTC
Verified on 4.9.0-0.nightly-2021-10-20-023733.

Verification steps:

1. Disable Cluster Version Operator
oc scale --replicas 0 deployments/cluster-version-operator -n openshift-cluster-version
2. Disable Cluster Monitoring Operator
oc scale --replicas 0 deployment/cluster-monitoring-operator --namespace openshift-monitoring
3. Disable Prometheus Operator
oc scale --replicas 0 deployment/prometheus-operator --namespace openshift-monitoring
4. Edit "SamplesImagestreamImportFailing" alert in "prometheus-k8s-rulefiles-0" config map of "openshift-monitoring"
   4.1. Trigger the alert unconditionally using the following expression: "1 > bool 0"
   4.2. Decrease trigger time to "1m"
5. Wait until the alert will be firing
6. Create an image stream in "openshift-cluster-samples-operator" namespace
7. Restart the Insights Operator
8. Wait until an archive will be created
9. Download the archive

The archive contains "cluster-samples-operator" logs and the image stream manifest under "conditional" directory.

Comment 9 errata-xmlrpc 2021-10-26 17:22:37 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 (OpenShift Container Platform 4.9.4 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/RHBA-2021:3935

Comment 10 W. Trevor King 2021-11-02 22:42:34 UTC
Not clear to me why this got linked to the 4.9.4 errata; the backing PR landed in June, long before 4.9 forked off from master [1].  So the code was definitely in 4.9.0 as well.

[1]: https://github.com/openshift/insights-operator/pull/433#event-4950262577


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