2
votes

I have a number of identical processes that are writing to a single log file using a Log4j DailyRollingFileAppender. I am concerned that multiple processes may try and roll the file and that chaos will ensue. Does the implementation allow for this using with some kind of locking mechanism? - the Javadoc doesn't mention it.

1
Out of interest why not use separate log files, if it because you want an aggregated view then have you heard of Splunk? - JARC
possible duplicate of Log4j Logging to a Shared Log File - user180100

1 Answers

2
votes

it is not advisible to let multiple processes access the same log file. mayhem will occur