Skip to main content
SnapManager for SAP

Schedule archive log file pruning

Contributors

When you create a backup, you can schedule the pruning of archive log files to occur at a specified time.

About this task

SnapManager allows you to prune the archive log files periodically from the active file system.

Step
  1. Enter the following command:

    smsap schedule create -profile profile_name {[-full {-online | -offline | -auto}[-retain [-hourly | -daily | -weekly | -monthly | -unlimited] [-verify]] | [-data [-files files [files]] | [-tablespaces -tablespaces [-tablespaces]] {-online | -offline | -auto}[-retain [-hourly | -daily | -weekly | -monthly | -unlimited] [-verify]] | [-archivelogs]} [-comment comment] [-protect | -protectnow | -noprotect] [-backup-dest path1 [,[path2]] [-exclude-dest path1 [,path2]] [-prunelogs{-all | -untilSCN untilSCN | -before {-date yyyy-MM-dd HH:mm:ss | -months months | -weeks weeks | -days days | -hours hours}} -prune-dest prune_dest1,,prune_dest2] -schedule-name schedule_name [-schedule-commentschedule_comment] -interval {-hourly | -daily | -weekly | -monthly | -onetimeonly} -cronstring cronstring -start-time {start-time start_time <yyyy-MM-dd HH:mm>} -runasuser -runasuser [-force] [-quiet | -verbose]

    If you want to…​ Then…​

    Schedule pruning of archive log files

    Specify the following options:

    • -prunelogs to schedule pruning of the archive log files

    • -prune-dest to prune archive log files from the archive log destinations

    Include a name for the schedule

    Specify the -schedule-name option.

    Schedule pruning of archive log files at specific time interval

    Specify the interval option and indicate whether the archive log files should be pruned based on the following interval classes:

    • -hourly

    • -daily

    • -weekly

    • -monthly

    • -onetimeonly

    Add a comment about the schedule operation

    Specify the -schedule-comment option followed by the description string.

    Specify the start time of the schedule operation

    Specify the -start-time option in the yyyy-mm-dd hh:mm format.