For this case study, we will be backing up an Oracle database that is in no-archivelog mode. Keep in mind that the only backups that are allowed are:
- Whole database backups when the database is cleanly closed and the instance is mounted.
- Tablespace backups of tablespaces that are offline clean or read only.
Script: backup_cold.rcv run {
# -----------------------------------------------------------
# The following RMAN commands are run each day.
# The steps are:
# - Re-start the database to perform crash recovery, in
# case the database is not currently open, and was not
# shut down consistently. The database is started in DBA
# mode so that normal users cannot connect.
# - Shut down with the IMMEDIATE option to close the
# database consistently.
# - Startup and mount the database.
# - Backup database.
# - Open database for normal operation.
# -----------------------------------------------------------
startup force dba;
shutdown immediate;
startup mount;
backup database;
alter database open;
}
exit
Taking Backups of Read-Only Tablespaces
The database does not have to be closed to back up a readonly tablespace in no-archivelog mode.The following command can be used to backup a readonly tablespace:
run {In our example, we can use the following command to backup the read-only tablespace "READ_ONLY_TBS".
backup tablespace read_only_tablespace_name;
}run {
backup tablespace read_only_tbs;
}
No comments:
Post a Comment