RMAN testing

From: Ram Raman <veeeraman_at_gmail.com>
Date: Wed, 13 Feb 2008 22:03:17 -0600
Message-ID: <effc058d0802132003v18c1aa7er600fa353035088b@mail.gmail.com>

Hi all,

I am trying to simulate what is in production in dev box and test out the existing setup. We have Oracle ATES is a small database that I created in dev. Here is the script that I take backup with:

/psoft/u02/oracle10g/cds/ATES $ cat backup_ATES.sh
export ORACLE_HOME=/psoft/u01/oracle10/app/product/10.2.0 export ORACLE_SID=ATES

$ORACLE_HOME/bin/rman <<EOF

#connect catalog rman/xxxx_at_rmanprd;
connect target;

run {
allocate channel oem_disk_backup device type disk; configure CHANNEL device type 'SBT_TAPE' clear; sql 'alter system switch logfile';
configure CHANNEL device type disk format '/psoft/u02/oracle10g/cds/ATES/bkup/%U'; recover copy of database with tag 'incr_ates'; backup as compressed backupset

     incremental level 1 cumulative  copies=1 tag 'incr_ates'
     for recover of copy with tag 'incr_ates'
     format '/psoft/u02/oracle10g/cds/ATES/bkup/%U'
     database plus archivelog delete input;
sql 'alter system switch logfile';


The first run of the script (via cron) runs good, but it still creates an image copy in $OH/dbs ( /*psoft/u01/*


piece handle=/psoft/u02/oracle10g/cds/ATES/bkup/15j8kt64_1_1 tag=INCR_ATES comment=NONE
channel oem_disk_backup: backup set complete, elapsed time: 00:01:56 channel oem_disk_backup: starting datafile copy input datafile fno=00008 name=+TST_DATA/ates/datafile/tsbig02 output filename=/*psoft/u01/*oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-TSBIG_FNO-8_16j8kt9o tag=INCR_ATES recid=8 st
channel oem_disk_backup: datafile copy complete, elapsed time: 00:00:03 Finished backup at 13-FEB-08

Starting backup at 13-FEB-08
current log archived


But the script starts to fail from the second run (via cron):

channel oem_disk_backup: starting incremental datafile backupset restore channel oem_disk_backup: specifying datafile copies to recover recovering datafile copy fno=00001
name=/psoft/u01/oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-SYSTEM_FNO-1_0aj8k74m recovering datafile copy fno=00002
name=/psoft/u01/oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-SYSTEM_FNO-2_0ej8k83a recovering datafile copy fno=00003
name=/psoft/u01/oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-SYSTEM_FNO-3_0fj8k84d recovering datafile copy fno=00004
name=/psoft/u01/oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-SYSTEM_FNO-4_02j8k597 recovering datafile copy fno=00005
name=/psoft/u01/oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-UNDOTBS1_FNO-5_0gj8kg recovering datafile copy fno=00006
name=/psoft/u01/oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-SYSAUX_FNO-6_03j8k5bj recovering datafile copy fno=00007
name=/psoft/u01/oracle10/app/product/10.2.0/dbs/data_D-ATES_I-2542000691_TS-TSBIG_FNO-7_0sj8kcsh channel oem_disk_backup: reading from backup piece
released channel: oem_disk_backup

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 02/13/2008 20:52:07 ORA-19870: error reading backup piece
ORA-19625: *error identifying file
ORA-27037: unable to obtain file status
HP-UX Error: 2: No such file or directory Additional information: 3

RMAN> Recovery Manager complete.


  1. I have configured in RMAN settings :

CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT '/psoft/u02/oracle10g/cds/ATES/bkup/%U';

CONFIGURE CHANNEL 1 DEVICE TYPE DISK FORMAT '/psoft/u02/oracle10g/cds/ATES/bkup/%U
But part of the first output was going to $ORACLE_HOME/dbs. Why?

2) Why does it look for a piece in $OH/dbs when it is not there. In the beginning it was putting backup there. But then I changed the script the way it is now. I also did crosscheck backup several times from RMAN thinking that RMAN was looking for files from before. That does not help either.

PS: THe TSBIG_FNO-8 was a datafile I added last.

If it helps here is from dba_data_files:

   FILE_ID FILE_NAME                                   TABLESPACE_NAME
---------- -------------------------------------------
         1 +TST_SYS/ates/sys/system01.dbf              SYSTEM
         2 +TST_DATA/ates/datafile/users01.dbf         SYSTEM
         3 +TST_DATA/ates/datafile/users02.dbf         SYSTEM
         4 +TST_DATA/ates/datafile/lrg01.dbf           SYSTEM
         5 +TST_SYS/ates/undo/undotbs01.dbf            UNDOTBS1
         6 +TST_SYS/ates/sys/sysaux01.dbf              SYSAUX
         7 +TST_DATA/ates/datafile/tsbig01             TSBIG
         8 +TST_DATA/ates/datafile/tsbig02             TSBIG

8 rows selected.

Thanks in advance for all who help.

Received on Wed Feb 13 2008 - 22:03:17 CST

Original text of this message