The steps in the simulation are as follows:
- Before you start the recovery process, you decide to perform a whole closed database backup. At the prompt, type
SHUTDOWN IMMEDIATE
to shutdown the database. When you finish, press Enter.
- To perform a backup using the operating system, type
HOST
at the prompt. After you finish, press Enter.
- Suppose you have a batch file, do_backup.bat, that will perform the backup. This file is stored at the present directory. To have the file perform the backup, type
DO_BACKUP
at the prompt. After you finish, press Enter.
- Now you are going to restore all the datafiles. Remember all the database files must be older than the lost archived log #448, but the control file must be current. Suppose you have another batch file to restore all the datafiles for you.
This file is called do_dbf_restore.bat. To perform this operation, type
DO_DBF_RESTORE
at the prompt. After you finish, press Enter.
- Now you want to make sure the restoring of the datafiles has been done correctly. Type
DIR
at the prompt. After you finish, press Enter.
- After reading the timestamp for each datafile (see the highlighted text) you are sure that you have restored the correct datafiles since these are older than the lost archived log #448.
To go back to Server Manager, type
SVMGR30
at the prompt. After you finish, press Enter.
- Now you have to perform the recovery of the database in the mount mode. To mount the database, type
STARTUP MOUNT
at the prompt. After you finish, press Enter.
-
The database is mounted and you are ready to perform a cancel-based recovery. Type
RECOVER DATABASE UNTIL CANCEL
at the prompt.
After you finish, press Enter.
- When Oracle prompts you with the suggestion to apply a certain archived log, you must press enter in order to continue. This step is repeated for each archived log that needs to be applied. This Simulation will skip all these repetitions and move right to the archived
log you want to apply. Press Enter when you are ready to move on.
- Now you have reached archived log #448. Since this log is lost, the recovery cannot pass this log. To move on to the next step in the recovery process, type
CANCEL
at the prompt. After you finish, press Enter.
- To synchronize the recovered datafiles with the control file and redo log files and open the database, type
ALTER DATABASE OPEN RESET LOGS;
at the prompt. After you finish, press Enter.
- You have successfully recovered the database using the cancel-based recovery. Do not forget to make another whole database backup to avoid this type of recovery. This is the end of the Simulation.