Disable NHibernate logging

Solution 1:

Configure Log4Net for use with NHibernate may be helpful.

You need to have both these loggers:

 <logger name="NHibernate">
   <level value="ERROR" />
 </logger>

 <logger name="NHibernate.SQL">
   <level value="ERROR" />
 </logger>

Solution 2:

return Fluently.Configure()
            .Database(MsSqlConfiguration.MsSql2005.ConnectionString(
                c => c.FromConnectionStringWithKey("MyDB")).ShowSql())

Removing the .ShowSql() worked for me