Database Reference
In-Depth Information
You can now bring the data file back online:
SQL> alter database datafile '/u01/dbfile/O12C/users01.dbf' online;
If successful, you should see this:
Database altered.
Restoring Control Files
When you're dealing with user-managed backups, you usually restore the control file in one of these situations:
A control file is damaged, and the file is multiplexed.
All control files are damaged.
These two situations are covered in the following sections.
Restoring a Damaged Control File When Multiplexed
If you configure your database with more than one control file, you can shut down the database and use an OS
command to copy an existing control file to the location of the missing control file. For example, from the initialization
file, you know that two control files are used for this database:
SQL> show parameter control_files
NAME TYPE VALUE
---------------------------- ----------- ------------------------------
control_files string /u01/dbfile/O12C/control01.ctl
,/u02/dbfile/O12C/control02.ctl
Suppose the control02.ctl file has become damaged. Oracle throws this error when querying the data
dictionary:
ORA-00210: cannot open the specified control file...
When a good control file is available, you can shut down the database, move the old/bad control file (this
preserves it, in the event that it is later needed for root cause analysis), and copy the existing good control file to the
name and location of the bad control file:
SQL> shutdown abort;
$ mv /u02/dbfile/O12C/control02.ctl /u02/dbfile/O12C/control02.ctl.old
$ cp /u01/dbfile/O12C/control01.ctl /u02/dbfile/O12C/control02.ctl
Now, restart the database:
SQL> startup;
In this manner, you can restore a control file from an existing control file.
 
Search WWH ::




Custom Search