Hello,

According to the Short Manual for Log4J, using log4j.configuration
system property to specify the log4j config file location is the way to
go.

When I do that: java -Dlog4j.configuration=./log4j.xml com.example.Foo 

I get:

log4j:ERROR DOM element is - not a <log4j:configuration> element.
log4j:WARN No appenders could be found for logger (com.example.Foo).
log4j:WARN Please initialize the log4j system properly.

I checked my log4j.xml, and it starts with:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">

<!-- $Id: log4j.xml,v 1.3 2004/03/30 03:17:52 otis Exp $ -->

<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/";
debug="false">

    <appender ..........


I am using Log4J 1.2.8 and I see that my log4j-1.2.8.jar has log4j.dtd
in it.

Any idea why I am getting that error and warning above?
Nothing is getting logged.

Thanks,
Otis


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to