<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: RMAN script through cron in Operating System - HP-UX</title>
    <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994854#M913558</link>
    <description>Hi,&lt;BR /&gt;how do you schedule it ?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Can you prompt the line ?&lt;BR /&gt;&lt;BR /&gt;I used RMAN from cron and it worked for me.&lt;BR /&gt;&lt;BR /&gt;POut your command in a text file, called some.sql&lt;BR /&gt;&lt;BR /&gt;and run &lt;BR /&gt;&lt;BR /&gt;rman ....... @some.sql&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;HTH,&lt;BR /&gt;   Massimo&lt;BR /&gt;&lt;BR /&gt;</description>
    <pubDate>Wed, 11 Jun 2003 15:24:07 GMT</pubDate>
    <dc:creator>Massimo Bianchi</dc:creator>
    <dc:date>2003-06-11T15:24:07Z</dc:date>
    <item>
      <title>RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994853#M913557</link>
      <description>I've having problems trying to get RMAN commands to run from a script.  Ideally I want to run this script using cron.  The script will attach to RMAN and give me an RMAN&amp;gt; prompt but the commands I've listed appear to get ignored.&lt;BR /&gt;Any ideas?</description>
      <pubDate>Wed, 11 Jun 2003 15:18:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994853#M913557</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2003-06-11T15:18:28Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994854#M913558</link>
      <description>Hi,&lt;BR /&gt;how do you schedule it ?&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Can you prompt the line ?&lt;BR /&gt;&lt;BR /&gt;I used RMAN from cron and it worked for me.&lt;BR /&gt;&lt;BR /&gt;POut your command in a text file, called some.sql&lt;BR /&gt;&lt;BR /&gt;and run &lt;BR /&gt;&lt;BR /&gt;rman ....... @some.sql&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;HTH,&lt;BR /&gt;   Massimo&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Wed, 11 Jun 2003 15:24:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994854#M913558</guid>
      <dc:creator>Massimo Bianchi</dc:creator>
      <dc:date>2003-06-11T15:24:07Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994855#M913559</link>
      <description>In the cron entry you need.&lt;BR /&gt;&lt;BR /&gt;su - c oracle "script command"&lt;BR /&gt;&lt;BR /&gt;along with the normal shell redirection you use in cron.&lt;BR /&gt;&lt;BR /&gt;This assumes your oracle db owner is oracle.  Change that to fit your circumstances.&lt;BR /&gt;&lt;BR /&gt;In the command section include the full path name of the script to execute.&lt;BR /&gt;&lt;BR /&gt;To diagnose problems with the actual script, I would need to see a copy. You should be able to attach it.&lt;BR /&gt;&lt;BR /&gt;SEP</description>
      <pubDate>Wed, 11 Jun 2003 15:42:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994855#M913559</guid>
      <dc:creator>Steven E. Protter</dc:creator>
      <dc:date>2003-06-11T15:42:36Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994856#M913560</link>
      <description>Just to add to SEP's info:&lt;BR /&gt;&lt;BR /&gt;If you're using su - oracle then you need to ensure that there is nothing in oracle's .profile that will need a response or tty.  It would probably be safer to use su oracle; then source a file containing the necessary environmental setup.  Otherwise you risk running into the "not a typewriter" type messages.&lt;BR /&gt;&lt;BR /&gt;regards,&lt;BR /&gt;&lt;BR /&gt;Darren.</description>
      <pubDate>Wed, 11 Jun 2003 15:50:22 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994856#M913560</guid>
      <dc:creator>Darren Prior</dc:creator>
      <dc:date>2003-06-11T15:50:22Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994857#M913561</link>
      <description>I probably haven't explained myself very well.  Running the script through cron isn't a problem, the problem comes when executing the script.  The script will run but sit at an RMAN&amp;gt; prompt at line 8&amp;gt;, it won't run any of the RMAN commands I've put in the script (which I've copied below).&lt;BR /&gt;&lt;BR /&gt;1&amp;gt; #!/bin/sh&lt;BR /&gt;2&amp;gt; export ORACLE_SID=TMSPROD&lt;BR /&gt;3&amp;gt; export ORACLE_HOME=/oracle1/oracle/product/920&lt;BR /&gt;4&amp;gt; export RMAN=$ORACLE_HOME/bin/rman&lt;BR /&gt;5&amp;gt; cd /backup/TMSPROD/RMAN&lt;BR /&gt;6&amp;gt; cp tmsprod* /backup/TMSPROD/RMAN/old&lt;BR /&gt;7&amp;gt; rm tmsprod*&lt;BR /&gt;8&amp;gt; rman target / rcvcat rman/rman@tmsprod&lt;BR /&gt;9&amp;gt; run {&lt;BR /&gt;10&amp;gt; allocate channel c1 type disk&lt;BR /&gt;11&amp;gt; format '/backup/TMSPROD/RMAN/tmsprod_%U.dmp';&lt;BR /&gt;12&amp;gt; backup (database include current controlfile);&lt;BR /&gt;13&amp;gt; release channel c1;&lt;BR /&gt;14&amp;gt; allocate channel c1 type disk&lt;BR /&gt;15&amp;gt; format '/backup/TMSPROD/RMAN/tmsprod_al_%U.dmp;&lt;BR /&gt;16&amp;gt; sql "alter system archive log current";&lt;BR /&gt;17&amp;gt; backup (archivelog all delete input);&lt;BR /&gt;18&amp;gt; release channel c1;&lt;BR /&gt;19&amp;gt; }</description>
      <pubDate>Thu, 12 Jun 2003 08:40:29 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994857#M913561</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2003-06-12T08:40:29Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994858#M913562</link>
      <description>Hi, &lt;BR /&gt;you are doing a wrong re-direction on input (read: no redirection).&lt;BR /&gt;&lt;BR /&gt;Script should be&lt;BR /&gt;&lt;BR /&gt;1&amp;gt; #!/bin/sh &lt;BR /&gt;2&amp;gt; export ORACLE_SID=TMSPROD &lt;BR /&gt;3&amp;gt; export ORACLE_HOME=/oracle1/oracle/product/920 &lt;BR /&gt;4&amp;gt; export RMAN=$ORACLE_HOME/bin/rman &lt;BR /&gt;5&amp;gt; cd /backup/TMSPROD/RMAN &lt;BR /&gt;6&amp;gt; cp tmsprod* /backup/TMSPROD/RMAN/old &lt;BR /&gt;7&amp;gt; rm tmsprod* &lt;BR /&gt;8&amp;gt; rman target / rcvcat rman/rman@tmsprod &amp;lt;&amp;lt; EOF &lt;BR /&gt;9&amp;gt; run { &lt;BR /&gt;10&amp;gt; allocate channel c1 type disk &lt;BR /&gt;11&amp;gt; format '/backup/TMSPROD/RMAN/tmsprod_%U.dmp'; &lt;BR /&gt;12&amp;gt; backup (database include current controlfile); &lt;BR /&gt;13&amp;gt; release channel c1; &lt;BR /&gt;14&amp;gt; allocate channel c1 type disk &lt;BR /&gt;15&amp;gt; format '/backup/TMSPROD/RMAN/tmsprod_al_%U.dmp; &lt;BR /&gt;16&amp;gt; sql "alter system archive log current"; &lt;BR /&gt;17&amp;gt; backup (archivelog all delete input); &lt;BR /&gt;18&amp;gt; release channel c1; &lt;BR /&gt;19&amp;gt; } &lt;BR /&gt;20&amp;gt; EOF&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;or better:&lt;BR /&gt;&lt;BR /&gt;put the &lt;BR /&gt;&lt;BR /&gt;run (..)&lt;BR /&gt; in a sql called backup.sql&lt;BR /&gt;&lt;BR /&gt;and start your script calling it&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;rman target / rcvcat .... @backup.sql&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;HTH,&lt;BR /&gt;   Massimo&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;</description>
      <pubDate>Thu, 12 Jun 2003 08:43:47 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994858#M913562</guid>
      <dc:creator>Massimo Bianchi</dc:creator>
      <dc:date>2003-06-12T08:43:47Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994859#M913563</link>
      <description>Hi,&lt;BR /&gt;&lt;BR /&gt;I know very little about RMAN, but I can see that you are trying to run internal RMAN commands through the posix shell...  You will need to put the RMAN commands into a file and get RMAN to execute them, or perhaps use a here document .&lt;BR /&gt;&lt;BR /&gt;To ease testing you could run the script manually from the command line rather than via cron as this is not a cron issue.&lt;BR /&gt;&lt;BR /&gt;regards,&lt;BR /&gt;&lt;BR /&gt;Darren.</description>
      <pubDate>Thu, 12 Jun 2003 08:46:16 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994859#M913563</guid>
      <dc:creator>Darren Prior</dc:creator>
      <dc:date>2003-06-12T08:46:16Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994860#M913564</link>
      <description>Thanks Massimo I think I'm getting closer now.  I just need to get my RMAN commands just right and I'm there.  Thanks everyone, you've all been a big help!</description>
      <pubDate>Thu, 12 Jun 2003 09:10:46 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994860#M913564</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2003-06-12T09:10:46Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994861#M913565</link>
      <description>I'm not quite there it would seem.  I've tested all the RMAN commands manually but get the following output when executing the script.  Any ideas where I've gone wrong?&lt;BR /&gt;&lt;BR /&gt;[logtms01]/backup/scripts=$ ./tmsprod.sh&lt;BR /&gt;cp: cannot access tmsprod*: No such file or directory&lt;BR /&gt;rm: tmsprod* non-existent&lt;BR /&gt;&lt;BR /&gt;Recovery Manager: Release 9.2.0.3.0 - 64bit Production&lt;BR /&gt;&lt;BR /&gt;Copyright (c) 1995, 2002, Oracle Corporation.  All rights reserved.&lt;BR /&gt;&lt;BR /&gt;connected to target database (not started)&lt;BR /&gt;connected to recovery catalog database&lt;BR /&gt;&lt;BR /&gt;RMAN&amp;gt; run {&lt;BR /&gt;2&amp;gt; resync catalog;&lt;BR /&gt;3&amp;gt; change archivelog all crosscheck;&lt;BR /&gt;4&amp;gt; backup format '/backup/tmsprod/tmsprod_%U.dmp'&lt;BR /&gt;5&amp;gt; (database&lt;BR /&gt;6&amp;gt; include current controlfile);&lt;BR /&gt;7&amp;gt; backup format '/backup/tmsprod/tmsprod_%U.arc'&lt;BR /&gt;8&amp;gt; (archivelog all delete input);&lt;BR /&gt;9&amp;gt; }&lt;BR /&gt;10&amp;gt; &lt;BR /&gt;11&amp;gt; &lt;BR /&gt;RMAN-00571: ===========================================================&lt;BR /&gt;RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============&lt;BR /&gt;RMAN-00571: ===========================================================&lt;BR /&gt;RMAN-03002: failure of resync command at 06/12/2003 12:11:33&lt;BR /&gt;RMAN-06403: could not obtain a fully authorized session&lt;BR /&gt;ORA-01034: ORACLE not available&lt;BR /&gt;ORA-27101: shared memory realm does not exist&lt;BR /&gt;HP-UX Error: 2: No such file or directory&lt;BR /&gt;&lt;BR /&gt;Recovery Manager complete.</description>
      <pubDate>Thu, 12 Jun 2003 10:12:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994861#M913565</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2003-06-12T10:12:41Z</dc:date>
    </item>
    <item>
      <title>Re: RMAN script through cron</title>
      <link>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994862#M913566</link>
      <description>Can the previous message I've got it now.  I'd put the database SID in uppercase when it should have been lowercase.  All working now.  Thanks again everyone...</description>
      <pubDate>Thu, 12 Jun 2003 10:18:41 GMT</pubDate>
      <guid>https://community.hpe.com/t5/operating-system-hp-ux/rman-script-through-cron/m-p/2994862#M913566</guid>
      <dc:creator>Yvonne Butler</dc:creator>
      <dc:date>2003-06-12T10:18:41Z</dc:date>
    </item>
  </channel>
</rss>

