I recently installed GRID Control and while “playing around” with it, I discovered the fantastic capability to build a job once and deploy over many targets. I thought this is very cool after experiencing so many problems with Dbconsole.

I found you can create a Job with minimal effort and deploy it to various targets with minimal effort. Database backups fit this mold exceptionally well. In my shop, all of our backups are rather routine and all share common properties: complete backup, daily at 6PM. All of our databases are small enough for complete backups rather than incremental.

If you want to quickly and easily build the backups for a dozen or more databases, you can try this process. I’m sure you will find it simple and effective. The basic steps involved are:

  1. Build a Job “template” and save it in the Job Library
  2. Choose between submitting the Job for scheduling against multiple targets or submitting the Job for each target. This process submits the Job for each target. I chose this method because I believe it gives me more flexibility to accommodate future changes for individual target requirements. You can try both methods to see which best suits your needs.

To start, bring up Oracle Grid Control and then choose the Jobs tab at the top. My screen is shown below. Now click on Job Library tab of that screen.

jobs-000

You should now be in the Job Library. Follow the numbered sequences on the next image below to create a new Library Job

jobs-001

Fill in General information about the Job

jobs-002

Key or paste in your RMAN script into the Parameters screen. I use a very generic script which uses all of the defaults I had previously established in Backup Settings for the target. A copy of my RMAN script is available here for cut & paste.

run {
backup device type disk database;
backup device type disk archivelog all not backed up delete all input;
delete noprompt obsolete device type disk;
}

After entering the script you’ll go on to specifying the Schedule. We won’t worry about the Credentials tab until we deploy to a target.

jobs-004

Set up your Schedule. Because we are deploying to individual targets, you will be able to change this later per target. In my case, all the targets have the same schedule so I can set it here and not worry about it when I deploy.

jobs-007

Deploy your new Job by selecting it from the list and then clicking the Submit button.

jobs-008

Now you will see another Job creation screen with the General settings. However, this one is now in the Jobs category and not the Job Library. You may notice, the Job name has been filled in with the name from your Job Library along with a suffix (most likely .1).  This is the time to add a Target or Targets.

jobs-010

Select one or more from the Targets List. I chose to use one target for each deployment. However, you can deploy one Job to multiple targets at the same time. My preference is to run the deployment for each target thereby creating a Job for each.

jobs-012

We’re back to the General information screen of the Job creation. At this time I also change the suffix for the Job name to match the Instance name of my target.

jobs-013

The Credentials screen gives you the opportunity to choose which credentials you want to use. In my case I am using the preferred credentials which I had already set up for each target.

jobs-014

The final Job scheduled to run every day at 6PM according to the time of the target ( you could have targets in differing time-zones).

jobs-015 

If you chose, as I did, to deploy to individual targets, you would now return to the Job Library, select your job, and click submit. This would be repeated for each target.

Leave a Reply

You must be logged in to post a comment.