How to use DURATION with RMAN backups in #Oracle

tweak

The DURATION clause enables you to reduce the performance impact of RMAN backups respectively it sets a certain time limit for the backup.

Let’s suppose your RMAN backup takes one hour now and you take it online while end users work with the database. This reduces the performance impact of the online backup by half approximately:

RMAN> backup duration 02:00 minimize load database;

The first two digits are hours, the second two digits are minutes. Above command tells RMAN to spend 02 hours and 00 minutes with the backup that takes normally one hour. That way, RMAN gets throttled down, causing roughly half the load on the system than otherwise.

In another scenario, let’s suppose that you want to limit the backup run to take only 30 minutes every night, because you want to run a batch job afterwards that must not be impacted by the backup. Without the limit, backup takes one hour. You are fine with backing up only half of your datafiles every night. This command does the trick:

RMAN> backup duration 00:30 partial minimize time database 
      not backed up since time='sysdate-1' filesperset 1;

RMAN will backup as many datafiles as possible within 30 minutes, generating one backuset per datafile. It stops after 30 minutes. Tomorrow, the remaining datafiles are being backed up. Drawback is that it takes longer in case to recover the datafiles that have two days old backups.

This is one little topic from the Oracle Database 12c Backup and Recovery Workshop that I deliver this week in Prague. Great city, by the way 🙂

,

  1. #1 von jmheuls am September 14, 2016 - 13:22

    Hello
    Just a question : What’s happen in the first example if the backup isn’t finished after 2 hours?

    Thanks in advance

  2. #2 von krishna am September 14, 2016 - 17:32

    Please tell me,What will happen I enable block change tracking with Duration option.

  3. #3 von The Oracle Guy am September 15, 2016 - 21:18

    Thanks for the excellent post. These lesser known features can really help adjust impact on users & applications

    A question, can you set reduce impact dynamically? Example: for a 6 hour backup have reduced impact for two hours then engage normal impact?

    Thanks

    Sent from my Remote Device

    >

  4. #4 von Pierre am Dezember 12, 2019 - 20:58

    So how do you know when you’ve backed up the whole db?

Kommentar verfassen

Trage deine Daten unten ein oder klicke ein Icon um dich einzuloggen:

WordPress.com-Logo

Du kommentierst mit deinem WordPress.com-Konto. Abmelden /  Ändern )

Facebook-Foto

Du kommentierst mit deinem Facebook-Konto. Abmelden /  Ändern )

Verbinde mit %s

Diese Seite verwendet Akismet, um Spam zu reduzieren. Erfahre, wie deine Kommentardaten verarbeitet werden..