Causes and Solutions on ORA-1113 Error Found in Backup & Recovery_183367.1
Common Causes and Solutions on ORA-1113 Error Found in Backup & Recovery (Doc ID 183367.1)
Applies to:
Information in this document applies to any platform.
Purpose
This note is intended to list the common reasons & solutions for the ORA-1113 error
Troubleshooting Steps
An ORA-1113 occurs when a datafile needs recovery.
Definition of ORA-01113:
Cause: An attempt was made to online or open a database with a file that
is in need of media recovery.
Action: First apply media recovery to the file.
The ORA-01113 error is usually followed with an ORA-01110 error which indicates
the name of the datafile that needs media recovery.
ORA-01110: data file 28: '/h04/usupport/app/oracle/oradata/index02.dbf'
This error message indicates that a datafile that is not up-to-date with
respect to the controlfile and other datafiles.
Oracle's architecture is tightly coupled in the sense that all database
files i.e., datafiles, redolog files, and controlfiles -- must be in sync
when the database is opened or at the end of a checkpoint.
This implies that the checkpoint SCN (System Commit Number) of all datafiles
must be the same. If that is not the case for a particular datafile, an
ORA-1113 error will be generated.
For example, when you put a tablespace in hot backup mode, the checkpoint
SCN of all its datafiles is frozen at the current value until you issue the
corresponding end backup. If the database crashes during a hot backup and
you try to restart it without doing recovery, you will likely get ORA-1113
for at least one of the datafiles in the tablespace that was being backed up,
since its SCN will probably be lower than that of the controlfile and the
datafiles in other tablespaces.
Likewise, offlining a datafile causes its checkpoint SCN to freeze.
If you simply attempt to online the file without recovering it first, its
SCN will likely be much older than that of the online datafiles, and thus an
ORA-1113 will result.
Before Starting these actions do the following:
Query the V$LOG and V$LOGFILE.
1. If the database is down, you need to mount it first.
SQL> STARTUP MOUNT;
2. Then connect internal Server Manager and issue the query:
SQL> connect / as sysdba
SQL> SELECT V1.GROUP#, MEMBER, SEQUENCE#, FIRST_CHANGE#
FROM V$LOG V1, V$LOGFILE V2
WHERE V1.GROUP# = V2.GROUP# ;
This will list all your online redolog files and their respective sequence and
first change numbers.
The steps to take next depend on the scenario in which the ORA-1113 was issued.
This is discussed in the following sections.
POSSIBLE CAUSES AND SOLUTIONS SUMMARY:
I. AT STARTUP AFTER CRASH WITH TABLESPACE(S) IN HOT BACKUP
II. AT STARTUP AFTER RESTORING A DATAFILE OR TABLESPACE FROM A BACKUP
III. TRYING TO ONLINE A DATAFILE OR TABLESPACE
IV. WHEN RECOVERING ' USING BACKUP CONTROLFILE' OPTION TO DO INCOMPLETE RECOVERY
I. AT STARTUP AFTER CRASH WITH TABLESPACE(S) IN HOT BACKUP
**********************************************************
1. Mount the database.
SQL> STARTUP MOUNT;
2. Find out which datafiles were in hot backup mode when the database crashed or
was shutdown abort or the machine was rebooted by running the query:
SQL> SELECT V1.FILE#, NAME
FROM V$BACKUP V1, V$DATAFILE V2
WHERE V1.STATUS = 'ACTIVE' AND V1.FILE# = V2.FILE# ;
3. For each of the files returned by the above query, issue the command:
SQL> ALTER DATABASE DATAFILE '' END BACKUP;
4. Open the database.
SQL> ALTER DATABASE OPEN;
II. AT STARTUP AFTER RESTORING A DATAFILE OR TABLESPACE FROM A BACKUP
*********************************************************************
A. WITH THE DATABASE IN ARCHIVELOG MODE
1. Mount the database.
SQL> STARTUP MOUNT;
2. Recover the datafile:
SQL> RECOVER DATAFILE '' ;
If recovering more than one datafile in a tablespace issue a
SQL> RECOVER TABLESPACE
If recovering more than one tablespace issue a
SQL> RECOVER DATABASE;
3. Confirm each of the archived logs that you are prompted for until you
receive the message "Media recovery complete".
If you are prompted for an archived log that does not exist, Oracle probably
needs one or more of the online logs to proceed with the recovery. Compare
the sequence number referenced in the ORA-280 message with the sequence
numbers of your online logs. Then enter the full path name of one of the
members of the redo group whose sequence number matches the one you are
being asked for.
4. Open the database.
SQL> ALTER DATABASE OPEN;
B. WITH THE DATABASE IN NOARCHIVELOG MODE
In this case, you will only succeed in recovering the datafile or tablespace
if the redo to be applied to it is within the range of your online logs.
Issue the query:
SQL> SELECT FILE#, CHANGE# FROM V$RECOVER_FILE;
Compare the change number you obtain with the FIRST_CHANGE# of your online logs.
If the CHANGE# is GREATER than the minimum FIRST_CHANGE# of your logs,
the datafile can be recovered. In this case, the procedure to be followed
is analogous to that of scenario II.A above, except that you must always
enter the appropriate online log when prompted, until recovery is finished.
If the CHANGE# is LESS than the minimum FIRST_CHANGE# of your logs, the file
cannot be recovered.Your options at this point include:
- If the datafile is in a temporary or index tablespace, you may drop
it with an ALTER DATABASE DATAFILE '' OFFLINE DROP
statement and then open the database. Once the database is up, you
must drop the tablespace to which the datafile belongs and recreate it.
- If the datafile is in the SYSTEM or in a rollback tablespace, restore
an up-to-date copy of the datafile (if available) or your most recent
full backup.In case you do not have either of this, then it might not
be possible to recover the database fully. For more details or to
assist you in your decision, please contact Oracle Customer Support.
For all other cases in this scenario, you must weigh the cost of going to a
backup versus the cost of recreating the tablespace involved, as described in
the two previous cases.For more details or to assist you in your decision,
please contact Oracle Customer Support.
III. TRYING TO ONLINE A DATAFILE OR TABLESPACE
**********************************************
1. Recover the datafile:
SQL> RECOVER DATAFILE '' ;
If recovering a tablespace, do
SQL> RECOVER TABLESPACE
If recovering a database, do
SQL> RECOVER DATABASE;
-- Note: With recover database, offline datafiles will not be recovered.
2. Confirm each of the archived logs that you are prompted for until you
receive the message "Media recovery complete".
If you are prompted for an archived log that does not exist, Oracle probably
needs one or more of the online logs to proceed with the recovery. Compare
the sequence number referenced in the ORA-280 message with the sequence
numbers of your online logs. Then enter the full path name of one of the
members of the redo group whose sequence number matches the one you are
being asked for.
3. Open the database.
SQL> ALTER DATABASE OPEN;
IV. WHEN RECOVERING 'USING BACKUP CONTROLFILE' OPTION TO DO INCOMPLETE RECOVERY
*******************************************************************************
If the database is recovered with the
"RECOVER DATABASE USING BACKUP CONTROLFILE;" option without specifying the
"UNTIL CANCEL" option, then upon "ALTER DATABASE OPEN RESETLOGS;" you will
encounter the ORA-1113 error.
Steps to workaround this issue:
1. Recover database again using:
SQL> RECOVER DATABASE USING BACKUP CONTROLFILE UNTIL CANCEL;
2. Cancel recovery by issuing the "CANCEL" command.
3. Open the database using:
SQL> ALTER DATABASE OPEN RESETLOGS;
#
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/17252115/viewspace-1069120/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Common Causes and Solutions on ORA-376 Error Found in Backup & RecoveryError
- Error 15: File not found for RedhatErrorRedhat
- Error ./bin/my_print_defaults: not foundError
- ERROR in Entry module not found Error Can't resolve 'babel' in ' UseErrorBabel
- ERROR: No abbreviations files found in ...nonbreaking_prefixesError
- backup: 0511-432 A write error occurredError
- NBU report error 6 when RMAN backupError
- 關於java.lang.Error: Probable fatal error:No fonts found問題JavaError
- RMAN-06023 no backup or copy of datafile 1 found to restoreREST
- [PM2][ERROR] Process XXX not foundError
- an error has occurred. - no valid devices were found...Errordev
- GPG key retrieval failed: [Errno 14] HTTP Error 404: Not FoundAIHTTPError
- Error:(4, 0) Plugin with id 'com.jakewharton.butterknife' not found.ErrorPlugin
- MysqL錯誤之_ERROR! MySQL server PID file could not be found!MySqlErrorServer
- MySQL 5.6複製報錯Error_code: 1032; handler error HA_ERR_KEY_NOT_FOUND;MySqlError
- 應對 "RMAN-06023: no backup or copy of datafile 1 found to restore"錯誤REST
- ubuntu進行make時報錯error: Neither flex nor lex was found.UbuntuErrorFlex
- 釋出android apk,Error running app: No target device found.AndroidAPKErrorAPPdev
- 【MySQL】5.6.x InnoDB Error Table mysql.innodb_table_stats not foundMySqlError
- 急!!Error Parsing EJB file: Finder found in DD with no matching method.Error
- ERROR: freetype2 not found using pkg-configError
- ALTER TABLE causes auto_increment resulting key 'PRIMARY'REM
- Solutions for Session Consistency Problem in Web ClusterSessionWeb
- VMware虛擬機器重啟網路報錯" Error: No suitable device found"虛擬機ErrorUIdev
- configure: error: no acceptable C compiler found in $PATH 問題解決ErrorCompile
- 記處理線上記錄垃圾日誌 The view 'Error' or its master was not foundViewErrorAST
- 安裝 ESXi 出現錯誤 ERROR 1962: No operating system foundError
- PHP 5.4 編譯 configure: error: libXpm.(a|so) not found.PHP編譯Error
- SAP FI-AA Line item causes scrap value of to be violated
- Advance Web Solutions---Office MessengerWebMessenger
- Error:A problem was found with the configuration of task ':app:packageDebug' 問題解決ErrorAPPPackage
- mysql-python安裝時Environment Error: mysql_config not foundMySqlPythonError
- Rman Backup Failed With Error Rman-00600 [8201] (Doc ID 412786.1)AIError
- 【oracle】ORA-01580 error creating control backup fileOracleError
- ORA-1113 signalled during: alter database open...Database
- 詭異的OGG-01004 Database error 1403 no data foundDatabaseError
- Error parsing XML: An invalid XML character (Unicode:0x1f) was foundErrorXMLUnicode
- sybase ase 無法備份(backup.log中,提示with error number 109 )Error