Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> RE: Rman - created file already exists
Try using %t in your format to get a unique identifier
(eg. "/ora10/oradata/orabkup/peregrine/hot_copies/peregrine_%t.rbk").
%p only gives you the piece number. %t is an RMAN time stamp.
-----Original Message-----
From: oracle-l-bounce_at_freelists.org
[mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Schauss, Peter
Sent: Tuesday, May 08, 2007 9:45 AM
To: oracle-l_at_freelists.org
Subject: Rman - created file already exists
I have an rman script which have been using on 8.1.7.4 for several years, but when I run it on 10.2.0.2.0 I get the following error message for each channel:
RMAN-03009: failure of backup command on ch1 channel at 05/08/2007
09:32:03
ORA-19504: failed to create file
"/ora10/oradata/orabkup/peregrine/hot_copies/peregrine_070508093147_1.rb
k"
ORA-27038: created file already exists
My script is shown below. I have played around with the format such as adding a %p after the channel number in the file name, but I still get the same error. Any suggestions?
Thanks,
Peter Schauss
#!/bin/ksh # # rman_bkup.ksh # # Backup a database using rman #
export ORACLE_BASE=/opt/oracle export ORACLE_HOME=/opt/oracle/product/10.2.0/db_1 export BACKUP_DIR=/ora10/oradata/orabkup/$1/hot_copies export BACKUP_DIR2=/ora10/oradata/orabkup/$1/hot_copiesexport PATH=$PATH:$ORACLE_HOME/bin
echo " "
signon=`cat $ORACLE_BASE/maint/dba.ctl/dba.$1`
#
BASE_NAME=`date +$1_%y%m%d%H%M%S`
#
rman target $signon nocatalog <<EOF
run {
allocate channel ch1 type disk format '$BACKUP_DIR/${BASE_NAME}_1.rbk'; allocate channel ch2 type disk format '$BACKUP_DIR/${BASE_NAME}_2.rbk'; allocate channel ch3 type disk format '$BACKUP_DIR/${BASE_NAME}_3.rbk'; allocate channel ch4 type disk format '$BACKUP_DIR/${BASE_NAME}_4.rbk'; allocate channel ch5 type disk format '$BACKUP_DIR/${BASE_NAME}_5.rbk'; allocate channel ch6 type disk format '$BACKUP_DIR/${BASE_NAME}_6.rbk';backup database;
# # Backup the control file which now contains a record # of this backup. #
-- http://www.freelists.org/webpage/oracle-l -- http://www.freelists.org/webpage/oracle-lReceived on Tue May 08 2007 - 11:01:26 CDT
![]() |
![]() |