infra-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chris Thistlethwaite (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (INFRA-16643) Update logging rotation on Nexus (repository-vm2.a.o)
Date Tue, 12 Jun 2018 15:56:00 GMT

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

Chris Thistlethwaite commented on INFRA-16643:
----------------------------------------------

logs are located /x1/nexus-work/logs
config is located in /home/nexus/nexus/current/conf

Changing logback-access.xml from 
<configuration>

  <appender name="request.logfile" class="ch.qos.logback.core.rolling.RollingFileAppender">
    <File>${nexus-work}/logs/request.log</File>
    <Append>true</Append>
    <encoder class="org.sonatype.nexus.bootstrap.log.AccessPatternLayoutEncoder">
      <pattern>%clientHost %l %user [%date] "%requestURL" %statusCode %bytesSent %elapsedTime</pattern>
    </encoder>
    <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
      <fileNamePattern>${nexus-work}/logs/request-%d{yyyy-MM-dd}.log.gz</fileNamePattern>
      <maxHistory>90</maxHistory>
    </rollingPolicy>
    <File>${nexus-work}/logs/nexus.log</File>
  </appender>

  <appender-ref ref="request.logfile"/>
</configuration>

to 

<configuration>

  <appender name="request.logfile" class="ch.qos.logback.core.rolling.RollingFileAppender">
    <File>${nexus-work}/logs/request.log</File>
    <Append>true</Append>
    <encoder class="org.sonatype.nexus.bootstrap.log.AccessPatternLayoutEncoder">
      <pattern>%clientHost %l %user [%date] "%requestURL" %statusCode %bytesSent %elapsedTime</pattern>
    </encoder>
    <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
      <fileNamePattern>${nexus-work}/logs/request-%d{yyyy-MM-dd}.log.gz</fileNamePattern>
      <maxHistory>30</maxHistory>
    </rollingPolicy>
    <File>${nexus-work}/logs/nexus.log</File>
    <Append>true</Append>
    <encoder class="org.sonatype.nexus.bootstrap.log.AccessPatternLayoutEncoder">
      <pattern>%clientHost %l %user [%date] "%requestURL" %statusCode %bytesSent %elapsedTime</pattern>
    </encoder>
    <rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
      <fileNamePattern>${nexus-work}/logs/nexus-%d{yyyy-MM-dd}.log.gz</fileNamePattern>
      <maxHistory>30</maxHistory>
    </rollingPolicy>
  </appender>

  <appender-ref ref="request.logfile"/>
</configuration>





> Update logging rotation on Nexus (repository-vm2.a.o)
> -----------------------------------------------------
>
>                 Key: INFRA-16643
>                 URL: https://issues.apache.org/jira/browse/INFRA-16643
>             Project: Infrastructure
>          Issue Type: Bug
>          Components: Nexus
>            Reporter: Chris Thistlethwaite
>            Assignee: Chris Thistlethwaite
>            Priority: Major
>
> The current nexus.log files are rotating, but not archiving. Archives are also kept for
90 days, going to switch that to 30d.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message