Bug 1134034
| Summary: | RFE: Need a "parallel" logging option in logshifter to log using both file and syslog | ||
|---|---|---|---|
| Product: | OpenShift Container Platform | Reporter: | Eric Sauer <esauer> |
| Component: | Containers | Assignee: | Scott Dodson <sdodson> |
| Status: | CLOSED ERRATA | QA Contact: | libra bugs <libra-bugs> |
| Severity: | medium | Docs Contact: | |
| Priority: | high | ||
| Version: | 2.1.0 | CC: | adellape, agoldste, anli, asimonel, bleanhar, dmace, erich, jialiu, jokerman, libra-onpremise-devel, lmeyer, mmccomas, pruan, sdodson, thunt |
| Target Milestone: | --- | Keywords: | Upstream |
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | openshift-origin-logshifter-1.5.2.1-1 | Doc Type: | Enhancement |
| Doc Text: |
Because node host administrators may want to have logging consolidated via Syslog while gear users may wish to have logs written to the application root directory, nodes now support log delivery to both Syslog and file output types at the same time. Administrators can set the 'outputType' in the /etc/openshift/logshifter.conf file on node hosts to 'multi', which results in logs being written to both 'file' and 'syslog'.
|
Story Points: | --- |
| Clone Of: | Environment: | ||
| Last Closed: | 2014-10-02 13:59:45 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
Eric Sauer
2014-08-26 16:33:21 UTC
FYI, the latest logshifter code is in origin-server: https://github.com/openshift/origin-server/tree/master/logshifter. This seems reasonable to me. Would we want to allow for the logshifter output type to be a list of writers? Writing to both locations would involve setting 'outputType=syslog,file' instead of creating a new type of writer. Having admins put 'outputType=parallel' would sort of back us in the corner in the case of adding a third option (that could potentially be combined with the other two in some way). We wouldn't necessarily need to do anything fancy right now though. The implementation could largely be the same. It could be as simple as checking for permutations of 'syslog,file' for the outputType setting. After a bit more discussion, I think the proposed approach is good. I don't think there is much need for options beyond syslog, file, and both; the purpose of logshifter isn't to be a generic log tool, just to deal with the inside-gear vs syslog dichotomy. It may be possible to have syslog split logs back to the gear, but I suspect it's simpler in several ways to just complete this final option on logshifter. Just throwing in my +1 here: a narrowly-scoped combined option would be useful and straightforward to introduce. Created a PR with multi_writer changes here: https://github.com/openshift/origin-server/pull/5758 PR was tested and merged last week. What are the next steps to get this into OSE? Thanks for bumping this. Basically it is up to the OSE team to cherry-pick the changes into 2.1 (or decide to just wait for 2.2 to be released). Bumping priority so it'll be on our radar. Eric, I'm looking over this and familiarizing myself with logshifter. I'll likely get a PR in for 2.1.7 in order to ensure QA has adequate time to test. -- Scott Verified and pass on puddle-2-1-2014-09-09 set outputtype = file in logshifter.conf. 1) tailf /var/messages and check the log files under /var/lib/openshift/$uuid/app-root/. 2) Gears logged into file. No gears logged into /var/log/messages. set outputtype = syslog in logshifter.conf 1) tailf /var/message and check the log files under /var/lib/openshift/$uuid/app-root/. 2) Gears logged into /var/log/messages. No gears logged into /var/lib/openshift/$uuid/app-root/logs set outputtype = multi logshifter.conf 1) tailf /var/message and check the log files under /var/lib/openshift/$uuid/app-root/. 2) Gears logged into /var/log/messages and /var/lib/openshift/$uuid/app-root/logs 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. http://rhn.redhat.com/errata/RHBA-2014-1353.html |