logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jacob Kjome" <h...@visi.com>
Subject Re: unable to set properties
Date Mon, 07 May 2012 15:06:40 GMT

Do you have log4j-extras.jar [1] in the classpath along with log4j.jar?  If 
not, that's the problem.

[1] http://logging.apache.org/log4j/companions/extras/

Jake

On Mon, 7 May 2012 15:03:08 +0530
 aanjaneya shukla <shuklaaanjaneya@gmail.com> wrote:
> Hi,
> I am using the below mentioned log4j.properties file in tomcat 6.0.35
> 
> log4j.appender.request=org.apache.log4j.rolling.RollingFileAppender
> log4j.appender.request.Append=true
> log4j.fileName=logs/test
> log4j.appender.request.File=${log4j.fileName}.log
> log4j.appender.request.RollingPolicy=org.apache.log4j.rolling.FixedWindowRollingPolicy
> log4j.appender.request.RollingPolicy.FileNamePattern=${log4j.fileName}.%i.log.zip
> log4j.appender.request.RollingPolicy.MinIndex=1
> log4j.appender.request.RollingPolicy.MaxIndex=10
> 
> log4j.appender.request.TriggeringPolicy=org.apache.log4j.rolling.SizeBasedTriggeringPolicy
> log4j.appender.request.TriggeringPolicy.MaxFileSize=10485760
> 
> log4j.appender.request.layout=org.apache.log4j.PatternLayout
> log4j.appender.request.layout.ConversionPattern=%d{ABSOLUTE} %5p %c{1}:%L -
> %m%n
> 
> log4j.rootLogger=info, request
> 
> But I get the following messages returned
> log4j:WARN Failed to set property [rollingPolicy] to value
> "org.apache.log4j.rolling.FixedWindowRollingPolicy".
> log4j:WARN Failed to set property [triggeringPolicy] to value
> "org.apache.log4j.rolling.SizeBasedTriggeringPolicy".
> log4j:WARN Please set a rolling policy for the RollingFileAppender named
> 'request'
> log4j:WARN Failed to set property [rollingPolicy] to value
> "org.apache.log4j.rolling.FixedWindowRollingPolicy".
> log4j:WARN Failed to set property [triggeringPolicy] to value
> "org.apache.log4j.rolling.SizeBasedTriggeringPolicy".
> log4j:WARN Please set a rolling policy for the RollingFileAppender named
> 'request'
> log4j:ERROR No output stream or file set for the appender named [request].
> 
> There is some problem with setting the properties in log4j.
> 
> Thanks.


---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message