Hello, Anyone know how to read a file but not interfere with the files owner (process) from re-naming the file?
I have an app that periodically (every few seconds) reads a log file generated by a server, then mangles data and finally reports what it finds from the log files contents. The server periodically stops writing to the current file and start writing to a new file when it closes the old file, it renames it (or tries too!). Rarely (but problematically) the server is unable to rename the log file it just finished because my perl app has opened it for reading (its open for a very brief time using a standard open <below>). open (CURREVNT, "$current_event_log) || warn "-332 Open Current Logfile Failed (ERR: $! )\n"; Is there any way for me too read the contents of the log files without preventing the server from re-naming it (on the odd occurrence when the two collide)? Extra stuff: a. Platform->Windows NT 4 Svc Pack 6 [Without Perl (app compiled using Perlapp and running on NT 4)] b. Perl Program running as administrator (same as server process owner) c. 1 GB Physical Mem d. System Nominally operates at about 60% of its processing capacity V/R BigAl [EMAIL PROTECTED] _______________________________________________ Perl-Win32-Users mailing list [email protected] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
