Re: cron job at linux to remove trace and audit files

  • From: Stefan Koehler <contact@xxxxxxxx>
  • To: "oracle-l@xxxxxxxxxxxxx" <oracle-l@xxxxxxxxxxxxx>
  • Date: Tue, 9 Jun 2015 11:28:16 +0200 (CEST)

Hi Mostafa,
why every 5 minutes - is 1 hour also ok? Usually no need to setup a seperate
cronjob for that (or at least for all the trace files).

Just set the ADR retention policies (SHORTP_POLICY / LONGP_POLICY) accordingly.
For more details please check MOS ID #975448.1.

Best Regards
Stefan Koehler

Freelance Oracle performance consultant and researcher
Homepage: http://www.soocs.de
Twitter: @OracleSK


Mostafa Eletriby <dmarc-noreply@xxxxxxxxxxxxx> hat am 9. Juni 2015 um 11:17
geschrieben:

Hello professionals,
Please I need to set a cron job task to remove all trace and audit files at
database 11g every 5 minutes , platform linux v5
I want to know all the steps needed in order to run successfully because it
didn't work with me.
Please find below the steps performed.
Thanks

[root@Abohamad trace]# cat /etc/crontab

SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=root
HOME=/

# run-parts
01 * * * * root run-parts /etc/cron.hourly
02 4 * * * root run-parts /etc/cron.daily
22 4 * * 0 root run-parts /etc/cron.weekly
42 4 1 * * root run-parts /etc/cron.monthly
***********************************

00,05,10,15,20,25,30,35,40,45,50,55 * * * * root rm -rf
/opt/oracle/base/diag/rdbms/cdsdb/cdsdb/trace/*.trc & rm -rf
/opt/oracle/base/diag/rdbms/cdsdb/cdsdb/trace/cdmp* & rm -rf
/opt/oracle/base/diag/rdbms/cdsdb/cdsdb/trace/*.trm & rm -rf
/opt/oracle/base/admin/cdsdb/adump/*.aud
[root@Abohamad trace]#



[root@Abohamad sbin]# crontab -l
no crontab for root
[root@Abohamad sbin]#
--
//www.freelists.org/webpage/oracle-l


Other related posts: