Delete archivelog in the primary database
2013-09-18 10:25
411 查看
ORACLE_RMAN_delete archivelog in the primary database
About RMAN-08137, please refer to :
1. Case 1
Check that the standby database is uptodate - if not, restartmanaged recovery and resolve the gap first then query the Primaryv$archived_log view again for any log sequences that still have applied='NO'.
If you still have logs with applied='NO' and you are certain that these logshas been applied at standby and there is no 'gap', you need to remove theentries from the rman repository:
a. check that the physical files still exist on disk and if they do, usean OS command to delete them
b. run crosschek followed by delete expired to remove them from the rmanrepository
RMAN>crosscheckarchivelog all;
RMAN>delete expired archivelog all;
Once the problematic log(s) have been removed from the rman repositoryyou can resume normal use of 'delete input' option on the backup command.
2. Case 2
RMAN is used to backup archivelogs fromPrimary site using the syntax:
backup archivelog ...... delete input;
All logs are backed up successfully but not deleted; for each log the
following error is returned:
RMAN-8137: WARNING: archive log not deleted as it is still needed
archive log filename=<log> thread=<thrd> sequence=<seq>
The archivelogs have definitely been shipped and applied to standby site
which runs in maximum availability mode.
No logs are being deleted from Primary site after backup leaving the database
at risk of going down if the archivelog directory fills.
Logs have to be deleted manually.
WORKAROUND:-----------
Donot use DELETE INPUT option when backing up logs in a Data Guard environment.
Use instead (for example):
backup ARCHIVELOG UNTIL TIME '<date>' not backed up 1 times to devicetype
sbt;
delete archivelog until time '<date>' backed up 1 times to device typesbt;
Just a case:
delete noprompt archivelog until time'sysdate -1' backed up 1 times to device type sbt;
Or
run{
ALLOCATE CHANNEL FOR MAINTENANCE TYPEDISK;
crosscheck archivelog all;
delete noprompt archivelog until time 'sysdate -1' backed up1 times to device type sbt;
delete noprompt archivelog until time 'sysdate -1' backed up1 times to device type disk;
release channel;
}
About RMAN-08137, please refer to :
1. Case 1
Check that the standby database is uptodate - if not, restartmanaged recovery and resolve the gap first then query the Primaryv$archived_log view again for any log sequences that still have applied='NO'.
If you still have logs with applied='NO' and you are certain that these logshas been applied at standby and there is no 'gap', you need to remove theentries from the rman repository:
a. check that the physical files still exist on disk and if they do, usean OS command to delete them
b. run crosschek followed by delete expired to remove them from the rmanrepository
RMAN>crosscheckarchivelog all;
RMAN>delete expired archivelog all;
Once the problematic log(s) have been removed from the rman repositoryyou can resume normal use of 'delete input' option on the backup command.
2. Case 2
RMAN is used to backup archivelogs fromPrimary site using the syntax:
backup archivelog ...... delete input;
All logs are backed up successfully but not deleted; for each log the
following error is returned:
RMAN-8137: WARNING: archive log not deleted as it is still needed
archive log filename=<log> thread=<thrd> sequence=<seq>
The archivelogs have definitely been shipped and applied to standby site
which runs in maximum availability mode.
No logs are being deleted from Primary site after backup leaving the database
at risk of going down if the archivelog directory fills.
Logs have to be deleted manually.
WORKAROUND:-----------
Donot use DELETE INPUT option when backing up logs in a Data Guard environment.
Use instead (for example):
backup ARCHIVELOG UNTIL TIME '<date>' not backed up 1 times to devicetype
sbt;
delete archivelog until time '<date>' backed up 1 times to device typesbt;
Just a case:
delete noprompt archivelog until time'sysdate -1' backed up 1 times to device type sbt;
Or
run{
ALLOCATE CHANNEL FOR MAINTENANCE TYPEDISK;
crosscheck archivelog all;
delete noprompt archivelog until time 'sysdate -1' backed up1 times to device type sbt;
delete noprompt archivelog until time 'sysdate -1' backed up1 times to device type disk;
release channel;
}
相关文章推荐
- 190 The database is configured in ARCHIVELOG mode and regular complete database backups are taken. T
- 87.You are managing an Oracle Database 11g database running in ARCHIVELOG mode. The Flash Recovery A
- 74.The database is running in ARCHIVELOG mode. Examine the initialization parameters and their value
- 75.Your test database is configured to run in NOARCHIVELOG mode. One of the data files in the USERS
- 72.You want to enable archiving on your database. Presently, the database is running in NOARCHIVELOG
- 137 While Monitoring the space usage in your database that is in ARCHIVELOG mode you observed that t
- 4.Your test database is running in NOARCHIVELOG mode. Which statement is true regarding the type of
- Excessive growth of the primary database log mirror and system Performance Monitoring
- ORA-16714: the value of property ArchiveLagTarget is inconsistent with the database setting
- Judging whether object existed in the database, if it does, delete it.
- sql server 2008 R2 Error 9003:The log scan number passed to log scan in database is not valid
- 关于oracle的backup database plus archivelog delete input备份命令
- RMAN-06820: WARNING: failed to archive current log at primary database
- Could not store transport type data for Receive Location 'Recv.Loc' to config store. Primary SSO Server 'Sql-server' failed. The external credentials in the SSO database are more recent.
- Delete all tables in database(Ignore the relations between tables)
- RMAN-06817: Pluggable Database CHARLESPDB cannot be backed up in NOARCHIVELOG mode.
- sybase Space available in the log segment has fallen critically low in database 'tempdb'.
- The transaction log for database 'NJ_Address' is full. To find out why space in the log cannot be
- 126.Identify the two situations in which you use the alert log file in your database to check the de
- The log scan number (620023:3702:1) passed to log scan in database 'xxxx' is not valid