This blog wil be updated almost daily and the topics will be dealing with the daily support of SAP BusinessObjects BI support. So check back daily! Protected by Copyscape Online Plagiarism Test

Saturday, May 8, 2010

Fix for log4j warning message in the Tomcat log file stdout.log

I was getting these warning messages in the logs file stdout.log while trying to debug the Kerberos login issues on Java InfoView. Not that this was disruptive by any means, but I thought I should lower the logs size. I’m working on BO XI R2 on Windows 2003 with Tomcat.

INFO: Installing web application at context path /dswsbobje from URL file:C:\Program Files\Business Objects\Tomcat\webapps\dswsbobje
log4j:WARN No appenders could be found for logger (org.apache.catalina.session.ManagerBase).
log4j:WARN Please initialize the log4j system properly.

These messages indicate that listed web application file dswsbobje was unable to find the log4j.war file in its location which was supposed to be deployed universally at the time of installation and apparently did not.

A note on what log4j is?

log4j is a popular logging package for Java and is used for debugging Java applications. With log4j it is possible to enable logging at runtime without modifying the application binary. The package is distributed under the Apache Software License, a fully-fledged open source license certified by the open source initiative.


The link http://logging.apache.org/log4j/docs/manual.html gives pretty good information on different aspects of log4j properties. The output from Log4j can go to the console, but it can also go to an email server, a database table, a log file (as in my case here), or various other destinations.


This link gives the FAQ’s about log4j file: http://logging.apache.org/log4j/1.2/faq.html#a1.1


In my case here, I have created a folder WINNT on C:\ drive and created a file bscLogin.conf to enable Windows AD authentication using Kerberos for Java InfoView. Enabling trace in this file will provide logs for tracing any untoward login issues.

How to enable trace to follow Kerberos login attempt activities

Open the file bscLogin.conf from C:\WINNT in notepad. Append debug=true as shown below to debug the Kerberos login issues.

FIG 01 – Appending debug to file bscLogin.conf

The output of this will be logged at this default location C:\Program Files\Business Objects\Tomcat\logs\ and the log file name will be stdout.log

The Fix

There were some other messages warning for deployed WAR files dswsbobjewar.xml and jsfadminwar.xml. So to have Tomcat use file log4j.jar universally, I copied the files log4j.jar and commons-logging.jar from the Java library folder C:\Program Files\Business Objects\common\3.5\java\lib\external to the Tomcat lib folder C:\Program Files\Business Objects\Tomcat\common\lib

Then, this is the result of the Tomcat log file (stdout.log) that has size of 1 KB. I had to delete the stdout.log file first and then restart the Tomcat Service.

FIG 02 - Location of the log file

As per Tomcat forum documentation, some warning messages may persist but they don’t seem to be any reason for Kerberos not authenticating.

I hope this will be helpful to someone.

*
**
***

No comments:

Post a Comment