This discussion is archived
9 Replies Latest reply: Jan 28, 2013 11:03 PM by Hemant K Chitale RSS

Rman Backup

969526 Newbie
Currently Being Moderated
Hi,

The following is my parameters for Rman backup. Now i want to store the same backup in two different location. Say i want to store it in J:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a' also. Means the same what store in F:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a'. Please suggest what change i have to made to store that in two different locations.


RMAN> show all;

RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 30 DAYS;
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK;
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE 'SBT_TAPE' TO '%F';
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE 'SBT_TAPE' PARALLELISM 1 BACKUP TYPE TO BACKUPSET;
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE 'SBT_TAPE' TO 1;
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE 'SBT_TAPE' TO 1;
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT 'F:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a';
CONFIGURE CHANNEL DEVICE TYPE 'SBT_TAPE' CONNECT '*';
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default
CONFIGURE SNAPSHOT CONTROLFILE NAME TO 'D:\ORACLE\PRODUCT\10.2.0\DB_1\DATABASE\SNCFORCL.ORA'; # default
  • 1. Re: Rman Backup
    Hemant K Chitale Oracle ACE
    Currently Being Moderated
    You have to run an additional
    BACKUP DATABASE FORMAT 'J:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a'  ;
    Hemant K Chitale
  • 2. Re: Rman Backup
    969526 Newbie
    Currently Being Moderated
    Dear Hemant,

    The following is my Rman script for database backup which is running on scheduler. i have to add *'BACKUP DATABASE FORMAT 'J:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a''* this to the script or i have to run separately.

    RUN
    {

    BACKUP CURRENT CONTROLFILE;
    BACKUP DATABASE;
    Sql 'Alter system archive log current';

    }
    exit;
  • 3. Re: Rman Backup
    Hemant K Chitale Oracle ACE
    Currently Being Moderated
    Actually, another option you could try is to change the BACKUP DATABASE command to
    BACKUP DATABASE COPIES 2 FORMAT 'F:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a','J:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a'  ;
    I haven't tried it myself.

    Hemant K Chitale
  • 4. Re: Rman Backup
    969526 Newbie
    Currently Being Moderated
    Ok, Thanks....
  • 5. Re: Rman Backup
    969526 Newbie
    Currently Being Moderated
    This command not working ans it shows following error...




    RMAN> BACKUP tablespace orissa_master COPIES 2 FORMAT 'd:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a','d:\Rman\Backup%d_DB_%u_%s_%p_%a' ;

    RMAN-00571: ===========================================================
    RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
    RMAN-00571: ===========================================================
    RMAN-00558: error encountered while parsing input commands
    RMAN-01009: syntax error: found "copies": expecting one of: "archivelog, backup, backupset, channel, comma, copy, controlfilecopy, current, database, datafile, datafilecopy, delete, diskratio, db_recovery_file_
    dest, filesperset, format, from, force, include, keep, (, maxsetsize, noexclude, nokeep, not, pool, plus, reuse, recovery, ;, skip, spfile, setsize, tablespace, tag, to"
    RMAN-01007: at line 1 column 33 file: standard input
  • 6. Re: Rman Backup
    969526 Newbie
    Currently Being Moderated
    You have to run an additional


    BACKUP DATABASE FORMAT 'J:\Rman_Prod\Backup%d_DB_%u_%s_%p_%a' ;

    Hemant K Chitale



    The above will store the backup only in 'J:\Rman_Prod' not in both 'I:\Rman_Prod' & 'J:\Rman_Prod' locations.
  • 7. Re: Rman Backup
    Hemant K Chitale Oracle ACE
    Currently Being Moderated
    Oh. You are running 10.2

    The COPIES option appears in the 11.2 documentation. See Example 2-22 at http://docs.oracle.com/cd/E11882_01/backup.112/e10643/rcmsynta007.htm#CHDJIJDH

    In 10.2 you'd have to add a separate BACKUP DATABASE FORMAT 'J:....' command in the backup script.
    The two backups would not be the same as each other (copies of each other) as the second backup would begin after the first backup completes.


    Hemant K Chitale

    Edited by: Hemant K Chitale on Jan 29, 2013 2:56 PM
  • 8. Re: Rman Backup
    969526 Newbie
    Currently Being Moderated
    Ok, Thanks a lot.
  • 9. Re: Rman Backup
    Hemant K Chitale Oracle ACE
    Currently Being Moderated
    Duplexing Backup with the COPIES parameter does appear in the 10.2 documentation.
    http://docs.oracle.com/cd/B19306_01/backup.102/b14194/rcmsynta009.htm#sthref141

    Can you retry it ? See the example "Duplexing a Backup Set: Example"

    http://docs.oracle.com/cd/B19306_01/backup.102/b14194/rcmsynta009.htm#sthref141


    Hemant K Chitale

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points