Bug 1717738 - clusteroperator/machine-config does not define enough related resources
Summary: clusteroperator/machine-config does not define enough related resources
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Machine Config Operator
Version: 4.1.0
Hardware: Unspecified
OS: Unspecified
unspecified
high
Target Milestone: ---
: 4.1.z
Assignee: Antonio Murdaca
QA Contact: Micah Abbott
URL:
Whiteboard: 4.1.3
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-06-06 03:31 UTC by Luis Sanchez
Modified: 2019-06-26 08:51 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-06-26 08:50:23 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:1589 0 None None None 2019-06-26 08:51:05 UTC

Description Luis Sanchez 2019-06-06 03:31:06 UTC
Description of problem:

The machine-config ClusterOperator resource does not specify enough related resources. This hinders problem-determination as tools cannot automatically collect the information needed to debug issues.

The operator should specify, at minimum, a namespace and a configuration resource to collect.

Here is an example from kube-apisever:

kind: ClusterOperator
metadata:
  name: kube-apiserver
status:
  relatedObjects:
    - group: operator.openshift.io
      name: cluster
      resource: kubeapiservers
    - group: ''
      name: openshift-config
      resource: namespaces
    - group: ''
      name: openshift-config-managed
      resource: namespaces
    - group: ''
      name: openshift-kube-apiserver-operator
      resource: namespaces
    - group: ''
      name: openshift-kube-apiserver
      resource: namespaces


A new e2e test designed to catch this deficiency will white-list this component initially. This component should be removed from the white-list as part of resolving this issue.

https://github.com/openshift/origin/blob/master/test/extended/operators/clusteroperators.go (link will be active once https://github.com/openshift/origin/pull/23044 merges)

Comment 1 Antonio Murdaca 2019-06-06 07:26:32 UTC
The MCO has namespace as related resource to collect but we don't have any MCO config as of today (and I'm having an hard time understanding why we mandate that in any way). Commented on the PR as well.

Comment 2 Antonio Murdaca 2019-06-06 08:45:48 UTC
I've added some additional resources meanwhile here: https://github.com/openshift/machine-config-operator/pull/825

Comment 3 Antonio Murdaca 2019-06-06 15:14:00 UTC
https://github.com/openshift/machine-config-operator/pull/830 is the 4.1 backport

Comment 5 Antonio Murdaca 2019-06-06 17:09:45 UTC
The backport isn't merged yet :|

moving back to POST

Comment 8 Micah Abbott 2019-06-19 19:31:48 UTC
Verified with 4.1.0-0.nightly-2019-06-19-033215

```
$ oc get clusterversion                                                                                           
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS                                                                                                                              
version   4.1.0-0.nightly-2019-06-19-033215   True        False         168m    Cluster version is 4.1.0-0.nightly-2019-06-19-033215 

$ ./openshift-must-gather inspect clusteroperator/machine-config                                                    
2019/06/19 15:29:20 Gathering config.openshift.io resource data...                                                                                                                                                  
2019/06/19 15:29:22 Gathering kubeapiserver.operator.openshift.io resource data...
2019/06/19 15:29:22 Gathering cluster operator resource data...
2019/06/19 15:29:22     Gathering related object reference information for ClusterOperator "machine-config"...
2019/06/19 15:29:22     Found related object "namespaces/openshift-machine-config-operator" for ClusterOperator "machine-config"...
2019/06/19 15:29:22     Found related object "machineconfigpools.machineconfiguration.openshift.io/master" for ClusterOperator "machine-config"...
2019/06/19 15:29:22     Found related object "machineconfigpools.machineconfiguration.openshift.io/worker" for ClusterOperator "machine-config"...
2019/06/19 15:29:22     Found related object "controllerconfigs.machineconfiguration.openshift.io/cluster" for ClusterOperator "machine-config"...
2019/06/19 15:29:22 Gathering data for ns/openshift-machine-config-operator...
2019/06/19 15:29:22     Collecting resources for namespace "openshift-machine-config-operator"...
2019/06/19 15:29:22     Gathering pod data for namespace "openshift-machine-config-operator"...
...
```

Comment 11 errata-xmlrpc 2019-06-26 08:50:23 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, 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-2019:1589


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