Skip to content

How to Delete Old Audit Files in Oracle

  • by

Purge Old Audit Files

Audit files cannot be deleted like trace files deletion by ADR Command Interpreter (ADRCI), so we use find which is an OS command to search for candidates and delete them subsequently. For example:

[oracle@primary01 ~]$ find /u01/app/oracle/admin/orcl/adump -type f -mtime +7 -name '*.aud' -exec rm -f {} \;

In which, we find and remove audit files which are older than 7 days in the audit file dump destination (AUDIT_FILE_DEST). The question is where is audit files?

To automate all log deletion, you may periodically delete log files by scheduling a cron job.

Leave a Reply

Your email address will not be published.