Previous Table of Contents Next


Preparing to Run Jobs

Before you can submit a job on a node, regardless of the destination type, you must set the preferred credentials for that node. If you intend to run a database job, for example, you must set the credentials for the node and the database. Remember that preferred credentials are set by choosing the Preferences option from the OEM Console’s File menu.

If the node is a Windows NT server, make sure the user you define in the OEM preferences is an NT administrator ID, and that the user has been granted the Log on as Batch Job privilege.

Remember that an Intelligent Agent must be configured and running on the server. See the section “Configuring the Intelligent Agent,” earlier in this chapter.

When scheduling jobs on a UNIX server, root.sh must have already been run on the server. Verify this by checking the permissions on the dbsnmp command in $ORACLE_HOME/bin. The permissions on the executable should be rwsr-xr-x, and the owner should be root. If this is not the case, sign on as root, run root.sh, and then proceed.

Before scheduling database startup and shutdown jobs, you must configure the database to be managed remotely. See the section “Managing Database Instances,” later in this chapter.

Creating a Job

To create a job, select Job from the OEM Console menu and choose the Create option. The Create Job window will appear. As you can see in Figure 21.12, I’ve given the job a name and description, chosen a destination type, and selected SERVER1.


Figure 21.12.  Creating a new job.

Click on the Tasks tab and select the task you would like to perform. The tasks listed on this page are predefined job tasks provided by Oracle. You can create your own job task in Tcl and submit it through the Run Tcl task on this page. See the Oracle Enterprise Manager Application Developer’s Guide for instructions on writing job tasks in Tcl.

After you have selected the task, click on the Parameters tab. This page will vary depending on the task that you’ve selected. In Figure 21.13, because I selected the Run OS Command task, I’m prompted for a command and any arguments required for that command. In this example, I’m renaming one of my alert logs so that the log doesn’t grow too large.


Figure 21.13.  Entering job parameters.

The last step in creating a job is to submit it or save it. A submitted job is scheduled for execution, either immediately or in the future. A saved job is added to the Job Library.

To submit a job, first select the Schedule tab on the Create Job window and set the execution preferences. You can run the job immediately, schedule it to run once at some time in the future, or schedule it to run repeatedly at an interval of your choice (see Figure 21.14).


Figure 21.14.  Scheduling a job.

When you finish entering the scheduling information, press the Submit button. The job will appear on the Active Jobs page of the Job system on the console. After the job has been executed, the status and output from the job will be placed in the Job History.

Double-click on an item in the Job History window in order to see its details: the pages that comprise the Job History window when the job ran, what it did, and the parameter settings. The progress page shown in Figure 21.15 shows the status of the job I just scheduled. If the job had failed, or if it had produced any output, the Show Output button would be available. You would find any errors on the Output window.


Figure 21.15.  Viewing job details.

Creating a Fixit Job

A fixit job is used to respond to the occurrence of an event. To create a fixit job, follow all the steps described in the section prior to this one, but on the General page of the Create Job window, select the Fixit Job check box (see Figure 21.16).


Figure 21.16.  Creating a fixit job.

After you’ve created the fixit job, you can apply the job to an event set in the Event Set Library. In Figure 21.17, I’ve selected the Listener UpDown event set by double-clicking on that line in the library. On the Parameters page you can choose a fixit job. As you can see, the fixit job just created is now available in the drop-down list.


Figure 21.17.  Choosing a fixit job for an event set.

For more information on editing event sets, see the section “Creating and Modifying Event Sets,” earlier in this chapter.

Managing Database Instances

Oracle Instance Manager enables you to perform administrative actions on remote databases, including startup and shutdown. It helps you manage user sessions and enables you to save multiple configurations for your database startup. If your organization is running a handful of UNIX systems for its database servers, remote startup and shutdown might not seem that important. If you are trying to manage a large number of remote database servers running on Novell, Windows NT, VMS, and various other platforms, a single tool that enables you to start and stop any database is very convenient.


Previous Table of Contents Next
Используются технологии uCoz