Bug 1817860 - Some of `oc adm inspect co/xx` failed with error
Summary: Some of `oc adm inspect co/xx` failed with error
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Cloud Compute
Version: 4.5
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 4.5.0
Assignee: Alberto
QA Contact: Milind Yadav
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-03-27 06:47 UTC by zhou ying
Modified: 2020-08-27 22:35 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1817938 (view as bug list)
Environment:
Last Closed: 2020-08-27 22:35:18 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github openshift cluster-autoscaler-operator pull 147 0 None closed Bug 1817860: Fix API group on related resources 2021-02-13 21:49:44 UTC
Github openshift machine-api-operator pull 548 0 None closed Bug 1817860: Drop non existent object from relatedResources 2021-02-13 21:49:44 UTC

Description zhou ying 2020-03-27 06:47:43 UTC
Description of problem:
Use `oc adm inspect co/machine-api` met error:  skipping gathering roles.rbac.authorization.k8s.io/cloud-provider-config-reader due to error: roles.rbac.authorization.k8s.io "cloud-provider-config-reader" not found

`oc adm inspect co/cluster-autoscaler` failed with error: 
error: errors ocurred while gathering data:
    [skipping gathering machineautoscalers.machine.openshift.io due to error: the server doesn't have a resource type "machineautoscalers", skipping gathering clusterautoscalers.machine.openshift.io due to error: the server doesn't have a resource type "clusterautoscalers"]

`oc adm inspect co/monitoring` failed with error:
error: errors ocurred while gathering data:
    skipping gathering all/openshift-monitoring due to error: the server doesn't have a resource type "all"


Version-Release number of selected component (if applicable):
[root@dhcp-140-138 ~]# oc version 
Client Version: 4.5.0-202003252116-11cbaa8
Server Version: 4.5.0-0.nightly-2020-03-26-233202


How reproducible:
always

Steps to Reproduce:
1. Create cluster
2. Use command : `oc adm inspect co/machine-api`
3. `oc adm inspect co/cluster-autoscaler`
4. `oc adm inspect co/monitoring`

Actual results:
2. Met error: skipping gathering roles.rbac.authorization.k8s.io/cloud-provider-config-reader due to error: roles.rbac.authorization.k8s.io "cloud-provider-config-reader" not found

3. Met error: 
skipping gathering machineautoscalers.machine.openshift.io due to error: the server doesn't have a resource type "machineautoscalers", skipping gathering clusterautoscalers.machine.openshift.io due to error: the server doesn't have a resource type "clusterautoscalers"

4. Met error:
skipping gathering all/openshift-monitoring due to error: the server doesn't have a resource type "all"

Expected results:
2-4. Should works well



Additional info:

Comment 1 Maciej Szulik 2020-03-27 09:14:53 UTC
Data gathered by oc adm inspect are coming from cluster operator's .status.relatedObjects so please fill in those BZ for appropriate operator owners.
I'm splitting this into 3 distinct and assigning them to appropriate teams.

Comment 2 Maciej Szulik 2020-03-27 09:18:29 UTC
This bug goes to machine team, make sure that your .status.relatedObjects reflect reality and don't produce below error:

Use `oc adm inspect co/machine-api` met error:  skipping gathering roles.rbac.authorization.k8s.io/cloud-provider-config-reader due to error: roles.rbac.authorization.k8s.io "cloud-provider-config-reader" not found

Comment 3 Maciej Szulik 2020-03-27 09:19:27 UTC
Actually:

`oc adm inspect co/cluster-autoscaler` failed with error: 
error: errors ocurred while gathering data:
    [skipping gathering machineautoscalers.machine.openshift.io due to error: the server doesn't have a resource type "machineautoscalers", skipping gathering clusterautoscalers.machine.openshift.io due to error: the server doesn't have a resource type "clusterautoscalers"]

is also the same team, I think.

Comment 4 Pawel Krupa 2020-03-27 11:30:34 UTC
Fix for `skipping gathering all/openshift-monitoring due to error: the server doesn't have a resource type "all"` is present at https://github.com/openshift/cluster-monitoring-operator/pull/726

Comment 8 Milind Yadav 2020-04-09 06:52:43 UTC
Verified on:
[miyadav@miyadav clusterroles]$ oc get clusterversion
NAME      VERSION                             AVAILABLE   PROGRESSING   SINCE   STATUS
version   4.5.0-0.nightly-2020-04-09-005126   True        False         3h4m    Cluster version is 4.5.0-0.nightly-2020-04-09-005126

Steps:
1.Run oc adm inspect co/machine-api

Actual & Expected : Gathering data for ns/openshift-machine-api...
Wrote inspect data to inspect.local.388961362203275215.

2.Run  oc adm inspect co/cluster-autoscaler

Actual & Expected : 
Gathering data for ns/openshift-machine-api...
Wrote inspect data to inspect.local.1167060908678841821.

3.Run oc adm inspect co/monitoring

Actual :Gathering data for ns/openshift-monitoring...
E0409 12:06:45.800418   26884 portforward.go:400] an error occurred forwarding 37587 -> 9094: error forwarding port 9094 to pod 669fc5bdc77731461b249ad0df1def3beb5a6aaf4a89f9bd0779018543e88f22, uid : exit status 1: 2020/04/09 06:36:45 socat[436812] E connect(5, AF=2 127.0.0.1:9094, 16): Connection refused
E0409 12:06:47.168582   26884 portforward.go:400] an error occurred forwarding 37587 -> 9094: error forwarding port 9094 to pod 669fc5bdc77731461b249ad0df1def3beb5a6aaf4a89f9bd0779018543e88f22, uid : exit status 1: 2020/04/09 06:36:47 socat[436905] E connect(5, AF=2 127.0.0.1:9094, 16): Connection refused
E0409 12:06:48.594141   26884 portforward.go:400] an error occurred forwarding 37587 -> 9094: error forwarding port 9094 to pod 669fc5bdc77731461b249ad0df1def3beb5a6aaf4a89f9bd0779018543e88f22, uid : exit status 1: 2020/04/09 06:36:48 socat[436913] E connect(5, AF=2 127.0.0.1:9094, 16): Connection refused
E0409 12:06:50.112752   26884 portforward.go:400] an error occurred forwarding 37587 -> 9094: error forwarding port 9094 to pod 669fc5bdc77731461b249ad0df1def3beb5a6aaf4a89f9bd0779018543e88f22, uid : exit status 1: 2020/04/09 06:36:49 socat[437006] E connect(5, AF=2 127.0.0.1:9094, 16): Connection refused

which is not expected

Comment 9 Alberto 2020-04-13 08:06:58 UTC
Hey Milind, https://bugzilla.redhat.com/show_bug.cgi?id=1817860#c8 this seems unrelated to the original issue where the related resources for mao/cao do not exist that the linked PRs should fix.
Can you verify https://bugzilla.redhat.com/show_bug.cgi?id=1817860#c8 is not a generic issue with your particular env or with oc adm inspect, and if so create a particular different issue for oc adm inspect being broken against the appropriate team?

Comment 10 Milind Yadav 2020-04-13 09:09:52 UTC
I ran on different env. got the same error - for  oc adm inspect co/monitoring , checking if it has to be raised to different team , will update here ..

Comment 11 Milind Yadav 2020-04-13 09:20:00 UTC
Thanks Alberto for comment#9 , moving to VERIFIED as oc adm inspect co/machine-api & oc adm inspect co/cluster-operator is working fine

Comment 12 Luke Meyer 2020-08-27 22:35: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, 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:2409'


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