2

I have experienced a problem with flashback and the solution is to recreate the control file (the error was ORA-01207).

So to do this I tried

 alter database backup controlfile to trace as '/tmp/trace.sql';

This creates a file that instructs one to either use set one or set two. i.e. with or without resetlogs.

How does one determine what set is the most applicable? Is there any tests that one needs to perform to find out?

1

From /tmp/trace.sql:

The first set opens the database with the NORESETLOGS option and should be used only if the current versions of all online logs are available. The second set opens the database with the RESETLOGS option and should be used if online logs are unavailable.

If you're only recreating the controlfile you should be able to perform a complete recovery. i.e. without resetlogs. If you are missing some online redo logs or if they are not complete, then it will be a partial recovery, and RESETLOGS will be required.

  • How does one determine is some online redo logs are missing? – Ed Heal Sep 1 '16 at 13:57
  • 2
    Compare the contents of v$logfile with your file system. Regardless, if the recovery without resetlogs doesn't work, it will tell you that resetlogs is required. – Andrew Brennan Sep 1 '16 at 14:21
  • How does one go about doing the comparison wrt Exadata – Ed Heal Sep 1 '16 at 14:23
  • 1
    Have you tried selecting * from v$logfile? It shouldn't be any different for Exadata... – Andrew Brennan Sep 1 '16 at 14:40
-2

In addition to @Andrew Brennan answer. The following steps are using RESETLOGS option, assuming online logs are unavailable.


Trace the Control File backup

ALTER DATABASE BACKUP CONTROLFILE TO TRACE as 'path\trace.sql'

Restart the database in NOMOUNT stage

SHUTDOWN IMMEDIATE
STARTUP NOMOUNT

Run the traced script

--Traced Script

Open the database with RESETLOGS

ALTER DATABASE OPEN RESETLOGS;

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.