title: How to switch off NHibernate logging for INFO level?
body: <p>I am using NHibernate &amp; Net Persistence API with C# and MySql db in my project and I have UI layer (ASP.NET), Business Layer, and Data Access Layer (DAL). For logging, I am using log4net.</p>
  
  <p>I have web.config file in my UI layer, and there I have put following lines of code to disable NHibernate INFO level logging:</p>
  
  <pre><code>&lt;log4net debug="true"&gt;
          &lt;appender name="RollingLogFileAppender" type="log4net.Appender.RollingFileAppender"&gt;
              &lt;file value="Log.txt"/&gt;
              &lt;appendToFile value="true"/&gt;
              &lt;rollingStyle value="Date"/&gt;
              &lt;datePattern value="dd-MM-yyyy"/&gt;
              &lt;maxSizeRollBackups value="20"/&gt;
              &lt;maximumFileSize value="50MB"/&gt;
              &lt;staticLogFileName value="true"/&gt;
              &lt;layout type="log4net.Layout.PatternLayout"&gt;
                  &lt;conversionPattern value="%-5p %d %5rms %-22.22c{1} %-18.18M - %m%n"/&gt;
              &lt;/layout&gt;
          &lt;/appender&gt;
          &lt;root&gt;
              &lt;logger name="NHibernate" additivity="false"&gt;
                  &lt;level value="WARN"/&gt;
                  &lt;appender-ref ref="RollingFileAppender"/&gt;
              &lt;/logger&gt;
              &lt;level value="INFO"/&gt;
              &lt;appender-ref ref="RollingLogFileAppender"/&gt;            
          &lt;/root&gt;
      &lt;/log4net&gt;
  </code></pre>
  
  <p>But it is not working! I can still see INFO level logs, some of the lines from the logs are:</p>
  
  <pre><code>INFO  2013-01-09 01:15:06,383  6993ms Environment            lambda_method      - NHibernate 3.2.0.4000 (3.2.0.4000)
  INFO  2013-01-09 01:15:06,386  6996ms Environment            lambda_method      - hibernate-configuration section not found in application configuration file
  INFO  2013-01-09 01:15:06,387  6997ms Environment            lambda_method      - Bytecode provider name : lcg
  INFO  2013-01-09 01:15:06,388  6998ms Environment            lambda_method      - Using reflection optimizer
  INFO  2013-01-09 01:15:07,171  7781ms Dialect                lambda_method      - Using dialect: NHibernate.Dialect.MySQLDialect
  INFO  2013-01-09 01:15:07,390  8000ms Dialect                lambda_method      - Using dialect: NHibernate.Dialect.MySQLDialect
  INFO  2013-01-09 01:15:07,407  8017ms Mappings               lambda_method      - duplicate import: JDAL.Impl.Entities.EntityName, JDAL, Version=1.0.0.0,
  </code></pre>