Bug 1704573 - prometheus-k8s serviceaccount cannot list endpoints in the namespace openshift-etcd
Summary: prometheus-k8s serviceaccount cannot list endpoints in the namespace openshif...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Monitoring
Version: unspecified
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 4.1.0
Assignee: Frederic Branczyk
QA Contact: Peter Ruan
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-04-30 05:49 UTC by Junqi Zhao
Modified: 2019-06-04 10:48 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-06-04 10:48:18 UTC
Target Upstream Version:


Attachments (Terms of Use)
prometheus-k8s pod logs (2.69 MB, text/plain)
2019-04-30 05:49 UTC, Junqi Zhao
no flags Details
prometheus-k8s sa info (26.62 KB, text/plain)
2019-04-30 05:53 UTC, Junqi Zhao
no flags Details


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2019:0758 None None None 2019-06-04 10:48:24 UTC

Description Junqi Zhao 2019-04-30 05:49:13 UTC
Created attachment 1560175 [details]
prometheus-k8s pod logs

Description of problem:
etcd pods/services are moved to openshift-etcd project now, but the etcd svc can not be discovered and can not show etcd data in grafana UI

error in prometheus-k8s pod logs shows:
level=error ts=2019-04-30T04:06:58.311Z caller=klog.go:94 component=k8s_client_runtime func=ErrorDepth msg="github.com/prometheus/prometheus/discovery/kubernetes/kubernetes.go:300: Failed to list *v1.Endpoints: endpoints is forbidden: User \"system:serviceaccount:openshift-monitoring:prometheus-k8s\" cannot list resource \"endpoints\" in API group \"\" in the namespace \"openshift-etcd\""


Version-Release number of selected component (if applicable):
4.1.0-0.nightly-2019-04-28-064010

How reproducible:
Always

Steps to Reproduce:
1. Check etcd targets in prometheus /service-discovery page
2.
3.

Actual results:
etcd svc can not be discovered

Expected results:
etcd svc should be discovered


Additional info:

Comment 1 Junqi Zhao 2019-04-30 05:50:09 UTC
blocks etcd monitoring testing

Comment 2 Junqi Zhao 2019-04-30 05:53:46 UTC
Created attachment 1560176 [details]
prometheus-k8s sa info

Comment 3 Frederic Branczyk 2019-04-30 06:51:06 UTC
https://github.com/openshift/cluster-monitoring-operator/pull/339 opened

Comment 4 Frederic Branczyk 2019-04-30 09:46:01 UTC
PR merged.

Comment 6 Peter Ruan 2019-05-01 06:49:27 UTC
verified with 

I can see openshift-monitoring/etcd/0 in prometheus UI, and there's a etcd section under grafana

Comment 7 Peter Ruan 2019-05-01 06:50:35 UTC
verified with nightly build 4.1.0-0.nightly-2019-05-01-002148

Comment 9 errata-xmlrpc 2019-06-04 10:48: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-2019:0758


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