Hi Ravi  :-)

> My web app is based on Tomcat 9.0.45 server. I have migrated from Tomcat 7 to 
> Tomcat 9
> and from log4j 1.x to log4j 2.x.  I have updated the log4j2.properties as per 
> log4j 2.x standard,
> still my tomcat.log file is not getting generated and all the application log 
> are coming on
> console instead of redirecting this to tomcat.log file.  So
> 1.tomcat.log is not geting  generated
> 2. all the contents are logging and showing on the application console 
> instead of getting this
> logged inside the tomcat.log file.
> Tomcat 9.0.45 + log4j 2.14.1 is used. I am also attaching my log4j property 
> file.
> Please find this attached here.
> Kindly suggest me the solution.
> Thank you.

Thanks for supplying your "log4j2.properties" file.  (Actually, I kind of 
surprised the file was delivered intact, since the mailing list usually strips 
attachments.)  That properties file tells Log4j2 how to perform logging.  How 
did you tell Tomcat to use Log4j2?

FYI, I'm a little rusty as Log4j2.

Cris Berneburg
CACI Senior Software Engineer


This electronic message contains information from CACI International Inc or 
subsidiary companies, which may be company sensitive, proprietary, privileged 
or otherwise protected from disclosure. The information is intended to be used 
solely by the recipient(s) named above. If you are not an intended recipient, 
be aware that any review, disclosure, copying, distribution or use of this 
transmission or its contents is prohibited. If you have received this 
transmission in error, please notify the sender immediately.

To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to