Database Reference
In-Depth Information
This is because the active online redo log will not have been archived and you need to indicate
to Oracle that this is okay. This command will rebuild the online redo log and allow Oracle to
proceed with normal operations. You should always back up the database after this operation.
Dealing with the Loss of the Current Online Redo Log Group
Losing the current online redo log group is perhaps the worst disaster your Oracle Database
could encounter. This is because there is a significant risk of loss of data in such cases. When
you lose the current online redo log group, you can expect that the database will crash.
If the database has not yet shut down, you should immediately attempt to checkpoint the
database using the ALTER SYSTEM CHECKPOINT command and then shut down the database
afterward as soon as it is practical. The ALTER SYSTEM CHECKPOINT command forces the
database to write any dirty blocks from the database buffer cache to the database data files
in an urgent manner.
It may be that you can open the database without any recovery being required. This is
the best-case situation. To try to restart the database do the following:
1. Issue the STARTUP MOUNT command.
2. Issue the ALTER DATABASE CLEAR UNARCHIVED LOGFILE command for the redo log
group that was lost.
Examples of this command can be seen in earlier sections of this chapter.
3. Issue the ALTER DATABASE OPEN command.
If the database opens successfully, you are in luck. If the database fails to open, you are
in a bad way. You will need to perform incomplete recovery of the database as discussed in
the section “Performing an Incomplete Recovery.” You can see an example of recovering the
database as a result of the loss of the current online redo log group in Exercise 2.1.
Recovering from the Loss of a Control File
Recovery from loss of a control file depends on the nature of the loss. There are two different
situations you might encounter. You might lose one or more but not all control files. You might
also lose all control files. Let's look at what to do in these cases.
Dealing with the Loss of One or More Control Files but Not All
If you have at least one control file left, recovery is quite simple. Follow these steps:
1. Shut down the database normally.
2. Copy one of the remaining control files to the location of the lost control files and give
it the same name as the lost control file.
3. Restart the database.
Search WWH ::




Custom Search