Once you have prepared your database and identified the necessary files, use the following steps to perform a closed database backup:
- First, shut down the Oracle instance with the
SHUTDOWN NORMAL or the
SHUTDOWN IMMEDIATE command.
It is important to note that the database must be shut down properly or you will have backed up a crashed database, which is problematic in certain recovery scenarios. An example of an improper shutdown would be to use the
shutdown abort command.
If this happens, you have to restart the database and shut it down properly.
The default shutdown parameter is "normal."
The database will not shut down with the command
, until the last user logs off. Use SHUTDOWN
IMMEDIATE if there is any chance the database is still being accessed to avoid waiting for the last user to log off.
- Second, back up all datafiles, redo log files, control files, parameter files, and the password files with an operating system backup utility.
Although parameter and password files are not physically part of the database and do not contain any user data, they are important because the files contain essential information about database startup and configuration.
In order to ensure that every file is correctly backed up, a reliable and automated procedure for this operation can be established by creating and executing a simple script.
- Next, restart the Oracle instance.
The image below illustrates the closed backup process.