Oracle DBA Tips and Techniques

By Arjun Raja

RMAN WILL NOT DELETE ARCHIVELOG NEEDED FOR RECOVERY ON STANDBY DATABASE

Posted by Arjun Raja on December 1, 2009

RMAN command issued to backup and delete all archivelogs on PRIMARY database.

RMAN > BACKUP ARCHIVELOG ALL DELETE INPUT;

archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_10_22/o1_mf_1_5182_5fzsdwgv_.arc recid=10340 stamp=700923294
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_10_23/o1_mf_1_5183_5g3b7jt1_.arc recid=10342 stamp=701038835
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_10_25/o1_mf_1_5184_5g6pzq0g_.arc recid=10344 stamp=701150202
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_10_26/o1_mf_1_5185_5gc5c5kw_.arc recid=10346 stamp=701295975
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_10_27/o1_mf_1_5186_5gdp4vvn_.arc recid=10348 stamp=701345949
RMAN-08137: WARNING: archive log not deleted as it is still needed archive log
filename=/u02/oradata/flash_recovery_area/Test/archivelog/2009_10_27/o1_mf_1_5187_5gdpby1j_.arc thread=1 sequence=5187
channel ORA_SBT_TAPE_1: deleting archive log(s)
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_08_25/o1_mf_1_5128_596rhksp_.arc recid=10232 stamp=695822449
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_08_26/o1_mf_1_5129_59bdjhbv_.arc recid=10234 stamp=695941266
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_08_28/o1_mf_1_5130_59frckcs_.arc recid=10236 stamp=696051699
archive log
filename=/u02/oradata/flash_recovery_area/TEST/archivelog/2009_08_29/o1_mf_1_5131_59jkd348_.arc recid=10238 stamp=696142854

In this case, archivelog sequence 5187 was not yet applied on standby database – hence RMAN will not delete it from the PRIMARY database disk.

This is a safety measure to make sure primary and standby databases can remain in sync

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

 
%d bloggers like this: