Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> Re: Deleting files from O/S older than 6 hours

Re: Deleting files from O/S older than 6 hours

From: Carel-Jan Engel <careljan_at_dbalert.eu>
Date: Thu, 29 Nov 2007 12:10:02 +0100
Message-Id: <1196334603.2399.51.camel@lagavulin.dbalert.eu>


On Thu, 2007-11-29 at 02:56 -0800, Nigel Thomas wrote:
> Another trick is to create or touch a marker file at the time you do
> the move, which you can use "next time" to tell you the O/S time to
> compare with:
>
>
> find files newer than marker file (see earlier post)
> move them / delete them / archive them
> touch marker file now
>
>
> The only small issue is what happens to files added between 1 and 3
> (as the operations aren't exactly ACID)

That's why I do:

    touch temporary marker file
    find files newer than marker file
    do with them what you like
    move temporary marker file over marker_file

But this is getting much of a unix-shell thread now... Jared won the contest, with his perl script.

Best regards,

Carel-Jan Engel

===
If you think education is expensive, try ignorance. (Derek Bok) ===

--
http://www.freelists.org/webpage/oracle-l
Received on Thu Nov 29 2007 - 05:10:02 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US