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?
Verified with ose-cluster-logging-operator-v4.2.0-201908041300
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