If you run data aging from the CommCell Console, it checks for qualifying jobs after checking the basic retention rule, log rule and any extended rule. If any job qualifies for data aging, it generates an RMAN script to make the aged backup pieces unavailable.
Example
The script below is a sample RMAN script.
allocate channel for maintenance type 'sbt_tape' PARMS="SBT_LIBRARY=/opt/commvault/Base/libobk.so"
TRACE 0;
change backuppiece 'obpb5ojv_1_1','c-1013501923-20140618-00' unavailable;
change backuppiece 'odpb5ot3_1_1','c-1013501923-20140618-01' unavailable;
release channel;
exit;
Deleting Backup Pieces from the Oracle Recovery Catalog
When a Data Aging job runs, it issues the change backuppiece... UNAVAILABLE command to RMAN to disable the backup pieces in the Oracle Recovery Catalog database that were pruned from the Media Manager CommServe tables. To delete backup pieces from the Recovery Catalog instead of marking them unavailable, create and set the OracleDeleteAgedBackupPiece additional setting to Y, which generates the following RMAN script.
allocate channel for maintenance type 'sbt_tape' PARMS="SBT_LIBRARY=/opt/commvault/Base/libobk.so"
TRACE 0;
change backuppiece 'obpb5ojv_1_1','c-1013501923-20140618-00' delete;
change backuppiece 'odpb5ot3_1_1','c-1013501923-20140618-01' delete;
release channel;
exit;
Preventing the Software from Setting the Backup Piece to Unavailable
By default during the data aging operation, the Commvault software sets the backup piece to unavailable. You can configure the software to prevent this. For more information, see Preventing the Software from Setting the RMAN Backup Piece to Unavailable.
Synchronizing the CommServe Database and Oracle Recovery Catalog
Sometimes data aging removes the backup pieces from the CommServe database but not from the Recovery Catalog. In such cases, you need to manually run the Oracle CROSSCHECK command on the client side to synchronize both the CommServe database and the Oracle Recovery Catalog.
Run this in the following cases.
-
If the Oracle Services are down while data aging runs.
-
If any of the backup pieces are manually deleted from the Oracle Recovery Catalog.
-
If the Commvault software is uninstalled on the client.
Preventing RMAN Command Line Scripts from Deleting RMAN Backups
The CommCell data aging feature ages and deletes backups according to user-defined rules.
Users can also delete the backups using RMAN Command Line scripts before the data aging rules take effect.
You can prevent RMAN Command Line scripts from deleting the Commvault backups.
- Set the Disable RMAN External Pruning Data Aging Media Management parameter to one of the following values. For information on how to set the parameter, see Media Management Configuration Parameters.
Note: For new installations, this value is set to 1. For upgrades, the value is set to 0.
Option |
Value |
---|---|
Prevent the RMAN scripts from deleting the backups |
1 |
Allow the RMAN scripts to delete the backups. |
0 |