Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1725517

Summary: Set `ENABLE_PROMETHEUS_ENDPOINT=false` in rsyslog env doesn't take effect.
Product: OpenShift Container Platform Reporter: Qiaoling Tang <qitang>
Component: LoggingAssignee: Jeff Cantrill <jcantril>
Status: CLOSED ERRATA QA Contact: Qiaoling Tang <qitang>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 4.2.0CC: anli, aos-bugs, lvlcek, nhosoi, rmeggins
Target Milestone: ---   
Target Release: 4.3.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2020-01-23 11:04:15 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Qiaoling Tang 2019-07-01 02:50:30 UTC
Description of problem:
The default value of ENABLE_PROMETHEUS_ENDPOINT is false(https://github.com/openshift/cluster-logging-operator/blob/master/files/rsyslog/rsyslog.sh#L4), when deploying logging using rsyslog as log collector, some of the rsyslog pods' prometheus endpoints are exposed.

If set ENABLE_PROMETHEUS_ENDPOINT=true in rsyslog ds, then wait for all rsyslog pods restart, set ENABLE_PROMETHEUS_ENDPOINT=false again, all of the rsyslog pods prometheus endpoints are exposed.

[qitang@wlc-trust-182 aws]$ oc exec rsyslog-t7rqb env |grep ENABLE_PROMETHEUS_ENDPOINT
Defaulting container name to rsyslog.
Use 'oc describe pod/rsyslog-t7rqb -n openshift-logging' to see all of the containers in this pod.
ENABLE_PROMETHEUS_ENDPOINT=false
[qitang@wlc-trust-182 aws]$ oc exec rsyslog-t7rqb -- curl -k https://localhost:24231/metrics
Defaulting container name to rsyslog.
Use 'oc describe pod/rsyslog-t7rqb -n openshift-logging' to see all of the containers in this pod.
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100 13285    0 13285    0     0   102k      0 --:--:-- --:--:-- --:--:--  103k
# HELP go_gc_duration_seconds A summary of the GC invocation durations.
# TYPE go_gc_duration_seconds summary
go_gc_duration_seconds{quantile="0"} 5.9918e-05
go_gc_duration_seconds{quantile="0.25"} 5.9918e-05
go_gc_duration_seconds{quantile="0.5"} 5.9918e-05
go_gc_duration_seconds{quantile="0.75"} 5.9918e-05
go_gc_duration_seconds{quantile="1"} 5.9918e-05
go_gc_duration_seconds_sum 5.9918e-05
go_gc_duration_seconds_count 1
# HELP go_goroutines Number of goroutines that currently exist.
# TYPE go_goroutines gauge
go_goroutines 14
# HELP go_info Information about the Go environment.
# TYPE go_info gauge
<------>

Version-Release number of selected component (if applicable):
ose-logging-rsyslog-v4.2.0-201906301800

How reproducible:
Always

Steps to Reproduce:
1.Deploy logging via OLM
2.check targets in prometheus console
3.

Actual results:
ENABLE_PROMETHEUS_ENDPOINT=false in rsyslog pod doesn't take effect

Expected results:
If set ENABLE_PROMETHEUS_ENDPOINT=false, should not expose any rsyslog prometheus endpoints.

Additional info:
Could we set ENABLE_PROMETHEUS_ENDPOINT default to true?

Comment 2 Qiaoling Tang 2019-08-05 01:52:36 UTC
Verified with ose-cluster-logging-operator-v4.2.0-201908041300

Comment 6 errata-xmlrpc 2020-01-23 11:04:15 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:0062