Switching to Copy in Application Backup Repository
If you use Oracle RMAN Incremental Merge, you can switch to a copy of your Oracle database using the image copy and incremental backups stored on the NFS share of the application backup repository. For more information, see Oracle RMAN Incremental Merge.
Switching the database to the image copy stored on the NFS share allows you to minimize the downtime in case of disaster. Since the image copy contains ready-to-use database files, Oracle RMAN does not need to copy any data. After the switch, the database will run directly from the NFS share until you restore the database files to the production storage.
To switch the database to the image copy, run the following command:
RUN { |
Note |
Make sure you disable the snapshot schedule in the repository settings after you switch the database to image copy. You cannot create snapshots of the NFS share while the database is running. |
After you switch the database to image copy, you can proceed to the restore. For details, see Examples of Restore Scenarios.
Depending on the recovery scenario, you can use the image copy and application backup repository snapshots in the following ways:
- Move the database from the NFS share to the production storage after you switch the database to the image copy. In this case, Oracle RMAN moves the database files to their original location while the database is running. For more information, see Moving Database to Production Storage.
- Restore the database from the NFS share to the production storage, without switching the database to the image copy. In this case, Oracle RMAN will copy the database files from the NFS share to their original location, and the restore operation will take about as much time as a full database restore. For more information, see Restoring Database to Production Storage.
- Restore the database to another server. You can export the data of an application backup repository snapshot to a temporary NFS share and restore the database from this share without changing the production database. This may be useful for testing purposes. For more information, see Restoring Database to Another Server.
Note |
Below, you can find examples from a tested configuration. They do not cover all RMAN scenarios. The database administrator must proofread the commands, adapt them to the Oracle environment, and perform all required RMAN preparations, recovery steps and post-restore actions manually. |
Moving Database to Production Storage
To move the database files to the production storage, run the following statement for each database file:
ALTER DATABASE MOVE DATAFILE '<file_path>' TO '<new_file_path>'; |
where:
- <file_path> is the current path of the database file on the NFS share.
- <new_file_path> is the path on the production storage to which Oracle will move the database file.
For example:
ALTER DATABASE MOVE DATAFILE '/nfsabr/oracopy/ORCL_USERS_4.dbf' TO '/u01/oradata/ORCL/users01.dbf'; |
Restoring Database to Production Storage
To restore the database from the image copy, run the following command:
RUN { |
where <tag_name> is the tag of the image copy from which Oracle RMAN restores the database. Specify the tag that you used when you created the image copy. For more information, see Oracle RMAN Incremental Merge.
For example:
RUN { |
Exporting and Restoring Database on Another Server
To restore the database to another server, do the following:
- In the Veeam Backup & Replication console, export the data of the required snapshot to a temporary NFS share. For more information, see Performing Instant Application Backup Repository Recovery.
- Mount the temporary NFS share on the target server.
- On the target server, restore the database from the image copy stored on the share using any Oracle RMAN restore method suitable for your environment. For more information, see this Oracle article.