Search

Join this Blog for direct reference of any post into your inbox. To join just click on "Join this Site" under "Follower" then Login with your Email.*** DECLARATION: I Maintain this Blog for Helping Myself While at Work and Welcome any body Needing Help!!!.*** CAUTION: Using any of the script from this Blog may contain at Own Risk. These scripts May or May not have been Tested.***

Thursday, 30 October 2014

ORA-00392 While duplicating the database

We are recieving ORA-00392 error while trying to open a database after restoring and recovering a database in case of duplicating the database. When i trying to open the reset logs, i am getting the following error:
SQL> ALTER DATABASE OPEN resetlogs 
ORA-00392: log 2 OF thread 1 IS being cleared, operation NOT allowed

SQL>ALTER DATABASE clear logfile GROUP 2;
SQL>ALTER DATABASE OPEN resetlogs;

Since the path on source and destination is different, it is trying to create a file under old destination which is not present on the target server. Solution to this is you should clear the busy onlinelog then later you need to rename the files with your current location. But when i tried clearing the log then gettting now different error:

SQL>ALTER DATABASE clear logfile GROUP 2;
ALTER DATABASE clear logfile GROUP 2
ORA-00344: unable TO re-create online log 'D:\ORACLE\ORADATA\LOG02B.DBF'
ORA-27040: file CREATE error, unable TO CREATE file
OSD-04002: unable TO OPEN file
O/S-Error: (OS 3) The system cannot find the path specified.

SQL>ALTER DATABASE RENAME file 'P:\ORACLE\ORADATA\LOG02A.DBF' TO 'D:\app\o
racle\fast_recovery_area\ONLINELOG\LOG02A.DBF';

SQL>ALTER DATABASE RENAME file 'P:\ORACLE\ORADATA\LOG01A.DBF' TO 'D:\app\o
acle\fast_recovery_area\ONLINELOG\LOG01A.DBF';

Now try opening the database with resetlogs, it will succeed
SQL>ALTER DATABASE OPEN resetlogs;

7 comments: