Oracle® Database Backup and Recovery Advanced User's Guide 10g Release 2 (10.2) Part Number B14191-01 |
|
|
View PDF |
You can make a whole database backup of all files in a database after the database has been shut down with the NORMAL
, IMMEDIATE
, or TRANSACTIONAL
options. A whole database backup taken while the database is open or after an instance failure or SHUTDOWN
ABORT
is inconsistent. In such cases, the files are inconsistent with respect to the checkpoint SCN.
You can make a whole database backup if a database is operating in either ARCHIVELOG
or NOARCHIVELOG
mode. If you run the database in NOARCHIVELOG
mode, however, the backup must be consistent; that is, you must shut down the database cleanly before the backup.
The set of backup files that results from a consistent whole database backup is consistent because all files are checkpointed to the same SCN. You can restore the consistent database backup without further recovery. After restoring the backup files, you can perform additional recovery steps to recover the database to a more current time if the database is operated in ARCHIVELOG
mode. Also, you can take inconsistent whole database backups if your database is in ARCHIVELOG
mode.
Control files play a crucial role in database restore and recovery. For databases running in ARCHIVELOG
mode, Oracle recommends that you back up control files with the ALTER
DATABASE
BACKUP
CONTROLFILE
TO
'
filename'
statement.
See Also: "Making User-Managed Backups of the Control File" for more information about backing up control files |
This section describes how to back up the database with an operating system utility.
To make a consistent whole database backup:
If the database is open, use SQL*Plus to shut down the database with the NORMAL
, IMMEDIATE
, or TRANSACTIONAL
options.
Use an operating system utility to make backups of all datafiles as well as all control files specified by the CONTROL_FILES
parameter of the initialization parameter file. Also, back up the initialization parameter file and other Oracle product initialization files. To find these files, do a search for *.ora
starting in your Oracle home directory and recursively search all of its subdirectories.
For example, you can back up the datafiles, control files and archived logs to /disk2/backup
as follows:
% cp $ORACLE_HOME/oradata/trgt/*.dbf /disk2/backup % cp $ORACLE_HOME/oradata/trgt/arch/* /disk2/backup/arch
Restart the database. For example, enter:
SQL> STARTUP
See Also: Oracle Database Administrator's Guide for more information on starting up and shutting down a database |