Home » Infrastructure » Linux » coding for job schduling in shell programming.
coding for job schduling in shell programming. [message #263308] Wed, 29 August 2007 12:02 Go to next message
kapil.kaushish
Messages: 12
Registered: February 2007
Location: delhi
Junior Member

Dear

This is Kapil Kaushish

I want hot backup database evey day on aproper predefinied time.

server is apache, dabase is Oracle 9i and OS is linux.

Let me prrovide the coding for everyday i cuold be take backup of database at 11.00 pm .

Find the attechment PL block for hotbackup of database

provide me by the time.
I need very urgent .
With regards

Kapil Kaushish
  • Attachment: backup.doc
    (Size: 25.50KB, Downloaded 1629 times)
Re: coding for job schduling in shell programming. [message #263320 is a reply to message #263308] Wed, 29 August 2007 13:00 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Many of us (including me) don't or can't download doc file.
Use a text one.

You'll take profit in reading: Database Backup and Recovery Quick Start Guide

Regards
Michel
Re: coding for job schduling in shell programming. [message #263416 is a reply to message #263320] Thu, 30 August 2007 00:22 Go to previous messageGo to next message
kapil.kaushish
Messages: 12
Registered: February 2007
Location: delhi
Junior Member

Dear Sir
Find this file again

I want shell script to impelement dynamically on a specific time.
find this attechment again

I want this bach file automatically run at 10.00 pm every night.
just provide me coding for this by the time because its very urgent

with regards
Kapil Kaushish

kapil.kaushish@gmail.com
  • Attachment: back_up.sql
    (Size: 1.64KB, Downloaded 1723 times)
Re: coding for job schduling in shell programming. [message #263446 is a reply to message #263416] Thu, 30 August 2007 01:44 Go to previous message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Just insert at first line:
whenever sqlerror exit
And append after the last line:
@backup.cmd

This script can then be executed with:
sqlplus -s <user>/<psw> @back_up.sql

This command can be put in a shell script that set the environment (ORACLE_SID, ORACLE_HOME...).

And this shell script can be put in a crontab (see "man crontab").

Regards
Michel
Previous Topic: script not executing in cron
Next Topic: rebuild index failure in Crontab
Goto Forum:
  


Current Time: Thu Apr 18 12:06:23 CDT 2024