Error ORA-01152: file 1 was not restored from a sufficiently old backup
Demo:
SQL> startup ORACLE instance started.
Total System Global Area 171966464 bytes
Fixed Size 787988 bytes
Variable Size 145488364 bytes
Database Buffers 25165824 bytes
Redo Buffers 524288 bytes
ORA-00205: error in identifying controlfile, check alert log for more info.
I don’t have automatized control file backup neither i have control file copy.What i will do
to recover control file i will restore controlfile from backup.Before doing it that i will bring
the database in mount state.
SQL> shutdown immediate ORA-01507: database not mounted
ORACLE instance shut down.
SQL> startup mount ORACLE
instance started.
Total System Global Area 171966464 bytes
Fixed Size 787988 bytes
Variable Size 145488364
bytes
Database Buffers 25165824 bytes
Redo Buffers 524288 bytes
ORA-00205: error in identifying controlfile, check alert log
for more info
I have two backup piece in my backupset folder you cant check control file backup
existence with list backup controlfile at RMAN prompt cause it needs database in
mount state.You will have to test both backup set pieces.
RMAN> restore controlfile from Autobackup;
Starting restore at 08-DEC-07 using channel ORA_DISK_1 channel ORA_DISK_1: restoring controlfile channel ORA_DISK_1:
restore complete output filename=C:\ORACLE10G\ORACLE\ORADATA\ORCL1\ORCL1\CONTROL01.CTL output filename=C:\ORACLE10G\ORACLE\ORADATA\ORCL1\ORCL1\CONTROL02.CTL output filename=C:\ORACLE10G\ORACLE\ORADATA\ORCL1\ORCL1\CONTROL03.CTL
Finished restore at 08-DEC-07
SQL> startup ORACLE instance started.
Total System Global Area 171966464 bytes
Fixed Size 787988 bytes
Variable Size 145488364 bytes
Database Buffers 25165824 bytes
Redo Buffers 524288 bytes Database mounted.
ORA-01589: must use RESETLOGS or NORESETLOGS option
for database open
SQL> alter database open resetlogs ;
Database altered.
You can see database now comes into open mode without raising error error
ORA-01152: file 1 was not restored from a sufficiently old backup,you can see that
database shutdown with immediate which synchronized the control file with database
file.
Cause: When you shutdown the database with using the normal,transactional or immediate options not abort a full checkpoint occurs.A full checkpoint ensures that all of the dirty blocks contained in the buffer cache are written to the data files,the database comes into synchronized state at this time i.e controlfile CKPT SCN=databasefile CKPT.
Solution: Simply issue RECOVER DATABASE prior to opening database.