adddep job
You can use the adddep command to add dependencies to a job.
Overview
To add the dependencies to a job, you must have adddep access to the job. For more information about security access roles, see Security role definition.
Syntax and command line options
Before you run the command, you must specify options such as job name, dependencies, and required permissions. you can enter the command as follows:
ocli plan adddep job | adj = <jobselect> <dependency> <noask>
You can add the dependency according to the specific results you want to accomplish. The details that are required with each parameters are as follows:
JobselectSpecify the job to update, by means of attributes and qualifiers.
For example,
WA_AGT_0#JOB_STREAM.JOB
.
Specify the type of dependency and add at least one to complete the command. The following table lists the type of dependencies that you can use to create the command line.
\Command | Reference |
---|---|
at= time[timezone | tz][+n day[s] | [mm/dd |
mm/dd[/yy]] |
at |
deadline= time [timezone | tz][+n day[s] | [mm/dd |
mm/dd[/yy]]] |
deadline |
follows=[workstation#]{jobstreamname[time
[mm/dd[/yy]]][.job | @] | jobstream_id.job;schedid}| job[,...]
[if 'condition_name[| condition_name][| ...]'] |
follows |
maxdur=[time] [onmaxdur action] |
maxdur |
mindur=[time] [onmindur action] |
mindur |
until time [timezone|tz tzname][+n day[s]] |
[;onuntil action] |
until |
confirmed |
confirmed |
When you add the option as an argument the agent will not ask for confirmation before taking action on each qualifying job.
- If you add twice a dependency on a job stream to a job, both dependencies are treated.
-
When using the deadline keyword, ensure the bm check deadline option is set to a value higher than 0 in the localopts configuration file on the workstation you are working on. You can define the bm check deadline option on each workstation on which you want to be aware of the deadline expiration, or, if you want to obtain up-to-date information about the whole environment, define the option on the master domain manager. Deadlines for critical jobs are evaluated automatically, independently of the bm check deadline option.
For more information about the bm check deadline option, see Setting local options.
- If you add a dependency to a job after it has completed, it is not evaluated. However, any subsequent reruns of the job will process the dependency correctly.
- Wildcard characters are not permitted.
- If you do not specify a value for
priority
, the job reverts to its original scheduled priority. - If you do not specify a workstation in
follows
,needs
, oropens
, the default is the workstation on which the job runs.
Examples
- To add an external follows dependency on job
JOB022
in job streamMLN#/FOLDER1/SCHED_02(0600 02/24/23)
fromJOBA
in job streamMLN#/FOLDER2/NEW_TEST(0900 02/19/23)
, run the following command:ocli plan adj=MLN#/FOLDER2/NEW_TEST(0900 02/19/23).JOBA ; follows MLN#/FOLDER1/SCHED_02(0600 02/24/23).JOB022
- To stop the job
PAYROLL_JOB
in job streamABSENCES_JS
when it is completed more than 9 hours and 1 minute, run the following command:ocli plan adj DUBAI#ABSENCES_JS.PAYROLL_JOB ; maxdur=901 ;onmaxdur kill