SELECT resetlogs_time FROM v$database ;
SELECT xep.legal_entity_id "Legal Entity ID", xep.name "Legal Entity", hr_outl.name "Organization Name", hr_outl.organization_id "Organization ID", hr_loc.location_id "Location ID", hr_loc.country "Country Code", hr_loc.location_code "Location Code", glev.flex_segment_value "Company Code" FROM xle_entity_profiles xep, xle_registrations reg, -- hr_operating_units hou, -- hr_all_organization_units hr_ou, hr_all_organization_units_tl hr_outl, hr_locations_all hr_loc, -- gl_legal_entities_bsvs glev WHERE 1=1 AND xep.transacting_entity_flag = 'Y' AND xep.legal_entity_id = reg.source_id AND reg.source_table = 'XLE_ENTITY_PROFILES' AND reg.identifying_flag = 'Y' AND xep.legal_entity_id = hou.default_legal_context_id AND reg.location_id = hr_loc.location_id AND xep.legal_entity_id = glev.legal_entity_id -- -- AND hr_ou.organization_id = hou.business_group_id AND hr_outl.organization_id = hou.organization_id ORDER BY hr_outl.name
RMAN> delete noprompt archivelog all; using target database control file instead of recovery catalog allocated channel: ORA_DISK_1 channel ORA_DISK_1: SID=24 device type=DISK RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process archived log file name=/u01/app/oracle/admin/db1/arch/1_146_812203684.dbf thread=1 sequence=146 RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process archived log file name=/u01/app/oracle/admin/db1/arch/1_147_812203684.dbf thread=1 sequence=147 RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process archived log file name=/u01/app/oracle/admin/db1/arch/1_148_812203684.dbf thread=1 sequence=148 RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process archived log file name=/u01/app/oracle/admin/db1/arch/1_149_812203684.dbf thread=1 sequence=149
RMAN > delete noprompt force archivelog all;
RMAN> show all; CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default RMAN> CONFIGURE ARCHIVELOG DELETION POLICY TO SHIPPED TO STANDBY; new RMAN configuration parameters: CONFIGURE ARCHIVELOG DELETION POLICY TO SHIPPED TO STANDBY; new RMAN configuration parameters are successfully stored RMAN-08591: WARNING: invalid archived log deletion policy
RMAN> show all; CONFIGURE ARCHIVELOG DELETION POLICY TO SHIPPED TO STANDBY;
RMAN> delete noprompt archivelog all; released channel: ORA_DISK_1 allocated channel: ORA_DISK_1 channel ORA_DISK_1: SID=147 device type=DISK List of Archived Log Copies for database with db_unique_name DB1 ===================================================================== Key Thrd Seq S Low Time ------- ---- ------- - --------- 239 1 146 A 24-MAY-13 Name: /u01/app/oracle/admin/db1/arch/1_146_812203684.dbf 247 1 147 A 24-MAY-13 Name: /u01/app/oracle/admin/db1/arch/1_147_812203684.dbf 249 1 148 A 24-MAY-13 Name: /u01/app/oracle/admin/db1/arch/1_148_812203684.dbf 250 1 149 A 24-MAY-13
Name: /u01/app/oracle/admin/db1/arch/1_149_812203684.dbf
..........
..........
deleted archived log
archived log file name=/u01/app/oracle/admin/db1/arch/1_146_812203684.dbf RECID=239 STAMP=816273514
deleted archived log
.........
………
RMAN> crosscheck archivelog all;
RMAN> CONFIGURE ARCHIVELOG DELETION POLICY CLEAR;
CONFIGURE ARCHIVELOG DELETION POLICY TO SHIPPED TO STANDBY;
While RMAN full backup, today i have encountered “RMAN-06059: expected archived log not found, loss of archived log compromises recoverability”
RMAN error.
Solution for the mentioned error is to Crosscheck your archive logs from RMAN prompt and delete those expired logs who are not needed anymore.
While crosscheck archivelogs, RMAN will marked archives as Expired in his repository (i.e. controlfile or catalog) those who are not physically present there. So we can easily delete expired archives from controlfile or catalog repository.
Error log 1 :
RMAN> RUN 2> { 3> ALLOCATE CHANNEL backup1 DEVICE TYPE DISK FORMAT 'Z:\RMAN\%U'; 4> BACKUP DATABASE PLUS ARCHIVELOG; 5> } using target database control file instead of recovery catalog allocated channel: backup1 channel backup1: SID=70 device type=DISK Starting backup at 10-SEP-14 current log archived released channel: backup1 RMAN-00571: =========================================================== RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS =============== RMAN-00571: =========================================================== RMAN-03002: failure of backup plus archivelog command at 09/10/2014 18:22:35 RMAN-06059: expected archived log not found, loss of archived log compromises recoverability ORA-19625: error identifying file E:\ORACLE\--ORACLE_SID--\ORAARCH\1_35338_778192583.DBF ORA-27041: unable to open file OSD-04002: unable to open file O/S-Error: (OS 2) The system cannot find the file specified. Error log 2 :
Starting backup at 26-JUL-12
current log archived
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=155 devtype=DISK
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of backup plus archivelog command at 07/26/2012 22:55:32
RMAN-06059: expected archived log not found, lost of archived log compromises recoverability
ORA-19625: error identifying file /app/oracle/product/10.2/dbs/arch1_1_781981525.dbf
ORA-27037: unable to obtain file status
SVR4 Error: 2: No such file or directory
Additional information: 3
Cause:
This can happen for a variety of reasons; the file has been manually moved or deleted,
the archive log destination has recently been changed,
the file has been compressed, etc
Solution:
Your options are either to restore the missing file(s), or to perform a crosscheck.
To perform a crosscheck, run the following command from within RMAN:
RMAN> CROSSCHECK ARCHIVELOG ALL;
Above command will give information of expired RMAN repository after verification. (i.e. in catalog or controlfile)
Above will marked archives as Expired who are not available physically and who are not required for any kind of recovery.
RMAN> DELETE EXPIRED ARCHIVELOG ALL;
Above command will delete all archive logs who are marked as expired while crosscheck.
What? When using RMAN to backup archivelog files, an error “RMAN-06059: Errror identifying file ” is returned. Prior to this the backups have been running successfully.
RMAN-03002: failure of backup plus archivelog command RMAN-06059: expected archived log not found, lost of archived log compromises recoverability RMAN-6059: expected archived log not found, lost of archived log compromises recoverability ORA-19625 “error identifying file %s” Why? Oracle is trying to backup an archivelog and is expecting for it to be available as it could be required for recovery.
Cause: The archive log is no longer accessible. One of the common reasons is that the archive log has been removed manually to free up space on the system or the permissions on the file was changed.
Resolution: The most important thing is to determine what caused the file to not be available.
Then to get around this error, to allow RMAN to continue backing up the database first connect to the RMAN repository. The run the “CROSSCHECK ARCHIVELOG ALL”.
RMAN will continue to backup the rest of the archivelogs.
Caution: Ensure that you also take a full backup since one f the archivelogs is not available in the backupsets and will limit your ability to do a complete recovery without it.
When we are taking archive log backup with delete then got an error.
RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process archived log file name=/pac/lci9t1/arch/redo_1_16470_842608348.arc thread=1 sequence=16470 RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process archived log file name=/pac/lci9t1/arch/redo_1_16471_842608348.arc thread=1 sequence=16471 RMAN-08137: WARNING: archived log not deleted, needed for standby or upstream capture process
SOLUTION:
Cause: The archive logs seems that it is not yet applied in the standby database.
Select sequence# , applied from v$archived_log;
Action: Check the standby database and apply the logs manually and the start the deletion process.
I can delete the archive logs by force using the below command.
RMAN > delete noprompt force archivelog all;
But I don’t want to delete the archives which are not applied in standby so i’m changing the configuration
RMAN> show all;
Old configuration:
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
Change as Below:
RMAN> CONFIGURE ARCHIVELOG DELETION POLICY TO SHIPPED TO STANDBY; new RMAN configuration parameters: CONFIGURE ARCHIVELOG DELETION POLICY TO SHIPPED TO STANDBY; new RMAN configuration parameters are successfully stored RMAN-08591: WARNING: invalid archived log deletion policy Now check the configuration
RMAN> show all;
CONFIGURE ARCHIVELOG DELETION POLICY TO SHIPPED TO STANDBY;
Now I am able to delete those archivelogs now.
RMAN> delete noprompt archivelog all; RMAN> crosscheck archivelog all;
Once I deleted those logs, I changed the rman configuration by the default one.
RMAN> CONFIGURE ARCHIVELOG DELETION POLICY CLEAR; RMAN> Show all;