script to delete trace files

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

script to delete trace files

Roshan
Hi,

is the script to purge trace files good?
http://haridba7.blogspot.com/2012/12/remove-old-trace-file-in-oracle-using.html

Regards,
Roshan
Reply | Threaded
Open this post in threaded view
|

Re: script to delete trace files

ErmanArslansOracleBlog
Administrator
Why dont you ask this to the writer of the script? :)
IF you cant understand this script, then I suggest you to write your own script, as during your writing you will learn, and it will help you in the future.

an info for you, this statement "find $PATH/$ORACLE_SID/udump/*.trc -mtime +15 -exec rm {} \;"  deletes all the files, which has been modified at least 15 days ago, and which have a .trc suffix in $PATH/$ORACLE_SID/udump

PATH and ORACLE_SID changes according to the environment.
You need to find the user dump dest by connecting to the database using sqlplus and then use a similar command like above to delete the trace files programatically. If you can do that, it is better and become more generic.

read the manual pages of find and exec command
Reply | Threaded
Open this post in threaded view
|

Re: script to delete trace files

Roshan