Em 28/01/2013 18:51, Mark Eggers escreveu:
On 1/28/2013 10:06 AM, Christopher Schultz wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Tiago,
On 1/28/13 11:25 AM, Tiago Sousa wrote:
Em 28/01/2013 16:16, Christopher Schultz escreveu: Tiago,
On 1/28/13 11:02 AM, Tiago Sousa wrote:
Em 28/01/2013 15:41, Christopher Schultz escreveu: Tiago,
On 1/28/13 8:49 AM, Tiago Sousa wrote:
Thanks, one more time, for your reply. The problem with
log4j 1.x is that it outputs the following error:
log4j:WARN No appenders could be found for logger
(org.apache.catalina.startup.Embedded). log4j:WARN
Please initialize the log4j system properly.
I know that this is a common error, usually related
with classpath problems. In my case, the configuration
i'm using doesn´t seem to be have those sort of
problems....
This is a symptom of having your log4j.properties in the
wrong place.
You never said anything about using Tomcat Embedded. If you
are using Embedded Tomcat, you'll have to make sure that
your log4j.properties file is in the CLASSPATH of the JVM
when it starts.
-chris
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail:
users-h...@tomcat.apache.org
Hi. Thanks for your reply. Isn´t that assured (log4j in
classpath) putting the log4j.properties in apache lib folder
since i'm using tomcat 6.x?
If you are using Tomcat Embedded, you are entirely responsible for
your own CLASSPATH. The "Embedded" class causes the logger to be
initialized before any real code gets executed (it's in the first
static initializer in the class), so "Embedded" can't change the
CLASSPATH or launch a new ClassLoader for that purpose.
Can you please describe your environment? It's been tough to get
details from you.
-chris
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org
Hi,
Sorry, i am a newbie in tomcat issues. I'm just "following
orders"... :-) My configuration is the most standard i could find:
1 step: download apache-tomcat-6.0.36.zip from apache.org 2 -
unzip 3 - erase logging.properties from conf folder 4 - copy jar
files (juli and juli-adapters)from extras to bin and lib
directories, respectively. 5 - create a logging.properties file
(standard definitions as in apache.org) and put it in lib folder.
6- download log4j.1.2.7.jar and put it in lib folder.
And that's it. I'm using tomcat in windows.
Hope this helps you to help me...
So where does the Embedded class come in? How do you launch Tomcat?
- -chris
I just tried this - finally upgraded to 6.0.36 on this machine (been
using 7.0.x, so I haven't thought much about it).
OS: Windows 7 Home Premium 64 bit
JRE: 1.7.0_11 64 bit
Tomcat: 6.0.36
Editor: jEdit
I normally use Cygwin to unpack the zip file and edit stuff, but that
can leave ownership / permissions in strange states. So this time I did
the following.
1. Unpack the zip file in C:\Users\<me>\Apache\apache-6.0.36 (IZArc)
2. Make the appropriate edits to %CATALINA_HOME%\conf\tomcat-users.xml
3. Add setenv.bat to %CATALINA_HOME%\bin for JMX
4. Add URIEncoding=UTF-8 to Connector elements
5. Enable AccessLogValve
6. Add MySQL and mail jars to %CATALINA_HOME%\lib for some applications
Double-clicking on startup.bat from Windows Explorer results in the
expected execution. I get entries in the appropriate log files.
Now I do the following:
1. back up tomcat-juli.jar
2. replace it with the tomcat-juli.jar from Extras
3. add log4j-1.2.17.jar to %CATALINA_HOME%\lib
4. add tomcat-juli-adapters.jar to %CATALINA_HOME%\lib
5. Create log4j.properties
a. Copy from Tomcat web site
b. Save in %CATALINA_HOME%\conf
6. Remove logging.properties from %CATALINA_HOME%\conf
Start Tomcat by double-clicking startup.bat in %CATALINA_HOME%\bin from
Windows Explorer.
The result:
I get the same warning (No appenders could be found for logger
(org.apache.catalina.startup.Embedded). I get no log files in
%CATALINA_HOME%\logs other than the access log.
I also verified that I have no web applications with log4j-1.2.17.jar in
a WEB-INF/lib, nor do I have log4j.xml floating around in
%CATALINA_HOME%\webapps.
I'm not a Windows person and normally just use JULI logging for Tomcat.
So maybe I've done something wrong . . . dunno.
Hmm. Maybe I'll try rewriting the log4j.properties as log4j.xml.
. . . . just my two cents.
/mde/
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org
Hi.
I guess that in your case you just have to put your log4j.properties in
the lib folder, not the conf folder.
Tiago
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org