9 Job Views

A job is a unit of work that you define to automate commonly-run tasks. This chapter provides a description of each job view and its columns. It contains the following sections:

For examples of how to use views, see Chapter 20, "Examples".

9.1 MGMT$CA_TARGETS

The MGMT$CA_TARGETS view provides basic information about a Corrective Action (CA).

Table 9-1 MGMT$CA_TARGETS

Column Description

CA_NAME

Name of the CA

CA_ID

Unique ID of the CA

CA_OWNER

Owner of the CA

CA_DESCRIPTION

Description of the CA

JOB_TYPE

Job type of the CA

TARGET_NAME

Name of the target associated with the CA

TARGET_TYPE

Type of target associated with the CA

TARGET_GUID

Unique ID of the target associated with the CA

IS_BROKEN

Specifies whether the CA is broken

Possible values:

  • 1: CA is broken

  • 0: CA is not broken


9.2 MGMT$CA_EXECUTIONS

The MGMT$CA_EXECUTIONS view provides a summary of the Corrective Actions (CA) executions along with the status and targets for each execution.

Table 9-2 MGMT$CA_EXECUTIONS

Column Description

CA_NAME

Name of the CA

CA_OWNER

Owner of the CA

CA_ID

Unique ID of the CA

JOB_TYPE

Job type of the CA

EXECUTION_ID

Execution ID of the CA

SCHEDULED_TIME

Scheduled time for the CA execution

START_TIME

Start time of the CA execution (in Coordinated Universal Time (UTC))

END_TIME

End time of the CA execution (in UTC)

TRIGGERING_SEVERITY

Severity that triggered the CA

TARGET_NAME

Name of the target on which the CA executed

Note: This value can be different from the target with which the CA is associated

TARGET_TYPE

Type of target on which the CA executed

TARGET_GUID

Unique ID of the target on which the CA executed

TIMEZONE_REGION

The time zone region associated with the execution

STATUS

Represents the status of the execution

Possible values:

  • Scheduled: The execution is scheduled

  • Running: The execution has steps that have ran already or are running currently

  • Error: The execution encountered internal errors and terminated

  • Failed: Some steps of the execution ran into failures

  • Succeeded: The execution ran as expected

  • Suspended By User: The user suspended the execution

  • Suspended: Agent Unreachable: The execution cannot continue because the Management Agent cannot be contacted

  • Stopped: The execution is stopped explicitly

  • Suspended on Lock: The execution cannot continue because it is waiting for a logical lock to be obtained

  • Suspended on Event: The execution cannot continue because it is waiting for an internal event (such as a Management Agent restart) or a timeout to occur

  • Suspended on Blackout: The execution cannot proceed because the target it is supposed to run against is under blackout

  • Suspend Pending: The user initiated a suspension of the execution but the execution is still running because some steps cannot be suspended

  • Stop Pending: The user initiated a stop of the execution but the execution is waiting for some steps that could not be stopped

  • Inactive: This status is not used in the current release

  • Queued: The execution is submitted against a queue and there are executions that must complete before this execution can complete

  • Waiting: This execution tracks the next schedule compared to the current scheduled, running, or suspended execution

  • Skipped: The execution did not start and its corresponding schedule was skipped. The skip could be due to many reasons, such as overshooting the start grace period, previous schedule not completed when the scheduled time of this execution passed, or the OMS is down. These executions have no corresponding steps

  • Reassigned: The owner of the job has changed and the new owner has not updated the job to claim ownership.

  • Missing Credentials: The execution is blocked waiting for the user to supply target credentials

  • Action Required: The execution is blocked waiting for user action

  • Suspended on Broken Target: The execution cannot proceed becasue the corresponding target is broken (it has metric collection issues)

STATUS_INTERNAL

Internal status of the execution.

STATUS_CODE

Status code of the execution. The meaning of this column varies depending on the job type and the steps ran for the execution. This code usually maps ot the exit cilde of the step that rolls up the status.

STATUS_BUCKET

The status bucket to which the execution corresponds.

Note: This value can change from one release to another or between patchsets. Oracle recommends that you do not use this value as filtering criteria

STATE_CYCLE

Provides a lifecycle representation of the status of the execution.

Possible values:

  • SCHEDULED: The execution has no steps that are executed. All steps corresponding to the execution are either scheduled to be picked up shortly or later in the future

  • RUNNING: The execution has at least one step that ran or is running while no steps are blocked waiting for external processing

  • SUSPENDED: The execution is blocked and is waiting for external processing or an external event. For example, the user might have suspended the execution or a step of the execution might be waiting for some other system to respond (such as clearing of blackout, or a Management Agent restart). Such an execution cannot proceed until a timeout occurs or the event that the execution is waiting on occurs.

  • FINISHED: The execution has reached a terminal status where no further execution is possible. These executions usually cannot be manipulated in any way (except for failed executions that can be retried, but the retry operation creates a new execution, and does not affect the current execution)


