-
unix sheel: how do I remove trace files older than x date ?
Does anyone have the code to remove trace files that are older than a certain date ?
-
without knowing some particulars, a variation on
find . -new 'keeper file name' -print | rm
would work. (Substitute a real file name where obvious).
other variations would use -mtime, -ctime or -atime parameters of find.
Joseph R.P. Maloney, CSP,CDP,CCP
'The answer is 42'
-
Try this on UNIX
find . -name *trc -atime +7 -exec rm {} \;
if on NT get there are some nt ports available of the common unix commands
-
There are lots of variations on find. man find will give you the details...
Jeff Hunter
-
If your installation follows OFA, the following command will trim logs that have not been accessed withing the past 7 days...
*** replace ? with your database name (i.e ORCL) ***
find $ORACLE_HOME/admin/?/bdump -name "*.trc" -atime +7 -exec rm {} \;
alapps
Fast, Cheap, Reliable... Pick Two(2)
-
Thankyou rfmm1 amd alapps,
that was exactly what I was looking for.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|