Delete all archivelog files with each backup

Last post 03-28-2014, 11:46 AM by Ken_H. 6 replies.
Sort Posts: Previous Next
  • Delete all archivelog files with each backup
    Posted: 03-20-2014, 5:45 PM

    Hello everyone,

    I'm starting the migration of my Oracle database backups from NetBackup to Commvault and have a quuestion.  In NetBackup, I had configured the backup script to only delete archivelog files that are older than 21 days.  Since I don't need that many backups of the each log file, I had configure my backup script to only back up each file 3 times.  This was done via the following code:

          filesperset=1 format '%d_al%e_%T_%s'
          archivelog all not backed up 3 times;
       delete noprompt copy of archivelog all completed before 'SYSDATE-21';

    The only place I see this corresponding option in Commvault is when I run a manual backup and click on the Advanced tab and change the behaviour for that one backup.  As far as I can see the normal scheduled subclient backup can either not delete any archivelog files or delete them all.

    I have two questions: 

    1) Is the typical administrator configuring Oracle database backups to delete the archivelog files every time a backup is run? 

    2) Is there a way to configure the subclient to only backup log files not already backed up 3 times and only delete logs that are older than 21 days?

    Thanks in advance for your help.


  • Re: Delete all archivelog files with each backup
    Posted: 03-21-2014, 9:44 AM
    • efg is not online. Last active: 07-10-2019, 6:47 PM efg
    • Top 10 Contributor
    • Joined on 02-02-2010
    • CommVault Tinton Falls NJ
    • Expert
    • Points 1,665

    Hi Ken,

    Not in the subclient.   These options are only available from the advanced job options.  One additional point I would like to add is that for the delete option that you are using (from advanced job options) I would also recommend adding the "backed up n times" (with a setting of 3) to the delete tab as well.   This would produce the following command in the CV RMAN backup:

     filesperset = 4
     (archivelog  all   not backed up 3 times );
     delete noprompt archivelog  until time = 'sysdate-21'  backed up 3 times to sbt ;

    When using the delete from the advanced job options, it is recommended to deselect the "delete" from the subclient options.

    In terms of your first question, I would say that most "typical" admins use the subclient options, but I have seen an increase of DBAs using the "advanced job" options...  It could be that they just don't know about the availability of these options from the "advanced" job options.

    Let us know if this helps...

    Ernst F. Graeler
    Senior Engineer III
  • Re: Delete all archivelog files with each backup
    Posted: 03-24-2014, 3:49 PM

    I had the impression that when running a backup, if I specified the 'not backed up 3 times' and 'delete until time = 'sysdate-21'' advanced options, that those options are only in effect for that one backup.  Are you saying that after setting these advanced options for one backup, that they are used in all future backups?

  • Re: Delete all archivelog files with each backup
    Posted: 03-24-2014, 4:05 PM

    I just ran an Archivelog backup with an advanced settings of 'delete archive logs older than 25 days' and 'not backed up 3 times'.  I thought I'd re-run the backup with the job deleting log files older than 20 days to ensure that the logs are being properly removed from the server.  When I go to re-run the job with the different settings, none of the advanced settings from the first run are preserved.  It appears these advanced options are only available when manually running backups.  Since spending my days manually running backups is not an option, it appears the availability of the advanced options is of no benefit.

    So I'm back to my original question:  Is the normal configuration to remove the Oracle log files from the server immediately after they are backed up once?

  • Re: Delete all archivelog files with each backup
    Posted: 03-24-2014, 5:34 PM

    FYI:  I've opened incident 140324-519 asking how to get the advanced options to be used with the regular scheduled backups.


  • Re: Delete all archivelog files with each backup
    Posted: 03-24-2014, 6:00 PM
    • mhz is not online. Last active: 05-31-2019, 9:09 AM mhz
    • Top 500 Contributor
    • Joined on 06-18-2010
    • Oceanport, NJ
    • Novice
    • Points 61

    When you select the advanced options and any other options for your backup, instead of selecting run immediate, choose Schedule.

    Customer Engineer Unix/DB
  • Re: Delete all archivelog files with each backup
    Posted: 03-28-2014, 11:46 AM

    Thanks.  I found it easier to go to Policies > Scheduled Policies > (Oracle full backup or archivelog schedule) > Right-click > Edit > select Task > Edit > Advanced.  I then went to the Backup Archive Logs tab and selected All, Not Backed up 3 times.  On the Delete Archive Logs tab I select Delte Archive Log > Older than 21 days > Backed up 3 times.

    Using this method allows me to see what the previous settings are.  Going through the subclient > Run Backup > Advanced always brings up blank settings so you're not sure what the current values are.



The content of the forums, threads and posts reflects the thoughts and opinions of each author, and does not represent the thoughts, opinions, plans or strategies of Commvault Systems, Inc. ("Commvault") and Commvault undertakes no obligation to update, correct or modify any statements made in this forum. Any and all third party links, statements, comments, or feedback posted to, or otherwise provided by this forum, thread or post are not affiliated with, nor endorsed by, Commvault.
Commvault, Commvault and logo, the “CV” logo, Commvault Systems, Solving Forward, SIM, Singular Information Management, Simpana, Commvault Galaxy, Unified Data Management, QiNetix, Quick Recovery, QR, CommNet, GridStor, Vault Tracker, InnerVault, QuickSnap, QSnap, Recovery Director, CommServe, CommCell, SnapProtect, ROMS, and CommValue, are trademarks or registered trademarks of Commvault Systems, Inc. All other third party brands, products, service names, trademarks, or registered service marks are the property of and used to identify the products or services of their respective owners. All specifications are subject to change without notice.
Copyright © 2019 Commvault | All Rights Reserved. | Legal | Privacy Policy