tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Konstantin Kolinko <>
Subject Re: Understanding how to controlling what data is written to log4j appenders
Date Fri, 04 Dec 2015 00:53:54 GMT
2015-12-04 2:05 GMT+03:00 Joleen Barker <>:
> I want to have more control over what data is written to the various
> appenders in the files. I have played around with the
> various configurations in the file but I am not
> understanding how they are working in order to grasp how to have more
> control. I don't know if it would be a matter of turning off the INFO
> setting for the log4j.rootLogger and somehow setting individual logging for
> each appender.
> Below is my environment details:
> 1) The tomcat version that is running is v8.0.26.0
> 2) The OS is a Centos v7 UNIX VM
> 3) Java JDK I have installed that Tomcat is using is 1.8.0_60
> 4) Due to the catalina.out file growing too large with the default
> juli.AsyncFileHandler using the file that was found in
> the $CATALINA_HOME/conf directory. I changed the settings on a vendors
> software to use the log4j logging instead. (So this is NOT my web
> application or product written by me.)

None of AsyncFileHandler is responsible for catalina.out.

The catalina.out file consumes output of ConsoleHandler.

> log4j;,ContainerBase.[Catalina].[localhost].[/cfcc]=INFO,

The above line has a typo. s/;/./ after "log4j"

> <...>

You need to set "additivity" flag for non-root loggers to false.
I have not tested, but I think it will be like this:,ContainerBase.[Catalina].[localhost].[/cfcc]=false[Catalina].[localhost]=false[Catalina].[localhost].[/manager]=false[Catalina].[localhost].[/host-manager]=false

Documentation for Log4j 1.x:


Syntax of file:

Best regards,
Konstantin Kolinko

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message