RelationalDBDesign RelationalDBDesign


Recovery with Archiving  «Prev 

Steps to Recover Open Database, (initially open) in Oracle

  1. Make sure the damaged datafile is offline.
  2. Restore the damaged file using the operating system copy command.
  3. Use the RECOVER DATAFILE or RECOVER TABLESPACE command to apply the archived and the redo logs to the restored datafile.
  4. When recovery is finished, all datafiles are synchronized. Bring the datafile online via the ALTER DATABASE DATAFILE '<FILENAME>'; statement.

How It Works

As you can see in the two examples, you can use the host command with or without an operating system command as a parameter. If you run the host command as part of a series of RMAN commands, RMAN executes the host command and continues with the rest of the commands. When you execute the host command by itself, RMAN displays the operating system command prompt and resumes after you exit the command-line subshell.

Scripting RMAN

Problem: You want to automate an RMAN process by executing a set of commands that you have placed into a script file. You do not want to type each command one at a time. You want to start the entire sequence of commands and walk away while they execute. You may even want to execute your script periodically via a job scheduler, such as cron.