Re: Log file rotation and deletion

Tech Tip: Click here to run a free scan for Windows Errors and optimize PC performance




"Jason" <Jason@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:4F5FEB57-9526-415F-9966-2982C1B6D119@xxxxxxxxxxxxxxxx
I am looking for a way to keep a 12 month rotation of log files generated
in
a windows environment. I want to make a copy of the current log file and
rotate the old ones through every month. When a log file reachs the end of
the rotation I want it to be deleted.
There is a Linux environment program called logrotate which does this. I
am
basically looking for its windows equivelent if it exists.
I would also like to have the option to simply delete daily generated *.*
log files from a specific directory on my server whatever the extention
may
be.

Thank you
--
Jason
MS Admin

Can you give an example of what you're trying to do?


.



Relevant Pages

  • Re: Rotating logs (and keeping the logs tail)
    ... I use a wiki engine that produces an event log, which I want to rotate. ... Can't you just write a script that updates the tag to a separate file, ... # rotate-and-keep.sh - Rotate a log file, ... # GNU General Public License for more details. ...
    (Debian-User)
  • Re: Minor HEADSUP - "New order" for newsyslog
    ... waits 10 seconds (after all signals are sent) ... are done in a safer order, and any single daemon is sent only ... one signal (instead of one signal for each log file that needed ... to rotate a large number of apache log files, ...
    (freebsd-current)
  • Re: How to remove a single line from a flat file (Still very off-topic.)
    ... Every program that writes a log file under UNIX needs a way to split the old from the current. ... Contrast with a file system that actually stores records you can delete. ... Simply open the log file, copy the records you want to "rotate", and delete them off the front of the log file as you go. ... And that lock should be in the file system, rather than as a user-level work-around for a lack of functionality. ...
    (comp.lang.tcl)
  • Re: newsyslog(8) patch for both size and time checks
    ... Any objection to commit this? ... log file will only be rotated if both conditions are true. ... With the documented behavior, the effect is "rotate ... add a new flag to control this behavior. ...
    (freebsd-current)
  • Re: logrotate Problem
    ... I have a Problem to create the log file. ... It says logrotate is controled be a cron job. ... # rotate log files weekly ... # RPM packages drop log rotation information into this directory ...
    (RedHat)