title: How to resolve this error message "log4j:ERROR Property missing when configuring log4j: grails"
body: <p>I've been working with grails for a period time and feel like this error can be dealt with.</p>
  
  <p>Everytime I try my "run-app" command, and when I watch the log files as the deployment I see this line in the output</p>
  
  <pre><code>log4j:ERROR Property missing when configuring log4j: grails
  </code></pre>
  
  <p>I can not figure what its looking for.  I have several environments that I'm deploying to and each environment displays the same message.</p>
  
  <p>Here is my block from my config.groovy:</p>
  
  <pre><code>def appName = "${appName}"
  def catalinaBase = System.properties.getProperty('catalina.base')
  if (!catalinaBase) catalinaBase = '.'   // just in case
  def logDirectory = "${catalinaBase}/logs"
  
  log4j = { root -&gt;
  appenders {
      rollingFile name:'stdout', file:"${logDirectory}/${appName}.log".toString(), maxFileSize:'10MB'
      rollingFile name:'stacktrace', file:"${logDirectory}/${appName}_stack.log".toString(), maxFileSize:'1MB'
  }
  
   error  'org.codehaus.groovy.grails.web.servlet',  //  controllers
         'org.codehaus.groovy.grails.web.pages', //  GSP
         'org.codehaus.groovy.grails.web.sitemesh', //  layouts
         'org.codehaus.groovy.grails.web.mapping.filter', // URL mapping
         'org.codehaus.groovy.grails.web.mapping', // URL mapping
         'org.codehaus.groovy.grails.commons', // core / classloading
         'org.codehaus.groovy.grails.plugins', // plugins
         'org.codehaus.groovy.grails.orm.hibernate', // hibernate integration
         'org.springframework',
         'org.hibernate'
  warn   'grails',
         'grails.plugin.webxml.WebxmlGrailsPlugin', 
     'grails.app.service',
     'grails.plugins.hawkeventing',
     'net.sf.ehcache.hibernate'
  root.level = org.apache.log4j.Level.INFO
  grails.plugin.databasemigration.updateOnStart = true
  }
  codenarc {
  reportName = 'target/test-reports/CodeNarcReport.xml'
  reportType = 'xml'
  propertiesFile = 'grails-app/conf/codenarc.properties'
  }
  environments {
  development {
      log4j = { root -&gt;
          appenders {
              console name: 'stdout', layout: pattern(conversionPattern: "%d [%t] %-5p %c %x - %m%n")
          }
          error   'org.codehaus.groovy.grails.web.servlet',  //  controllers
                  'org.codehaus.groovy.grails.web.pages', //  GSP
                  'org.codehaus.groovy.grails.web.sitemesh', //  layouts
                  'org.codehaus.groovy.grails.web.mapping.filter', // URL mapping
                  'org.codehaus.groovy.grails.web.mapping', // URL mapping
                  'org.codehaus.groovy.grails.commons', // core / classloading
                  'org.codehaus.groovy.grails.plugins', // plugins
                  'org.codehaus.groovy.grails.orm.hibernate', // hibernate integration
                  'org.springframework',
                  'org.hibernate',
                  'org.codehaus.groovy.grails.compiler'
          warn    'grails',
                  'grails.app.service',
          'grails.plugin.webxml.WebxmlGrailsPlugin',      
                  'grails.plugins.hawkeventing',
          'net.sf.ehcache.hibernate'
          root.level = org.apache.log4j.Level.INFO
          grails.plugin.databasemigration.updateOnStart = true
      }
  
      codenarc {
          reportName = 'target/test-reports/CodeNarcReport.html'
          reportType = 'html'
      }
      //grails.plugin.databasemigration.updateOnStart = false
  }
  
  staging {
      log4j = { root -&gt;
          appenders {
              rollingFile name:'stdout', file:"${logDirectory}/${appName}.log".toString(), maxFileSize:'10MB'
              rollingFile name:'stacktrace', file:"${logDirectory}/${appName}_stack.log".toString(), maxFileSize:'10MB'
              //console name: 'stdout', layout: pattern(conversionPattern: "%d [%t] %-5p %c %x - %m%n")
          }
           warn   'org.codehaus.groovy.grails.web.servlet',  //  controllers
                  'org.codehaus.groovy.grails.web.pages', //  GSP
                  'org.codehaus.groovy.grails.web.sitemesh', //  layouts
                  'org.codehaus.groovy.grails.web.mapping.filter', // URL mapping
                  'org.codehaus.groovy.grails.web.mapping', // URL mapping
                  'org.codehaus.groovy.grails.commons', // core / classloading
                  'grails.app.service',
                  'org.codehaus.groovy.grails.compiler',
                  'org.springframework'
          debug   'org.hibernate',
                  'org.codehaus.groovy.grails.plugins', // plugins
                  'org.codehaus.groovy.grails.orm.hibernate', // hibernate integration                    
                  'com.sexingtechnologies',
                  'grails.plugins.hawkeventing',
                  'net.sf.ehcache.hibernate'                  
          error   'grails',                   
                  'grails.plugin.webxml.WebxmlGrailsPlugin'
  
          root.level = org.apache.log4j.Level.INFO
          grails.plugin.databasemigration.updateOnStart = true
  
      }
  
      codenarc {
          reportName = 'target/test-reports/CodeNarcReport.html'
          reportType = 'html'
      }
      //grails.plugin.databasemigration.updateOnStart = false
  }
  
  dbdiff {
      log4j = { root -&gt;
          appenders {
              console name: 'stdout', layout: pattern(conversionPattern: "%d [%t] %-5p %c %x - %m%n")
          }
          warn    'org.codehaus.groovy.grails.web.servlet',  //  controllers
                  'org.codehaus.groovy.grails.web.pages', //  GSP
                  'org.codehaus.groovy.grails.web.sitemesh', //  layouts
                  'org.codehaus.groovy.grails.web.mapping.filter', // URL mapping
                  'org.codehaus.groovy.grails.web.mapping', // URL mapping
                  'org.codehaus.groovy.grails.commons', // core / classloading
                  'org.codehaus.groovy.grails.plugins', // plugins
                  'org.codehaus.groovy.grails.orm.hibernate', // hibernate integration
                  'org.springframework',
                  'org.hibernate'
          debug  'grails.app.service',
  
          root.level = org.apache.log4j.Level.INFO
      }
  }
  </code></pre>
  
  <p>}</p>
  
  <p>What am I missing here that log4j is looking for?</p>