Menu

PRoblems with logj4

Help
Miguel
2004-11-22
2013-06-03
  • Miguel

    Miguel - 2004-11-22

    Hello,

    I have a problem with log4j.
    When I start tomcat i get the following message:

    log4j:WARN No appenders could be found for logger (org.apache.commons.beanutils.ConvertUtils).
    log4j:WARN Please initialize the log4j system properly.

    I have a log4j configuration file in WEB-INF. This is the content:
    #begin log4j.props
    #IMPORTANT - Watch for trailing whitespaces after each statement!!!
    log4j.rootCategory=warn, stdout, logFile
    log4j.category.org.dbforms=WARN
    #out to console
    log4j.appender.stdout=org.apache.log4j.ConsoleAppender
    log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
    # Pattern to output the caller's file name and line number.
    log4j.appender.stdout.layout.ConversionPattern=%-4r [%t] %-5p %c %x - %m%n
    #out to file
    log4j.appender.logFile=org.apache.log4j.RollingFileAppender
    #tomcat uses bin as current directory when writing log
    log4j.appender.logFile.File=c:\log4j_log.txt
    log4j.appender.logFile.MaxFileSize=100KB
    log4j.appender.logFile.MaxBackupIndex=1

    My WEB-INF/web.xml file is this:
    <?xml version="1.0" encoding="ISO-8859-1"?>

    <!DOCTYPE web-app
        PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"
        "http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">

    <web-app>
        <servlet>
            <servlet-name>org.dbforms.ConfigServlet</servlet-name>
            <servlet-class>org.dbforms.servlets.ConfigServlet</servlet-class>
            <init-param>
                <param-name>log4j.configuration</param-name>
                <param-value>/WEB-INF/log4j.properties</param-value>
            </init-param>

    In WEB-INF/lib I have the following jar:
    commons-beanutils-1.6.jar
    commons-collections-2.1.jar
    commons-dbcp-1.1.jar
    commons-digester-1.5.jar
    commons-fileupload-1.0.jar
    commons-httpclient-2.0.jar
    commons-lang-2.0.jar
    commons-logging-1.0.3.jar
    commons-pool-1.1.jar
    commons-validator-1.0.2.jar
    dbforms2.3.jar
    hsqldb-1.7.1.jar
    httpunit-1.5.4.jar
    jasperreports-0.5.0.jar
    jtds-0.8.jar
    junit-3.8.1.jar
    log4j-1.2.8.jar
    maxq-0.95dev.jar
    msbase.jar
    mssqlserver.jar
    msutil.jar
    oro-2.0.7.jar
    protomatter-1.1.8-pre5.jar
    servletapi-2.3.jar
    xalan.jar
    xercesImpl.jar
    xmlParserAPIs-2.2.1.jar

    I am using dbforms 2.3.

    Where is the problem? and How can i solve it?

    Thanks.

     
    • Miguel

      Miguel - 2004-11-22

      I have forgotten one thing: I am using Tomcat 5.0.28.

       
      • Henner Kollmann

        Henner Kollmann - 2004-11-22
         
      • Henner Kollmann

        Henner Kollmann - 2004-11-23

        This is only a warning - the only thing you will miss is the logging output.

        Henner

         
    • Miguel

      Miguel - 2004-11-23

      I have tried this, but without success. I have the same problem.

      Are you sure this will solve the problem?

      Thanks.

       
    • Miguel

      Miguel - 2004-11-25

      So, It means that logging system does not work. Is it a problem of dbforms 2.3? Will it be sorted out in the next version?

      Thanks.

       
      • Henner Kollmann

        Henner Kollmann - 2004-11-25

        No, that seems to be a problem in your configuration.
        Could you test with the current 2.4 build? We changed the logging interface there - maybe it's working for you.

         

Log in to post a comment.

MongoDB Logo MongoDB