Professional Documents
Culture Documents
Note:1013221.6 20-APR-2004
Problem Description:
====================
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
The steps outlined are only to be used with the assistance of Oracle Worldwide
Support. Included (in step 6) is a parameter _corrupted_rollback_segments
that will require that you rebuild your database. Please explore all other
options before using this parameter.
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+
Solution Description
====================
The main issue in solving this problem is trying to make sure that the
active transactions in the rollback segments do not get lost.
Solution Explanation
====================
If you are ABSOLUTELY POSITIVE that the database was cleanly shutdown,
i.e., it was closed with either shutdown NORMAL or IMMEDIATE, then
the simplest solution is to offline drop the missing datafile, open the
database in restricted mode, and then drop and recreate the rollback
tablespace to which the file belonged. DO NOT follow this procedure
if the database was shut down ABORT or if it crashed.
If that is not the case, i.e., if the last time YOU shut the database
down it was in abort mode, or the database crashed itself, it is
NOT safe to proceed. You should follow the instructions for
case I.B below.
2. Remove all the rollback segments in the tablespace to which the lost
datafile belongs from the ROLLBACK_SEGMENTS parameter in the init.ora
file for this instance. If you are not sure about which rollbacks are
in that tablespace, simply comment out the whole ROLLBACK_SEGMENTS entry.
6. Since opening the database failed, shut the database down and edit the
init.ora file for this instance. Comment out the ROLLBACK_SEGMENTS
parameter and add the following line:
i.e., the above list should contain all the rollbacks originally listed in
the ROLLBACK_SEGMENTS parameter.
This is the situation where the database was last shut down abort or crashed.
In this case, it is almost certain that the rollback segments that had
extents in the lost datafile still contain active transactions. Therefore,
the file cannot be offlined or dropped. You must restore the lost datafile
from a backup and apply media recovery to it. If the database is in
NOARCHIVELOG mode, you will only succeed in recovering the datafile if the
redo to be applied is within the range of your online logs. If a
backup of the datafile is not available, please contact Oracle Customer
Support.
If the status of the file you just restored is "OFFLINE," you must
online it before proceeding:
This will list all your online redolog files and their respective
sequence and first change numbers.
5. If the database is in NOARCHIVELOG mode, issue the query:
7. Confirm each of the logs that you are prompted for until you
receive the message "Media recovery complete". If you are prompted for a
non-existing archived log, Oracle probably needs one or more of the
online logs to proceed with the recovery. Compare the sequence number
referenced in the ORA-280 message with the sequence numbers of your online
logs. Then enter the full path name of one of the members of the redo group
whose sequence number matches the one you are being asked for. Keep entering
online logs as requested until you receive the message "Media recovery
complete".
If you have detected the loss of the rollback datafile and the database
is still up and running, DO NOT SHUT IT DOWN. In most cases, it is
simpler to solve this problem with the database up than with it down.
A) The first one involves offlining the lost datafile, restoring it from
backup, and then applying media recovery to it to make it consistent
with the rest of the database. This method can only be used if
the database is in ARCHIVELOG mode.
B) The other approach involves offlining all the rollback segments in the
tablespace to which the lost datafile belongs, dropping the tablespace,
and then recreating it. You may have to kill sessions that have
transactions in the rollbacks involved to force the rollbacks to go
offline.
This will list all your online redolog files and their respective
sequence numbers.
5. Confirm each of the logs that you are prompted for until you
receive the message "Media recovery complete". If you are prompted for a
non-existing archived log, Oracle probably needs one or more of the
online logs to proceed with the recovery. Compare the sequence number
referenced in the ORA-280 message with the sequence numbers of your online
logs. Then enter the full path name of one of the members of the redo group
whose sequence number matches the one you are being asked for. Keep entering
online logs as requested until you receive the message "Media recovery
complete".
This approach can be used regardless of the archival mode of the database.
The steps are:
If the above query returns one or more rows, they should show
status "PENDING OFFLINE". Next, check the ACTIVE_TX
column for each rollback. If it has a value of 0, it implies
there are no pending transactions left in the rollback, and it
should go offline shortly. Repeat the query in step 2 a few
more times until it shows the rollback being offline and then
drop it as described in step 3. Move on to step 6.
8. Recreate the rollback segments in the tablespace and bring them online.