Skip to content

How to Delete Old Audit Files in Oracle

ADUMP Cleanup

Audit files cannot be deleted like trace files deletion by ADR Command Interpreter (ADRCI), so we need to delete them at OS-level by ourselves.

In this post, we use OS command find to search for candidates older than 7 days 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 this command, we find and remove audit files which are older than 7 days in the audit file dump destination (AUDIT_FILE_DEST, also called ADUMP).

The question is, how to check the location of audit files (ADUMP)?

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. Required fields are marked *