Skip Menu |

This queue is for tickets about the File-Tail CPAN distribution.

Report information
The Basics
Id: 39762
Status: resolved
Priority: 0/
Queue: File-Tail

People
Owner: Nobody in particular
Requestors: david-e.hansen [...] ubs.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject: File::Tail doesn't work on Windows with certain rotation scheme
Date: Thu, 2 Oct 2008 13:08:23 +0200
To: <bug-File-Tail [...] rt.cpan.org>
From: <david-e.hansen [...] ubs.com>
Based on the present E-Mail exchange, and/or on the agreement reached with you, respectively, UBS is entitled to contact you via insecure E-Mail: (a) E-Mails contain substantial risks such as lack of confidentiality, manipulation of content and sender, misdirection, viruses etc. UBS does not accept any liability for damages arising from use of E-mail. Accordingly, UBS recommends to abstain from sending any sensitive information via E-Mail, from forwarding the text received when submitting reply E-Mails and recommends to manually capture the E-Mail address in every instance. If you should wish to verify the content of this message, please request a hard-copy version. (b) In principle, UBS does not accept any (purchase) orders, cancellation of orders or authorizations etc. via E-mail. If UBS receives such E-Mails, UBS is not obliged to expressly decline them. If you have received this E-Mail by mistake or do not wish to be contacted by E-Mail in the future, you are kindly asked to inform UBS accordingly. Any E-Mail received by mistake (including all its annexes) needs to be destroyed and the content may not be forwarded nor disclosed to any further persons. c) This message is provided for informational purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments.
Hi, I have a Windows application which uses the following log file rotation scheme: - Rename Logger.log Logger_bak<n>.log, where <n> is a monotomically increasing integer - Create new Logger.log file - Continue logging to (now empty) Logger.log file. When I try to use File::Tail on this log file, the application stops logging, because the "rename" step gets a system error (file in use) -- Windows sees that the Perl script is holding an open connection to the file, and does not allow it to be renamed by another process. So, bottom line is, it doesn't always work on Windows. Regards, David Hansen
One could point out that File::Tail is still doing it's job, it's just that the other process can not rename the file - which is an OS limitation. I don't see what could be changed in File::Tail to make this possible, other than constantly closing and opening the file, in the hope that the rename will just happen always to hit the window when the file is closed. Which would be a really lousy fix.