Hi, We are using log4cxx in our application running on Windows. The maximum size for log file is defined in log4j.properties as follows:
log4j.appender.R.MaxFileSize=1000KB The log file size goes up to more than 1000 kb to 13gb some times. We have seen this issue several times, but unable to recreate it consistently. Our application consists of two components: 1. Shared Library file - DLL (It includes the log4cxx, apr libraries statically) and it has it's own initialization sequence for log4cxx. 2. Executable file and it linked to DLL file dynamically mentioned above (It also includes the log4cxx, apr libraries statically) and it has it's own initialization sequence for log4cxx). Here is the sequence of log4cxx in both executable and DLL: log4cxx::BasicConfigurator::configure(); log4cxx::File cfgFile("conf/log4j.properties"); log4cxx::PropertyConfigurator::configureAndWatch(cfgFile, 60000); We had to add initialization sequence in both executable and DLL in order to get log message from both of them (Executable and DLL). Any help is appreciated to stop the log file grows more than 1000 kb. Note: We never experienced this issue when we link our DLL and executable statically. But, we have to make our library as DLL as per our requirements. thanks, -- Shyam