9.3 MGMT$JOBS

The MGMT$JOBS view displays information about a job including the job's schedule.

Table 9-3 MGMT$JOBS

Column Description

JOB_NAME

The unique name for the job

JOB_ID

The unique system identifier for the job

JOB_OWNER

The owner or creator of the job

JOB_DESCRIPTION

Optional text describing the job function

JOB_TYPE

The job type. For example, multi-task, SQL script or OS Command.

TARGET_TYPE

The type of target the job was submitted against. Applies to single-target jobs only

IS_LIBRARY

Indicates whether or not the job is part of the job library

IS_RESTARTABLE

Indicates whether the job can be restarted. ”0” indicates the job is not restartable. ”1” indicates the job is not restartable.

By default, a job is not restartable if the original job owner is deleted and the job is transferred to another administrator.

START_TIME

The scheduled start time. For daily, days of week and days of month schedules, the start_time denotes when the job should start.

END_TIME

For all periodic schedules, the last date (and time) to run the job. For daily, day of week and day of month schedules, only the date portion is used.

TIMEZONE_TYPE

Possible values are:

  • 1 - Repository (deprecated)

  • 2 - Agent

  • 3 - Specified Offset/Region (offset from GMT)

  • 4 - Specified Offset/Region (time zone region name)

TIMEZONE_REGION

The specified time zone region

SCHEDULE_TYPE

Possible values are:

  • 1 - One Time

  • 2 - Interval

  • 3 - Daily

  • 4 - Weekly

  • 5 - Monthly

  • 6 - Yearly

INTERVAL

If schedule_type is interval (2), this is the interval at which the job repeats, in minutes

EXECUTION_HOURS

Indicates the time of day at which the job will execute. Hours are specified using the 24-hour format (0 to 23)

EXECUTION_MINUTES

Indicates the time of day at which the job will execute. Minutes are specified as a number between 0 and 59

MONTHS

For days-of-year job schedules, this indicates the ”month” in the schedule

DAYS

For day-of-week/month or day(s) of the week job schedules, this indicates the ”day” of the week/month.

Days-of-week specified as numbers 1 (Sunday) to 7 (Saturday).

Days-of-month specified as numbers 1 to 31.


9.4 MGMT$JOB_TARGETS

The MGMT$JOB_TARGETS view displays the target(s) the job was submitted against.

Table 9-4 MGMT$JOB_TARGETS

Column Description

JOB_NAME

The unique name for the job

JOB_OWNER

The owner or creator of the job

JOB_ID

Unique id of the submitted job

JOB_TYPE

The job type. For example, multi-task, SQL script or OS Command.

TARGET_NAME

Name of the target the job was submitted against

TARGET_TYPE

The type of target the job was submitted against. Applies to single-target jobs only.

TARGET_GUID

The unique global identifier for the target


9.5 MGMT$JOB_EXECUTION_HISTORY

The MGMT$JOB_EXECUTION_HISTORY view displays a summary of job executions along with their status and targets for each execution.

Table 9-5 MGMT$JOB_EXECUTION_HISTORY

Column Description

JOB_NAME

The unique name for the job

JOB_OWNER

The owner of the job

JOB_ID

The unique system identifier for the job

JOB_TYPE

The job type. For example, multi-task, SQL script or OS Command.

EXECUTION_ID

The unique execution identifier

SCHEDULED_TIME

The scheduled time of job execution (using the time zone specified by TIMEZONE_REGION)

START_TIME

The actual time (UTC) the job executed

END_TIME

The actual time (UTC) the job ended execution

TARGET_NAME

Name of the target the job was submitted against

TARGET_TYPE

The type of target the job was submitted against. Applies to single-target jobs only.

TARGET_GUID

The unique global identifier for the target

TIMEZONE_REGION

The time zone region specifying to the job execution

STATUS

The current status of the job execution

Valid values:

  • Scheduled: The job execution is scheduled

  • Running: The job execution had steps that are run already or are running at the moment

  • Error: The job execution encountered internal errors and stopped unexpectedly

  • Failed: Some of the steps of the job execution failed

  • Succeeded: The job execution completed as expected

  • Suspended By User: The user suspended the job execution

  • Suspended: Agent Unreachable: The job execution cannot continue because it cannot contact the Management Agent

  • Stopped: The job execution is stopped

  • Suspended on Lock: The job execution cannot proceed because it waiting for a logical lock to be obtained

  • Suspended on Event: The job execution cannot proceed because it is waiting for an internal event (such as restarting the Management Agent) or a timeout to occur

  • Suspended on Blackout: The job execution cannot proceed because the target that the job is running against is under blackout

  • Suspend Pending: The user initiated a suspension but the job execution is still running because some steps could not be suspended

  • Stop Pending: The user initiated a stop but the job execution is waiting for some steps that could not be stopped

  • Inactive: This status is not used in the current release

  • Queued: The job execution is submitted against a queue and there are other jobs that must complete before this job execution can proceed

  • Waiting: The job execution tracks the next schedule compared to the current scheduled or running or suspended job execution

  • Skipped: The job execution did not start and its corresponding schedule is skipped

  • Reassigned: The job owner is changed and the new owner has not updated to job to claim ownership

  • Missing Credentials: The job execution is blocked and is waiting for the user to supply target credentials

  • Action Required: The job execution is blocked waiting for user action

  • Suspended on Broken Target: The job execution cannot proceed because the corresponding target is broken

