[ 
https://issues.apache.org/jira/browse/TS-306?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14990753#comment-14990753
 ] 

ASF GitHub Bot commented on TS-306:
-----------------------------------

GitHub user SolidWallOfCode opened a pull request:

    https://github.com/apache/trafficserver/pull/322

    TS-306: Fix file privilege elevation to work with log rotation.

    This fixes several issues.
    
    The biggest is DAC bypass privilege elevation. Because `traffic_server` is 
invoked in multiple ways (full deployment, standalone, via `gdb`, etc.) 
sometimes the process is privileged when the logfiles are bound and sometimes 
it is not. The existing elevation mechanism does not work if the process is 
already privileged because it incorrectly removes the privileges when it lowers 
privileges. I have changed this to save the current capability set and restore 
it on lowering so that it works in both cases.
    
    I tweaked the buffering on the logfiles to avoid log messages apparently 
stopping in the middle.
    
    I changed an argument naming to reserve leading underscores for class 
member variables.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/SolidWallOfCode/trafficserver ts-306

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/trafficserver/pull/322.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #322
    
----
commit a69b103bdd34c1287e83439f154cced5877f3fe1
Author: Alan M. Carroll <a...@apache.org>
Date:   2015-11-04T23:54:23Z

    TS-306: Fix file privilege elevation to work with log rotation.

----


> enable log rotation for diags.log
> ---------------------------------
>
>                 Key: TS-306
>                 URL: https://issues.apache.org/jira/browse/TS-306
>             Project: Traffic Server
>          Issue Type: Improvement
>          Components: Logging
>            Reporter: Miles Libbey
>            Assignee: Daniel Xu
>              Labels: newbie
>             Fix For: 6.1.0
>
>
> (from yahoo bug 913896)
> Original description
> by Leif Hedstrom 3 years ago at 2006-12-04 12:42
> There might be reasons why this file might get filled up, e.g. libraries used 
> by plugins producing output on STDOUT/STDERR. A few suggestions have been
> made, to somehow rotate traffic.out. One possible solution (suggested by 
> Ryan) is to use cronolog (http://cronolog.org/), which seems like a fine idea.
>               
>  
> Comment 1
>  by Joseph Rothrock  2 years ago at 2007-10-17 09:13:24
> Maybe consider rolling diags.log as well. -Feature enhancement.
>               
> Comment 2
>  by Kevin Dalley 13 months ago at 2009-03-04 15:32:18
> When traffic.out gets filled up, error.log stops filing up, even though 
> rotation is turned on. This is
> counter-intuitive.  Rotation does not control traffic.out, but a large 
> traffic.out will stop error.log from being
> written.
>               



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to