Recover A Lost Datafile With No Backup (Doc ID 1060605.6)
Recover A Lost Datafile With No Backup (Doc ID 1060605.6)
***Checked for relevance on 16-Apr-2014***
Problem Description:
====================
You have inadvertantly lost a datafile at the OS level and there are no current
backups.
You are in archivelog mode.
You have ALL Archivelogs available since the datafile was created initially (creation date).
Problem Explanation:
====================
Since there are no backups, the database cannot be opened without this file
unless dropped and the tablespace dropped. If this is an important file and
tablespace, this is not a valid option.
Problem References:
===================
Oracle 7 Backup and Recovery Workshop Student Guide, Failure Scenario 14
Search Words:
=============
ORA-1110, lost datafile, file not found.
Solution Description:
=====================
This files have to be recreated and recovered. Do the following:
1) Go to svrmgrl and connect internal.
2) SVRMGR>shutdown immediate. (If this hangs, issue shutdown abort)
3) SVRMGR>startup mount
4) SVRMGR> select * from v$recover_file;
SAMPLE:
FILE# ONLINE ERROR CHANGE# TIME
---------- ------- ------------------ ---------- --------------------
11 OFFLINE FILE NOT FOUND 0 01/01/88 00:00:00
(Noting the file number that was reported in the error)
5) SVRMGR> select * from v$datafile where FILE#=11;
SAMPLE:
FILE# STATUS ENABLED CHECKPOINT BYTES CREATE_BYT NAME
---------- ------- ---------- ---------- ---------- ---------- --------
11 RECOVER READ WRITE 4.9392E+12 0 10240 /tmp/sample.dbf
(Note the status is RECOVER and the CREATE_BYTE size)
(Note the NAME)
6) Recreate the datafile.
SVRMGR> alter database create datafile '/tmp/sample.dbf'
as '/tmp/sample.dbf' size 10240 reuse.
(Note that the file "created" and the file created "as" are
the same file. The "size" needs to be the same size as it
was when it was created.)
7) Check to see that it was successful.
SVRMGR> select * from v$datafile where FILE#=11;
8) Bring the file online.
SVRMGR> alter database datafile '/tmp/sample.dbf' online;
9) Recover the datafile.
SVRMGR> Recover database;
Note: During recovery, all archived redo logs written to since the original
datafile was created must be applied to the new, empty version of the
lost datafile."
10) Enjoy!!
SVRMGR> alter database open;
Solution Explanation:
=====================
Recreating the file and recovering it rewrites it to the OS and brings it up to
date.
Solution References:
====================
Oracle 7 Backup and Recovery Workshop Student Guide, Failure Scenario 14
ReferencesNOTE:29430.1 - How to Recover a Database Having Added a Datafile Since Last Backup |
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/17252115/viewspace-1160651/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- recover database using backup controlfile理解Database
- Oracle 最新PSU (Doc ID 2118136.2)Oracle
- expdp/impdp變慢 (Doc ID 2469587.1)
- Reading and Understanding Systemstate Dumps (Doc ID 423153.1)
- RMAN -- Frequently Asked Question (FAQ) (Doc ID 469777.1)
- Oracle 下載最新psu (Doc ID 2118136.2)Oracle
- PRCT-1011 : Failed to run "oifcfg" (Doc ID 1380183.1)AI
- How to Collect Diagnostics for Database Hanging Issues (Doc ID 452358.1)Database
- RMAN restore fails with ORA-01180: can not create datafile 1 (文件 ID 1265151.1)RESTAI
- [轉帖]Release Schedule of Current Database Releases (Doc ID 742060.1)Database
- 【CURSOR】How to Monitor and tune Open and Cached Cursors (Doc ID 1430255.1)
- Physical Standby Switchover_status Showing Not Allowed. (Doc ID 1392763.1)
- oracle11g: Scheduler Maintenance Tasks or Autotasks (Doc ID 756734.1)OracleAINaN
- 【DBA】Relinking Oracle Home 常見問題 (Doc ID 2048232.1)Oracle
- How To Replicate Data from Oracle to Postgres Using GoldenGate (Doc ID 1544137.1OracleGo
- 11g-Reduce Transportable Tablespace Downtime using XTTS (Doc ID 1389592.1)TTS
- Can GoldenGate Replicate An Oracle Table That Contains Only CLOB Column(s)? (Doc ID 971833.1)GoOracleAI
- 12c DG新特性 - Active Data Guard Far Sync (Doc ID 2179719.1)
- 【GRID】Grid Infrastructure 啟動的五大問題 (Doc ID 1526147.1)ASTStruct
- 【DATAGUARD】Data Guard 12C 新特性:Far Sync Standby (Doc ID 2179719.1)
- SqlServer 備份集和備份片以及mirror的backup_set_idSQLServer
- ORA-04063: package body SYS.DBMS_REGISTRY_SYS has errors (Doc ID 2165402.1)PackageError
- cron with recover
- 【ASM】ORA-27504 ORA-27300 ORA-27303 while starting ASM (Doc ID 2281441.1)ASMWhile
- 【RAC】Oracle 12c以及以上版本的diagsnap是什麼? (Doc ID 2469643.1)Oracle
- RMAN-06214: Datafile Copy
- It is the Auction House in Lost Ark
- SQLBackupAndFTP12.0 failed to backup database with full backup typeSQLFTPAIDatabase
- [20201103]set newname for datafile.txt
- Will attempt to recover by breaking constraintAI
- sqlserver docSQLServer
- md_backup
- Lost RAM可能的原因
- 【譯】defer-panic-and-recover
- ORA-19909: datafile 1 belongs to an orphan incarnation
- 新書問答:Lost and Founder新書
- MySQL:Lost connection to MySQL server at 'readingMySqlServer
- Using V$BACKUP_ASYNC_IO / V$BACKUP_SYNC_IO to Monitor RMAN PerformanceORM
- 部署Onlyoffice Doc ServerServer