logging-log4net-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Georg Jansen" <Georg.Jan...@FaktNet.com>
Subject RE: Specifying a specific folder for log files.
Date Tue, 29 Nov 2005 17:49:40 GMT


I have successfully used the configuration listed below: 


<appender name="RollingFileAppender"

   <file value="..\\..\\Error.Log"/>

   <lockingModel type="log4net.Appender.FileAppender+MinimalLock" />

   <layout type="log4net.Layout.PatternLayout">

      <conversionPattern value="%date [%thread] %-5level %logger [%ndc] -


   <appendToFile value="true" />

   <rollingStyle value="Size" />

   <maxSizeRollBackups value="10" />

   <maximumFileSize value="100KB" />

   <staticLogFileName value="true" />



The only difference I can se from your configuration to mine is that in your
configuration the file is specified as:


<param name="File" value="..\\Log\\Error.log"/>


While in my configuration the file is specified as:


<file value="..\\Log\\Error.log"/>


I tried to switch to your configuration, and that works as well, so this is
probably no answer to your issue, but only a confirmation that the
configuration you are trying, is working in my environment.


The new config section (in app.config) after I switched to your
configuration is listed below:


<appender name="ErrorRollingFileAppender"

   <param name="File" value="..\\Log\\Error.log" />

   <param name="AppendToFile" value="true" />

   <param name="MaxSizeRollBackups" value="10" />

   <param name="MaximumFileSize" value="500000" />

   <param name="RollingStyle" value="Size" />

   <param name="StaticLogFileName" value="true" />

   <layout type="log4net.Layout.PatternLayout">

      <param name="ConversionPattern" value="%n %d %-5p - %m%n" />




Best regards


http://www.l4ndash.com <http://www.l4ndash.com/>  - Log4Net Dashboard / Log


View raw message