commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <>
Subject Re: [io] Apache Tailer prevents log4j from creating backup files?
Date Fri, 08 Apr 2011 12:15:06 GMT
On 8 April 2011 04:37, Hemal Pandya <> wrote:
> [I Just realized the list allows posts from non-subscribers, but
> following up on an existing post is not easy. Hopefully this will land
> up in the same thread]
>> OS? Java version? IO version?
> I am developing on Windows XP SP2 but it would be deployed on Windows
> Server 08.

In which case I think you may be out of luck. It looks like Java on
Windows locks a file entry that is open for read, even though the file
itself can be written.

Just had a look at the test cases, and they don't appear to check that
the tailed file can actually be deleted and/or renamed.

I don't know if there is a different way for Tailer to open the file -
maybe NIO offers something here.

> Java version is 1.6.0, _20 or higher. I downloaded the
> latest common-io yesterday, commons-io-2.0.1.
> Thanks
> Hemal
> On Thu, Apr 7, 2011 at 10:34 PM, Hemal Pandya <> wrote:
>> Hello,
>> I am trying to use Apache Tailer for a utility that processes log file entries.
>> My log4j configuration creates backup files when the max file size has been reached.
It seems the Tailer is correctly handling the file roll over without missing any lines but
log4j is no longer creating the .1 etc back-up files. I suspect it is a conflict between with
how Tailer has opened the file and how log4j created backups.
>> Does anybody else have similar experience? Is it a usage error on my part?
>> Thanks in advance for any answers, pointers or suggestions.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message