Solved

log4j:WARN

Posted on 2010-09-09
6
889 Views
Last Modified: 2013-11-09
where is the setting to initialize, for the below error: (after running a batch file where java.exe is called)
----------------------
log4j:WARN No appenders could be found for logger (org.springframework.context.s
upport.ClassPathXmlApplicationContext).
log4j:WARN Please initialize the log4j system properly.
0
Comment
Question by:anushahanna
6 Comments
 
LVL 20

Expert Comment

by:ChristoferDutz
ID: 33636623
This error usually only occurs, when the Log4J System initializes itself and it cannot find a log4j.properties in any of the default locations.
0
 
LVL 20

Accepted Solution

by:
ChristoferDutz earned 250 total points
ID: 33636649
Are you running a web application? If yes you could add the following to your web.xml and add a log4j.properties to the WEB-INF/classes directory. It makes sure the Log4J subsystem is correclty initialized. Also have a look at this overview-documentation (Includes an example log4j.properties file) http://logging.apache.org/log4j/1.2/manual.html
    <listener>
        <listener-class>
            org.springframework.web.util.Log4jConfigListener
        </listener-class>
    </listener>

Open in new window

0
 
LVL 16

Expert Comment

by:Valeri
ID: 33636760
Find out where is placed your commons-logging*.jar
Put the attached file in the same directory, just rename it to log4j.properties before that.
log4j.txt
0
Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

 
LVL 16

Assisted Solution

by:Valeri
Valeri earned 250 total points
ID: 33636809
ops, sorry! replace this line
log4j.rootLogger=DEBUG, A
with this one :
log4j.rootLogger=ERROR, A
0
 
LVL 6

Author Comment

by:anushahanna
ID: 33637979
Thanks very much.
0
 
LVL 92

Expert Comment

by:objects
ID: 33642424
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

It is a general practice to get rid of old user profiles on a computer  in a LAN environment. As I have been working with a company in a LAN environment where users move from one place to some other place at times. This will make many user profil…
While rebooting windows server 2003 server , it's showing "active directory rebuilding indices please wait" at startup. It took a little while for this process to complete and once we logged on not all the services were started so another reboot is …
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.

832 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question