Hi,

I have a number of daemon processes using Log::Log4perl and tens of
modules shared between them also using Log::Log4perl. All the log4perl
configuration is in a single file for convenience (as most modules in it
are common). Each perl module has its own log entry and logs to a
different file. The problem is there are ALOT of different log files
defined and Log4perl seems to open every file mentioned in the config
file even though only a handful might be used. e.g.,

config:
log4perl.logger.XXX.module1 = INFO, MONE
log4perl.appender.MONE=Log::Dispatch::File
log4perl.appender.MONE.filename=/tmp/file1.log

log4perl.logger.XXX.module2 = INFO, MTWO
log4perl.appender.MTWO=Log::Dispatch::File
log4perl.appender.MTWO.filename=/tmp/file2.log
.
.
.
etc

and daemon1 uses module XXX::module1 but not XXX.module2, the
/tmp/file2.log is opened in daemon1 even though it is never going to be
logged to. This is rather annoying since it is using up my open file
descriptors etc.

Using lsof on a single daemon shows dozens of log files open even though
there is NO chance it will log anything to them.

Is there any way to stop this?

Thanks.

Martin
-- 
Martin J. Evans
Easysoft Limited
http://www.easysoft.com

------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
_______________________________________________
log4perl-devel mailing list
log4perl-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/log4perl-devel

Reply via email to