Hello Konstantin:
I tried to invoke Bootstrap,but got an error saying "Can't load
server.xml from
I:\workspace\mye10\TOMCAT_5_5_30\conf\server.xml",server.xml does exist
and when I invoke Catalina ,everything is ok, that is ,web app deployed
into webapps/Root can run normally. Is there any material to guide a
newbie on how to compile,run tomcat 5 of your compiled version, config
logging thing etc?
Thanks and nice day.
Kurt
在 Mon, 21 Nov 2011 20:00:51 +0800,Konstantin Kolinko
<knst.koli...@gmail.com> 写道:
2011/11/21 Kurt <fxbird1...@163.com>:
Hello all:
I compile tomcat 5.5.30 and import it to eclipse as a project, to
research
how the tomcat load class , I need to view the running log ,after
reading
through this post(http://tomcat.apache.org/tomcat-5.5-doc/logging.html)
and
adding below log4j.properties to the direcotry 'common/classes' and
log4j-1.26.jar to common/lib, logs turned out not to be generated when I
debug the tomcat starting from class Catalina. No idea about it, I've
tried
many times.
log4j.rootLogger=DEBUG,R
log4j.appender.R=org.apache.log4j.RollingFileAppender
log4j.appender.R.File=k:\\logs\\tomcat.log
log4j.appender.R.MaxFileSize=10MB
log4j.appender.R.MaxBackupIndex=10
log4j.appender.R.layout=org.apache.log4j.PatternLayout
log4j.appender.R.layout.ConversionPattern=%p%t%c-%m%n
log4j.logger.org.apache.catalina.core.ContainerBase.[Catalina].[localhost]=DEBUG,
R
log4j.logger.org.apache.catalina.core=DEBUG, R
log4j.logger.org.apache.catalina.session=DEBUG, R
And the program parameter I use is 'start', vm parameter is
'-Dcatalina.home="I:\My
Documents\program\java\projects\eclipse\mye9.0\TOMCAT_5_5_30\mybuild-5.5.30"'
Any ideas? Thanks
1. Is there a reason why you are trying to use log4j? That is not
default configuration for Tomcat logging. The default one is JULI.
(Though you have to remove log4.jar from Tomcat if you want JULI to
work).
2. Why are you trying to start Catalina? The entry point is
"org.apache.catalina.startup.Bootstrap".
3. You need to use -Djava.util.logging.manager= and
-Djava.util.logging.config.file=
vm options to configure JULI, like catalina.sh/catalina.bat does it.
Best regards,
Konstantin Kolinko
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org
--
使用 Opera 革命性的电子邮件客户程序: http://www.opera.com/mail/
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org