STATUS_INTERNAL

The internal integer status of the job execution

STATUS_CODE

The status code of the job execution. This integer usually maps to the exit code of the step that rolls up the status.

STATUS_BUCKET

The status bucket to which the execution corresponds

Note: This value can change between patchsets and Oracle recommends that you do not use this value as filtering criteria

STATE_CYCLE

Provides a lifecycle representation of the status of the execution

Valid values:

  • SCHEDULED: The execution has no steps that are executed yet

  • RUNNING: The execution has at least one step that ran or is running and no steps are blocked

  • SUSPENDED: The execution has blocked steps that are waiting for external processing or an external event

  • FINISHED: The execution has reached where no further execution is possible

SOURCE_EXECUTION_ID

The execution which was retried and caused this execution (EXECUTION_ID). For executions that are not retried, the SOURCE_EXECUTION_ID is the same as the EXECUTION_ID.

RETRIED

This value is set to 1 if this execution is retried. Otherwise, it is set to 0


9.6 MGMT$JOB_STEP_HISTORY

The MGMT$JOB_STEP_HISTORY view displays step-level details of job executions.

Table 9-6 MGMT$JOB_STEP_HISTORY

Column Description

JOB_NAME

The unique name for the job

JOB_OWNER

The owner or creator of the job

JOB_ID

The unique system identifier for the job

EXECUTION_ID

The unique execution identifier

STEP_NAME

The name of the job step

START_TIME

The start time of the job step

END_TIME

The end time of the job step

STATUS

The current status of the job execution

TARGET_NAME

Name of the target the job was submitted against

TARGET_TYPE

The type of target the job was submitted against. Applies to single-target jobs only.

TARGET_GUID

The unique global identifier for the target

OUTPUT

Generated job output

STATUS_INTERNAL

The internal integer status of the job step

STATUS_CODE

The status code of the job execution. This integer usually maps to the exit code of the step that rolls up the status

STEP_ID

The step ID of the job step

STEP_TYPE

The step type of the job step


9.7 MGMT$JOB_ANNOTATIONS

The MGMT$JOB_ANNOTATIONS view displays a summary of annotations for changes in job status.

Table 9-7 MGMT$JOB_ANNOTATIONS

Column Description

JOB_NAME

The unique name for the job

JOB_OWNER

The owner or creator of the job

JOB_STATUS

The job status. Possible values are as follows:

  • 1: Scheduled

  • 2: Executing

  • 3: Aborted

  • 4: Failed

  • 5: Completed

  • 6: Suspended

  • 7: Agent Down

  • 8: Stopped

  • 9: Suspended/Lock

  • 11: Suspended/Blackout

  • 13: Suspend Pending

  • 15: Queued

  • 16: Failed

  • 17: Waiting

  • 18: Skipped

OCCURRENCE_TIMESTAMP

The time at which the state change occurred

ANNOTATION_MESSAGE

Annotation text

ANNOTATION_TIMESTAMP

The time the annotation was created

ANNOTATED_BY

Enterprise Manager administrator who authored the annotation


9.8 MGMT$JOB_NOTIFICATION_LOG

The MGMT$JOB_NOTIFICATION_LOG view displays details of notification deliveries for changes in job status.

Table 9-8 MGMT$JOB_NOTIFICATION_LOG

Column Description

JOB_NAME

The unique name for the job

JOB_OWNER

The owner or creator of the job

JOB_STATUS

The job status.

Possible values:

  • 1: Scheduled

  • 2: Executing

  • 3: Aborted

  • 4: Failed

  • 5: Completed

  • 6: Suspended

  • 7: Agent Down

  • 8: Stopped

  • 9: Suspended/Lock

  • 11: Suspended/Blackout

  • 13: Suspend Pending

  • 15: Queued

  • 16: Failed

  • 17: Waiting

  • 18: Skipped

OCCURRENCE_TIMESTAMP

The time at which the state change occurred

DELIVERY_MESSAGE

The message  indicating the success or failure of the notification delivery

DELIVERY_TIMESTAMP

The time at which the log message was created