Rman/PERL scripts errors
464053Nov 1 2005 — edited Nov 8 2005I am trying to automate the backups and disk maintenence on a test machine using a "Host Command" in the 10g EM environment. If I run the script from the command on the target host the scripts completes successfully.
This is the script:
ORACLE_HOME=/u01/app/oracle/product/9.2.0
export ORACLE_HOME
ORACLE_SID=coeusdba.
export ORACLE_SID
rman <<EOF
connect target sys<password>@coeusdba;
connect catalog <user>/<password>@recv;
replace script coeusdba_full_bkp {
allocate channel Channel1 type disk format '/u03/orabkp/coeusdba/b_%u_%p_%c';
backup
( database include current controlfile );
backup ( archivelog all delete input );
}
run { execute script coeusdba_full_bkp;}
EOF
/u01/app/oracle/product/9.2.0/dbs/scripts/coeusdba_new.sh
exit
When I execute the same script from a 10g EM "Host Command" job the script fails at the PERL command step with the following output:
Recovery Manager: Release 9.2.0.7.0 - Production
Copyright (c) 1995, 2002, Oracle Corporation. All rights reserved.
RMAN>
RMAN>
connected to target database: COEUSDBA (DBID=1916078485)
RMAN>
RMAN>
connected to recovery catalog database
RMAN> 2> 3> 4> 5> 6> 7> 8>
replaced script coeusdba_full_bkp
RMAN>
RMAN>
executing script: coeusdba_full_bkp
allocated channel: Channel1
channel Channel1: sid=10 devtype=DISK
Starting backup at NOV-01-2005 10:32:32
channel Channel1: starting full datafile backupset
channel Channel1: specifying datafile(s) in backupset
including current controlfile in backupset
input datafile fno=00006 name=/u02/oradata/coeusdba/users01.dbf
input datafile fno=00002 name=/u03/oradata/coeusdba/undotbs01.dbf
input datafile fno=00004 name=/u03/oradata/coeusdba/index01.dbf
input datafile fno=00005 name=/u03/oradata/coeusdba/tools01.dbf
input datafile fno=00007 name=/u03/oradata/coeusdba/xdb01.dbf
input datafile fno=00001 name=/u02/oradata/coeusdba/system01.dbf
input datafile fno=00003 name=/u02/oradata/coeusdba/drsys01.dbf
channel Channel1: starting piece 1 at NOV-01-2005 10:32:33
channel Channel1: finished piece 1 at NOV-01-2005 10:33:28
piece handle=/u03/orabkp/coeusdba/b_3rh2l4q1_1_1 comment=NONE
channel Channel1: backup set complete, elapsed time: 00:00:55
Finished backup at NOV-01-2005 10:33:28
Starting backup at NOV-01-2005 10:33:29
current log archived
channel Channel1: starting archive log backupset
channel Channel1: specifying archive log(s) in backup set
input archive log thread=1 sequence=49 recid=200 stamp=573215609
channel Channel1: starting piece 1 at NOV-01-2005 10:33:32
channel Channel1: finished piece 1 at NOV-01-2005 10:33:33
piece handle=/u03/orabkp/coeusdba/b_3sh2l4rr_1_1 comment=NONE
channel Channel1: backup set complete, elapsed time: 00:00:02
channel Channel1: deleting archive log(s)
archive log filename=/u04/arch/coeusdba/1_49.dbf recid=200 stamp=573215609
Finished backup at NOV-01-2005 10:33:35
Starting Control File and SPFILE Autobackup at NOV-01-2005 10:33:35
piece handle=/u04/orabkp/coeusdba/ctl_file_bkps/c-1916078485-20051101-00 comment=NONE
Finished Control File and SPFILE Autobackup at NOV-01-2005 10:33:38
released channel: Channel1
RMAN>
RMAN>
Recovery Manager complete.
syntax error at /u01/app/oracle/product/9.2.0/EM10g_1/perl/lib/5.6.1/warnings.pm line 306, near "{^"
syntax error at /u01/app/oracle/product/9.2.0/EM10g_1/perl/lib/5.6.1/warnings.pm line 311, near "{^"
BEGIN failed--compilation aborted at /u01/app/oracle/product/9.2.0/EM10g_1/perl/lib/5.6.1/English.pm line 38.
BEGIN failed--compilation aborted at /u01/app/oracle/product/9.2.0/dbs/scripts/rmanc.pl line 20
Is anyone having this problem in 10g and if so , can you provide me with some insight with respect to resolution?