About Me

My photo
Bangalore, India
I am an Oracle Certified Professional working in SAP Labs. Everything written on my blog has been tested on my local environment, Please test before implementing or running in production. You can contact me at amit.rath0708@gmail.com.

Sunday, October 14, 2012

ORA-01207: File is more recent than control file - old control file

Few days ago I faced this issue in my database, due to some problem in my ASM disks, my database closed abruptly and I was getting the following error when I was trying to open my database using STARTUP command.

Errors:-
===========
ORA-01122: database file 6 failed verification check
ORA-01110: data file 6: '
+AMIT_R1/orcl/datafile/amit.271.795743985'
ORA-01207: file is more recent than control file - old control file.


Cause :-
===========
The information in this file is inconsistent with information from the control file.
The datafile header CHECKPOINT count is beyond the controlfile CHECKPOINT count.


Solution :-
=========== 
1. Mount the database.
 SQL> startup mount;
ORACLE instance started.

Total System Global Area 1025298432 bytes
Fixed Size                  1341000 bytes
Variable Size             322963896 bytes
Database Buffers          696254464 bytes
Redo Buffers                4739072 bytes
 

Database mounted. 

2. Recreate the control file of the database.
Please refer to 
http://amit7oracledba.blogspot.in/2012/10/how-to-recreate-control-file-in-oracle.html 
only to recreate your control file.


3. After creation of control file, database is in mount stage

SQL> select open_mode from v$database;

OPEN_MODE
--------------------
MOUNTED


4. Recover the database.
SQL> recover database;

If it does recovery from the redo logs then from above command only your database will be recovered , but if the error is "control file is more recent than the file" then it asks you for archive logs to recover then you have to use below command 

SQL> recover database using backup controlfile until cancel;

it will ask you for archive logs, give the path of all archive logs which it needs until it gives you message, MEDIA RECOVERY COMPLETED.

5. Open the database.
SQL> alter database open;

Database altered.

SQL> select open_mode from v$database;

OPEN_MODE
--------------------
READ WRITE


 Database recovery complete.

I hope this article helped you.

Regards,
Amit Rath 


5 comments:

  1. Hi Amit,

    Your valuable post help me to recreate control file, recover media and stated database
    while recovering media users should define right redo log file path as identifiable in control file script. for me redolog2 worked.

    Cheers
    Mujeeb

    ReplyDelete
  2. Excellent Port, It helped me to solve the issue. thanks.

    ReplyDelete