Bug 1319906 - Openshift Router does not save haproxy logs
Summary: Openshift Router does not save haproxy logs
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: RFE
Version: 3.1.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: ---
Assignee: jtanenba
QA Contact: Johnny Liu
URL:
Whiteboard:
: 975533 (view as bug list)
Depends On:
Blocks: 1267746
TreeView+ depends on / blocked
 
Reported: 2016-03-21 19:07 UTC by Ryan Howe
Modified: 2019-11-14 07:38 UTC (History)
15 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-09-27 09:36:36 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2016:1933 normal SHIPPED_LIVE Red Hat OpenShift Container Platform 3.3 Release Advisory 2016-09-27 13:24:36 UTC

Description Ryan Howe 2016-03-21 19:07:04 UTC
Description of problem: Openshift Router does not save haproxy logs. 

Version-Release number of selected component (if applicable):
3.x


How reproducible:
100%

Steps to Reproduce:
1. oc logs ROUTER 

Actual results:
  - No Haproxy logs

Expected results:
  - Haproxy logs to be shown. 

Additional info:

 - Is there a workaround to get haproxy logs since it normally wants to log to rsyslog. 

UPSTREAM ISSUES:
https://github.com/openshift/origin/issues/1871
https://github.com/openshift/origin/issues/7974

Comment 2 Ram Ranganathan 2016-03-23 01:13:30 UTC
Here's an example repo to build a custom haproxy based template router image and 
run it and send haproxy logs to a syslog daemon. 
   https://github.com/ramr/openshift-haproxy-custom-logs

The gist is to take the current haproxy-config.template and add the appropriate log configuration and rebuild a router image and then use that image.
You can use these instructions as a guide:
https://docs.openshift.com/enterprise/3.1/install_config/install/deploy_router.html#deploying-a-customized-haproxy-router
https://docs.openshift.com/enterprise/3.1/install_config/install/deploy_router.html#rebuilding-your-router 


Note: The logs are sent to a syslog address (default is 127.0.0.1 port 514) and uses udp. See: https://github.com/ramr/openshift-haproxy-custom-logs/blob/master/haproxy-config.template#L11
for more details on usage.

You can pass this config in via environment variables: 
oc env dc/router HAPROXY_ROUTER_SYSLOG_ADDRESS=127.0.0.1 HAPROXY_ROUTER_LOG_LEVEL=debug

Comment 3 Ram Ranganathan 2016-03-28 18:11:44 UTC
Adding an RFE tag - since this is newly requested functionality. The above workaround using a custom image is an interim solution for now.

Comment 11 Dan McPherson 2016-04-13 14:23:57 UTC
*** Bug 975533 has been marked as a duplicate of this bug. ***

Comment 13 Ben Bennett 2016-04-25 18:54:52 UTC
The PR to enable remote syslog has not merged.  So it will be in 3.3 at the earliest.

https://github.com/openshift/origin/pull/8332

Comment 14 jtanenba 2016-05-17 14:30:42 UTC
https://github.com/openshift/origin/pull/8332 PR merged into origin. 

Waiting on documentation entries to merge https://github.com/openshift/openshift-docs/pull/1873

Comment 16 errata-xmlrpc 2016-09-27 09:36:36 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-2016:1933


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