Pages

Thursday, April 9, 2020

Deleting Old Archivelog Files Using RMAN

Deleting Old Archivelog Files Using RMAN


Use below rman script to delete archive logs older than 2 days.

rman target /
DELETE ARCHIVELOG ALL COMPLETED BEFORE 'sysdate-2';
CROSSCHECK ARCHIVELOG ALL;
DELETE EXPIRED ARCHIVELOG ALL;

For standby database:

rman target /
CONFIGURE ARCHIVELOG DELETION POLICY TO APPLIED ON STANDBY;
DELETE ARCHIVELOG ALL COMPLETED BEFORE 'sysdate-2';
CROSSCHECK ARCHIVELOG ALL;
DELETE EXPIRED ARCHIVELOG ALL;

No comments:

Post a Comment