|
|
| P is for Practical | |
| PerlMonks |
Re: Removing old records from log filesby Zaxo (Archbishop) |
| on Aug 22, 2001 at 10:21 UTC ( [id://106907]=note: print w/replies, xml ) | Need Help?? |
This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.
With that rate of logging, you are likely to need locks the logger respects to modify the file in place. Given that, a binary search strategy will speed your search for the cutoff time. Another approach would be to set up a cron job renaming the log file out of the way at set times. You may have a system utility called logrotate which specializes in that. Update: Oops :-) After Compline,
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||||||