[Building Sakai] log4j.properties log4j.DailyRollingFileAppender type logging question
Matthew Jones
matthew at longsight.com
Tue May 13 05:24:50 PDT 2014
Using this external program cronolog (Available in Redhat/Ubunutu repos)
has worked the best for me. Easy to add to catalina.sh
http://collab.sakaiproject.org/pipermail/sakai-dev/2012-February/015940.html
This is the result of using cronolog
https://qa10.longsight.com/logs/
You *should* be able to get it to work with the rolling file appender but
it seems like because of the different logging classes Sakai uses it might
not be entirely consistent in the results
http://collab.sakaiproject.org/pipermail/sakai-dev/2012-February/015928.html
On Tue, May 13, 2014 at 8:20 AM, Jeremy O'Connor <jeremy.uwc at gmail.com>wrote:
> Would the following entries in
> {$TOMCAT_HOME}/common/classes/log4j.properties work (specifically the
> entries for
>
> log4j.appender.SC)?
>
> # use "A" for log in with catalina.out (actually standard output)
> log4j.rootLogger=WARN, SC, SF
>
> # Configuration for standard output ("catalina.out" in Tomcat).
> # -log4j.appender.SC=org.apache.log4j.ConsoleAppender
> log4j.appender.SC=org.apache.log4j.DailyRollingFileAppender
> log4j.appender.SC.DatePattern='.'yyyy-MM-dd
> log4j.appender.SC.File=/opt/tomcat/logs/catalina.out
> log4j.appender.SC.layout=org.apache.log4j.PatternLayout
> log4j.appender.SC.layout.ConversionPattern=(%d %t_%c) - %p: %m %n
>
> # A more descriptive but lower performance logging pattern
> #log4j.appender.SC.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L -
> %m%n
>
> # Configuration for a rolling log file ("tomcat.log")
> log4j.appender.SF=org.apache.log4j.DailyRollingFileAppender
> log4j.appender.SF.DatePattern='.'yyyy-MM-dd
> log4j.appender.SF.File=/opt/tomcat/logs/tomcat.log
> # =log4j.appender.SF.File=/opt/tomcat/logs/catalina.out
> log4j.appender.SF.layout=org.apache.log4j.PatternLayout
> log4j.appender.SF.layout.ConversionPattern=%p %d %t_%c%n%m%n
> # =log4j.appender.SF.layout.ConversionPattern=(%d %t_%c) - %p: %m %n
>
> --
> Jeremy
>
> _______________________________________________
> sakai-dev mailing list
> sakai-dev at collab.sakaiproject.org
> http://collab.sakaiproject.org/mailman/listinfo/sakai-dev
>
> TO UNSUBSCRIBE: send email to
> sakai-dev-unsubscribe at collab.sakaiproject.org with a subject of
> "unsubscribe"
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://collab.sakaiproject.org/pipermail/sakai-dev/attachments/20140513/1d272765/attachment.html
More information about the sakai-dev
mailing list