Bug 1553576

Summary: Change the self_hostname to ${hostname} in openshift-ansible
Product: OpenShift Container Platform Reporter: Anping Li <anli>
Component: LoggingAssignee: Noriko Hosoi <nhosoi>
Status: CLOSED ERRATA QA Contact: Qiaoling Tang <qitang>
Severity: low Docs Contact:
Priority: low    
Version: 3.9.0CC: aos-bugs, jcantril, nhosoi, rmeggins
Target Milestone: ---   
Target Release: 3.9.z   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Fluentd secure-forward plug-in supports hostname placeholder "${hostname}" in the configuration file. Although the value is case-sensitive, upper case string "${HOSTNAME}" was set and it failed to pick up the correct hostname of the fluentd container. The bug has been fixed.
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-05-17 06:42:42 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:

Description Anping Li 2018-03-09 06:18:24 UTC
Description of problem:

As https://bugzilla.redhat.com/show_bug.cgi?id=1548720. The self_hostname should  be ${hostname}. the openshift-ansible to align with logging-fluentd image

roles/openshift_logging_fluentd/files/secure-forward.conf:# self_hostname ${HOSTNAME}
roles/openshift_logging_fluentd/templates/fluent.conf.j2:  self_hostname ${HOSTNAME}
roles/openshift_logging_mux/files/secure-forward.conf:# self_hostname ${HOSTNAME}

Version-Release number of selected component (if applicable):
OCP 3.9

How reproducible:
Always

Steps to Reproduce:
1. Deploy logging 3.9
2. Check the self_hostname  in configmap logging-fluentd

Actual results:
self_hostname ${HOSTNAME}

Expected results:
self_hostname ${hostname}


Additional info:

Comment 1 Noriko Hosoi 2018-03-09 17:44:28 UTC
Thanks a lot, Anping.  

I've submitted a pr:
https://github.com/openshift/openshift-ansible/pull/7475

Comment 2 openshift-github-bot 2018-03-16 02:42:43 UTC
Commits pushed to master at https://github.com/openshift/openshift-ansible

https://github.com/openshift/openshift-ansible/commit/3719792fe02fb160974f5b5542b479fd5fd5bfbc
Bug 1553576 - Change the self_hostname to ${hostname} in openshift-ansible

See also:
Bug 1548720 - fluent-plugin-secure-forward couldn't read the Environment ${HOSTNAME}
https://github.com/openshift/origin-aggregated-logging/pull/988

https://github.com/openshift/openshift-ansible/commit/06f8c2176bcd810112f0d8c4c5ec577620e948c9
Merge pull request #7475 from nhosoi/bz1553576

Automatic merge from submit-queue.

Bug 1553576 - Change the self_hostname to ${hostname} in openshift-ansible

See also:
Bug 1548720 - fluent-plugin-secure-forward couldn't read the Environment ${HOSTNAME}
https://github.com/openshift/origin-aggregated-logging/pull/988

Comment 3 Jeff Cantrill 2018-03-16 20:02:03 UTC
3.9 cherrypick https://github.com/openshift/openshift-ansible/pull/7561

Comment 5 Anping Li 2018-04-17 03:37:26 UTC
The hostname are use lowcase in openshift-ansible:3.9.22

Comment 7 Qiaoling Tang 2018-04-20 05:26:20 UTC
The fix isn't in openshift v3.9.24.

Version-Release number of selected component (if applicable):
logging-fluentd/images/v3.9.25-1

Comment 8 Anping Li 2018-05-11 10:52:52 UTC
The default values is ${hostname} in logging-fluentd configmap and logging-mux configmap which is created by openshift-ansible:v3.9.27. so move to verified.

Comment 11 errata-xmlrpc 2018-05-17 06:42:42 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-2018:1566