Survey
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
To force database open: 4/13/10 1. To force database open: a. shutdown database b. edit parameter file (initSID.ora) and add: s C:\oraclexe\app\oracle\product\10.2.0\server\database\initXE.ora SPFILE='C:\oraclexe\app\oracle\product\10.2.0\server\dbs/spfileXE.ora' Could not add the above statement in initXE.ora due to the fact that spfileXE.ora is not editable. c. startup mount d. recover database using backup controlfile until cancel -- type cancel e. open the database with: alter database open resetlogs; If the database does not open, please upload the full screen shot, alert.log and any trace file created. If the database DOES open, run a full database export. Information on export and datapump can be found in: Oracle® Database Utilities 10g Release 2 (10.2) http://download.oracle.com/docs/cd/B19306_01/server.102/b14215/toc.htm If you need additional information on that, let me know and I will log an SR to the utilities group. At this time, we will work on getting this database open let me know the results of above steps and/or if you have any questions on the procedure. 4/19/10 === ODM Action Plan === 1. Yes, the spfile cannot be edited. Instead, edit the C:\oraclexe\app\oracle\product\10.2.0\server\database\initXE.ora file. Add: _allow_resetlogs_corruption = true _minimum_giga_scn=6884 _allow_error_simulation=true 2. In sqlplus, issue: startup mount pfile=C:\oraclexe\app\oracle\product\10.2.0\server\database\initXE.ora 3. Issue: recover database using backup controlfile until cancel; --type cancel 4. open the database with: alter database open resetlogs; 5. Please submit screen shots, new alert.log and any trace file containing an ora-600 if the database does not open. 4/26/10: === ODM Action Plan === We have to corrupt the undo segments as well. 1. Please edit the initXE.ora, add: _corrupted_rollback_segments=(_SYSSMU1$, _SYSSMU2$, _SYSSMU3$, _SYSSMU4$, _SYSSMU5$, _SYSSMU6$, _SYSSMU7$, _SYSSMU8$, _SYSSMU9$, _SYSSMU10$, _SYSSMU11$, _SYSSMU12$, _SYSSMU13$, _SYSSMU14$, _SYSSMU15$, _SYSSMU16$, _SYSSMU17$, _SYSSMU18$, _SYSSMU19$, _SYSSMU20$) undo_management=manual 2. startup mount the database SQL>startup mount; 3. Execute: recover database; -----Media recovery was successful at this point. Alter database open; recover database using backup controlfile until cancel; -- cancel alter database open resetlogs; Please post full screen output, alert.log, and trace file containing any ora-600 error you may encounter. Reem http://www.dbaoracle.com/bk_recover_database_until_cancel_tips.htm Recover Database until cancel tips May 8, 2008 Problem: Can someone explain why it is necessary to perform "recover database until cancel" before using "alter database open resetlogs" when you are restoring a cold backup without a backup of the redo log files ? I perform the following steps, which I thought would be very simple, however I get an error on opening the database. SHUTDOWN IMMEDIATE Restore all backup datafiles and controlfiles (OS copy) STARTUP MOUNT ALTER DATABASE OPEN RESETLOGS ORA-01139: RESETLOGS option only valid after an incomplete database recovery So I tried useing: RECOVER DATABASE UNTIL CANCEL ALTER DATABASE OPEN RESETLOGS And this works, the database is opened and the new redo logs are created. I got a trace of my controlfile and found the following.. CREATE CONTROLFILE REUSE DATABASE "TEST" NORESETLOGS NOARCHIVEMODE ..... I think it is no NORESETLOGS that is causing the problem as if I re-create the control file with RESETLOGS specified it works fine. Solution: The Oracle documentation notes: "In cancel-based recovery, recovery proceeds by prompting you with the suggested filenames of archived redo log files. Recovery stops when you specify CANCEL instead of a filename or when all redo has been applied to the datafiles. Cancel-based recovery is better than change-based or time-based recovery if you want to control which archived log terminates recovery. For example, you may know that you have lost all logs past sequence 1234, so you want to cancel recovery after log 1233 is applied. You should perform cancel-based media recovery in these stages: 1. Prepare for recovery by backing up the database and correct any media failures as described in "Preparing for Incomplete Recovery". 2. Restore backup datafiles as described in "Restoring Datafiles Before Performing Incomplete Recovery". If you have a current control file, then do not restore a backup control file. 3. Perform media recovery on the restored database backup as described in the following procedure. To perform cancel-based recovery: 1. Start SQL*Plus and connect to Oracle with administrator privileges. For example, enter: 2. % sqlplus '/ AS SYSDBA' 3. 2. Start a new instance and mount the database: 3. STARTUP MOUNT 4. 3. Begin cancel-based recovery by issuing the following command: 4. RECOVER DATABASE UNTIL CANCEL 5. If you are using a backup control file with this incomplete recovery, then specify the USING BACKUP CONTROLFILE option in the RECOVER command. RECOVER DATABASE UNTIL CANCEL USING BACKUP CONTROLFILE Note: If you fail to specify the UNTIL clause on the RECOVER command, then you will not be able to open the database until a complete recovery is done. 4. Oracle applies the necessary redo log files to reconstruct the restored datafiles. Oracle supplies the name it expects to find from LOG_ARCHIVE_DEST_1 and requests you to stop or proceed with applying the log file. Note that if the control file is a backup, then you must supply the names of the online logs if you want to apply the changes in these logs. Note: If you use an Oracle Real Application Clusters configuration, and you are performing incomplete recovery or using a backup control file, then Oracle can only compute the name of the first archived redo log file from the first thread. The first redo log file from the other threads must be supplied by the user. After the first log file in a given thread has been supplied, Oracle can suggest the names of the subsequent log files in this thread. 5. Continue applying redo log files until the last log has been applied to the restored datafiles, then cancel recovery by executing the following command: 6. CANCEL 7. Oracle returns a message indicating whether recovery is successful. Note that if you cancel recovery before all the datafiles have been recovered to a consistent SCN and then try to open the database, you will get an ORA-1113 error if more recovery is necessary for the file. You can query V$RECOVER_FILE to determine whether more recovery is needed, or if a backup of a datafile was not restored prior to starting incomplete recovery. 6. Open the database in RESETLOGS mode. You must always reset the online logs after incomplete recovery or recovery with a backup control file. For example, enter: ALTER DATABASE OPEN RESETLOGS;"