Home » RDBMS Server » Backup & Recovery » Trouble running RMAN script (merged)
Trouble running RMAN script (merged) [message #406431] Thu, 04 June 2009 00:33 Go to next message
anwar786
Messages: 25
Registered: May 2009
Location: bangalore
Junior Member
hi guyz this is my shell script(HOTBACKUP2.SH)

ORACLE_SID=test export ORACLE_SID
ORACLE_HOME=/home/oracle/oracle/product/10.2.0/db_1 export ORACLE_HOME
export PATH=$PATH:$ORACLE_HOME/bin
sqlplus /nolog @/home/oracle/hotbackup2.sql


and HOTBACKUP2.SQL

ho /home/oracle/oracle/product/10.2.0/db_1/bin/rman target / catalog rman/rman@anwar

run
{
allocate channel ch1 type disk;
backup
(current controlfile);
release channel ch1;
}

but when i run the hotbackup2.sh from terminal i can ony get connected to rman

[oracle@siddhi8 ~]$ ./hotbackup2.sh

SQL*Plus: Release 10.2.0.1.0 - Production on Thu Jun 4 10:48:41 2009

Copyright (c) 1982, 2005, Oracle. All rights reserved.


Recovery Manager: Release 10.2.0.1.0 - Production on Thu Jun 4 10:48:41 2009

Copyright (c) 1982, 2005, Oracle. All rights reserved.

connected to target database: TEST (DBID=1985511869)
connected to recovery catalog database

RMAN>

its not executing the script .
what is wrong in this ?
Re: Trouble running RMAN script [message #406441 is a reply to message #406431] Thu, 04 June 2009 01:06 Go to previous messageGo to next message
Michel Cadot
Messages: 68716
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
Why do you use SQL*Plus "host" command to launch RMAN? Why don't you execute it directly at shell level?

Regards
Michel
Re: trouble in running rman script [message #406445 is a reply to message #406431] Thu, 04 June 2009 01:13 Go to previous messageGo to next message
Michel Cadot
Messages: 68716
Registered: March 2007
Location: Saint-Maur, France, https...
Senior Member
Account Moderator
Do not crosspost your question.

Regards
Michel
trouble in running rman script [message #406454 is a reply to message #406445] Thu, 04 June 2009 02:08 Go to previous messageGo to next message
anwar786
Messages: 25
Registered: May 2009
Location: bangalore
Junior Member
sorry about that
anyway i made this script hotbackup2.sh


ORACLE_SID=test export ORACLE_SID
ORACLE_HOME=/home/oracle/oracle/product/10.2.0/db_1 export ORACLE_HOME
export PATH=$PATH:$ORACLE_HOME/bin
rman target / catalog rman/rman@anwar
run
{
allocate channel ch1 type disk;
backup tablespace users
include current controlfile;
}
exit;

and i executed in the terminal

[oracle@siddhi8 ~]$ ./hotbackup2.sh

Recovery Manager: Release 10.2.0.1.0 - Production on Thu Jun 4 12:37:25 2009

Copyright (c) 1982, 2005, Oracle. All rights reserved.

connected to target database: TEST (DBID=1985511869)
connected to recovery catalog database

RMAN>

still the result is same
please help!!!!!!
Re: trouble in running rman script [message #406497 is a reply to message #406454] Thu, 04 June 2009 04:50 Go to previous messageGo to next message
ebrian
Messages: 2794
Registered: April 2006
Senior Member
The key is here document.
Re: trouble in running rman script [message #412800 is a reply to message #406497] Sun, 12 July 2009 02:39 Go to previous message
sruji6
Messages: 4
Registered: July 2009
Junior Member
thanks ebrian
i had the same problem.ur doc helped me in creating a shell script menu for start & stop DB
Previous Topic: Various Backup Methods
Next Topic: Oracle 32 bit on 64 bit processor
Goto Forum:
  


Current Time: Sun Nov 24 23:29:26 CST 2024