Hi,
Using log4j version 1.2.15. RollingFileAppender used in the configuration works fine with the app deployed on the local machine, with MaxFileSize and MaxBackUp index behaving as expected. However on a server where the application is deployed, the log files build up to much higher sizes - 5MB, 3MB etc and the BackUp files are randomly deleted. I see only infra.log and infra.log.2 etc. Any lead on this will be truly appreciated. A section of my log4j.xml: <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd"> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/"> <appender name="INFRA_INFO" class="org.apache.log4j.RollingFileAppender"> <param name="File" value="D:/logs/infra/infra_info.log"/> <param name="Append" value="true"/> <param name="MaxFileSize" value="1MB"/> <param name="MaxBackupIndex" value="2"/> <layout class="org.apache.log4j.PatternLayout"> <param name="ConversionPattern" value="%d{dd:MM:yyyy HH:mm:ss} %p - %C{1}.%M(%L) | %m%n"/> </layout> <filter class="org.apache.log4j.varia.LevelRangeFilter"> <param name="LevelMin" value="INFO"/> <param name="LevelMax" value="INFO"/> <param name="AcceptOnMatch" value="true"/> </filter> <filter class="org.apache.log4j.varia.DenyAllFilter"/> </appender> <logger name="com.xyz.abc.infra"> <level value="INFO"/> <appender-ref ref="INFRA_INFO"/> </logger> </log4j:configuration> Regards, Bhramara Extn: 6279 DISCLAIMER: This message contains privileged and confidential information and is intended only for an individual named. If you are not the intended recipient, you should not disseminate, distribute, store, print, copy or deliver this message. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmission cannot be guaranteed to be secure or error-free as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete or contain viruses. The sender, therefore, does not accept liability for any errors or omissions in the contents of this message which arise as a result of e-mail transmission. If verification is required, please request a hard-copy version.
