Restoring the database solely depends on a backup set of online full backup cannot save your database. That is, if you run RESTORE DATABASE, RMAN still needs archive logs to recover some of data files that were backed up in the early stage.
If you insist to backup only one self-contained and consistent full backup set for some reasons (e.g. to make it portable), I recommend the following backup strategies.
- Cold full backup If your database is not required to open 24-7, you may try cold full backup. First of all, you have to start your database to mount state or open read only after a clean shutdown and then take a full backup. Of course, when the end of backup, alter database to open (if previously mounted).
Please note that, a clean shutdown should leave the database no undo data. All transactions are all either rolled back or committed before close. The following events cannot be called clean shutdowns:
- SHUTDOWN ABORT
- Killing SMON accidentally or purposely.
- Server blackouts
If your database is in NOARCHIVELOG mode, then you have no choice, you must use this kind of strategy to make a consistent and self-contained backup set. Nevertheless, the cold backup is a clear to understand for customers and easy to implement in backup strategies for DBA.
RMAN> backup database plus archivelog;
By archiving the logs immediately after the backup, you ensure that you have a full set of archived logs through the time of the backup. In this way, you guarantee that you can perform media recovery after restoring this backup (Ref: Backing Up a Whole Database with RMAN).
If you greatly depends on incremental level 0, 1 strategies to restore and recover the database, you can do this:
RMAN> backup incremental level 0 database plus archivelog;
RMAN> backup incremental level 0 database plus archivelog delete input;
But please do NOT use this:
RMAN> backup incremental level 0 database plus archivelog not backed up;
This statement may ruin our goal of making the backup self-contained in some situations.I will talk more consistent backup strategies, please refer to my another post below:
Are All Oracle Full Backups Consistent?