eclipsetomcat

Tomcat ignores logging.properties when started from Eclipse


I'd like to enable Tomcat logging and changed Tomcat/conf/logging.properties (I enabled org.apache.catalina.util.LifecycleBase.level = FINE)

However, when I start Tomcat from Eclipse, it ignores my settings and shows logs as before.


Solution

  • Tomcat that is started from Eclipse uses configuration that is specified in its Properties. By default, logging configuration is not specified.

    So, open Eclipse -> select Tomcat -> Properties, click Open Launch configurationand in Arguments tab add -Djava.util.logging.config.file="your-tomcat-folder\conf\logging.properties" -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager.