RMAN does
not delete ArchiveLogs on Primary Database when the State for the
Archive Destination to the Standby Database is set to 'defer'. When trying to delete ArchiveLogs, this Error is raised:
RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process
If we defer an Archive Destination to a Standby Database, the Primary Database will still consider the Standby Database as existing but temporary unavailable eg. for Maintenance. This can happen if you stop Log Transport Services from the Data Guard Broker or manually defer the State for the Archive Destination.
SOLUTION:
------------------
As long as the Archive Destination (log_archive_dest_n) is still set, we consider the Standby Database as still existing and preserve the ArchiveLogs on the Primary Database to perform Gap Resolution when the Archive Destination is valid again.
There are Situations when this is not wanted, eg. the Standby Database was activated or removed but you still keep the Archive Destination because you want to rebuild the Standby Database later again. In this Case you can set the hidden Parameter "_deferred_log_dest_is_valid" to FALSE (default TRUE) which will consider deferred Archive Destinations as completely unavailable and will not preserve ArchiveLogs for those Destinations any more. It is a dynamic Parameter and can be set this Way:
Reff: RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process (1380368,1)
RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process
If we defer an Archive Destination to a Standby Database, the Primary Database will still consider the Standby Database as existing but temporary unavailable eg. for Maintenance. This can happen if you stop Log Transport Services from the Data Guard Broker or manually defer the State for the Archive Destination.
SOLUTION:
------------------
As long as the Archive Destination (log_archive_dest_n) is still set, we consider the Standby Database as still existing and preserve the ArchiveLogs on the Primary Database to perform Gap Resolution when the Archive Destination is valid again.
There are Situations when this is not wanted, eg. the Standby Database was activated or removed but you still keep the Archive Destination because you want to rebuild the Standby Database later again. In this Case you can set the hidden Parameter "_deferred_log_dest_is_valid" to FALSE (default TRUE) which will consider deferred Archive Destinations as completely unavailable and will not preserve ArchiveLogs for those Destinations any more. It is a dynamic Parameter and can be set this Way:
SQL> alter system set "_deferred_log_dest_is_valid" = FALSE scope=both;
NOTE: This Parameter has been introduced with
Oracle Database 11.2.0.x. In earlier Versions you have to unset the
log_archive_dest_n-Parameter pointing to the remote Standby Database to
make the Primary Database considering it as completely unavailable.
There also exists a Patch on Top of 11.1.0.7 for some Platforms to
include this Parameter in 11.1.0.7, too. This is Patch Number 8468117. Reff: RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process (1380368,1)
No comments:
Post a Comment