Hitachi

JP1 Version 12 JP1/Automatic Job Management System 3 Command Reference


ajsplan

Organization of this page

Format

ajsplan
     [-F service-name]
     [[-d[[year/]month/]day][-t hours[:minutes]][-p][-i]
          |[-b day][-c minutes][-p][-i]
          |-q[-p|-w][-i]|-p|-u]
     [-h|-r]
     [-n {priority-value|none}]
     [-s {none|hours:minutes|M-minutes|U-minutes|C-minutes}]
     [-e {none|hours:minutes|M-minutes|U-minutes|C-minutes}]
     [-f {none|minutes}]
     [-B execution-registration-number]
     [-j|-m {hours:minutes|M-minutes|unlimited}
          -k {number-of-times|unlimited}]
     [-l {y|n}]
     [-xw {enable|disable} -xn unit-whose-end-is-being-waited-for]
     [-R]
     [-E]
     [-T]
     [-N|-J]
     [-X {yes|no|auto}]
     job-name-or-jobnet-name-or-job-group-name...

Description

  1. Temporarily changes the next execution schedule of a jobnet registered for execution and it follows the schedule defined for the jobnet.

  2. Temporarily changes the execution order control method for the jobnet to which the jobnet connector is connected if the root jobnet execution order is controlled. (Note that this change applies to only root jobnets and planning groups.)

  3. Temporarily holds, releases, cancels, or resumes a job and it follows by execution according to the attributes defined for the job.

  4. Temporarily enables or disables a wait condition assigned to a job or jobnet. (After executing with the modified wait condition setting, the job runs according to the definition.)

    This feature is only available when the database uses a standard configuration.

Execution privileges

You must have any of the following JP1 privileges:

Arguments

-F service-name

Specify the name of the target scheduler service.

You can specify a character string of 1 to 30 bytes.

-d [[year/]month/]day

Specify the next execution start date to be changed temporarily.

You cannot specify this option for a job. If you set this option with the -p option in a root jobnet and push ahead the next schedule, the former schedule for the next execution is canceled. If you push ahead the next schedule without specifying the -p option, the schedule is added.

For a nested jobnet, the command only modifies the scheduled date/time regardless of whether the -p option is specified.

  • year

    You can specify a value between 1994 and 2036.

  • month

    You can specify a value between 1 (or 01) and 12.

  • day

    You can specify a value between 1 (or 01) and 31.

If you omit the year or the year/month in this option, the following values are assumed.

year: Year when the command was executed

year/month: Year and month when the command was executed

Assuming that the -t option has been specified instead of this option, the system assumes the year/month/day value if a jobnet with the generation as the target of temporary change is scheduled to be executed next time. Otherwise, an error takes place.

-t hours[:minutes]

Specify the absolute time when to start the next execution.

You cannot specify this option for a job. If you set this option with the -p option in a root jobnet and push ahead the next schedule, the former schedule for the next execution is canceled. If you push ahead the next schedule without specifying the -p option, the schedule is added.

For a nested jobnet, the command only modifies the scheduled date/time regardless of whether the -p option is specified.

If you specify this option with the -i option, the next execution schedule time for any jobnets in the specified jobnet are also changed relatively.

  • hours

    You can specify a value between 0 (or 00) and 47.

  • minutes

    You can specify a value between 0 (or 00) and 59. If you omit this option, the system assumes 0.

If you specify the -d option instead of this option, and if the jobnet of the generation for which a temporary change is being made has a schedule for execution, the scheduled time of execution (hours:minutes) is assumed.

If the jobnet has no schedule for execution, an error occurs.

You can also temporarily change the jobnet execution start time from JP1/AJS3 - View. For details about the operation procedure in JP1/AJS3 - View, see 9.3.1 Changing the execution start time of a jobnet in the JP1/Automatic Job Management System 3 Operator's Guide.

-p

Cancels the next execution schedule for a jobnet or job.

If you have already temporarily changed the next execution schedule, reset the current status using the -u option, then execute this command.

If you specify this option with the -d, -t, -b, -c, or -q option in a root jobnet to push ahead the next schedule, the next execution schedule is canceled.

For a nested jobnet, this option does not take effect if specified with the -d, -t, -b, -c, or -q option.

-b day

Specify the execution start date you want to change temporarily. To specify it, use the number of days relative to the scheduled execution day in the generation for which a temporary change should be made.

If there is no schedule for execution, an error occurs.

You can specify a value between -99 and 99 (days) except 0.

If you specify the -c option instead of this option, 0 days are assumed as the relative number of days.

You cannot specify this option for a job. If you set this option with the -p option in a root jobnet and push ahead the next schedule, the former schedule for the next execution is canceled. If you push ahead the next schedule without specifying the -p option, the schedule is added.

For a nested jobnet, the command only modifies the scheduled date/time regardless of whether the -p option is specified.

If you specify this option with the -i option, the next execution schedule time for any jobnets in the specified jobnet are also changed relatively.

-c minutes

Specify the execution start time you want to change temporarily. To specify it, use the number of minutes relative to the scheduled execution time in the generation for which a temporary change should be made.

If there is no schedule for execution, an error occurs.

You can specify a value between -2,879 and 2,879 (minutes) except 0.

You cannot specify this option for a job. If you set this option with the -p option in a root jobnet and push ahead the next schedule, the former schedule for the next execution is canceled. If you push ahead the next schedule without specifying the -p option, the schedule is added.

For a nested jobnet, the command only modifies the scheduled date/time regardless of whether the -p option is specified.

If you specify this option with the -i option, the next execution schedule time for any jobnets in the specified jobnet are also changed relatively.

-q

The jobnet generation scheduled to be executed the next time is immediately executed as soon as the command is entered regardless of the schedule definition for the root jobnet. If you specify this option for a nested jobnet, it modifies the base time for the execution date for a root jobnet.

If you specify this option with the -p option in a root jobnet, the former schedule for the next execution is canceled. Pushing ahead the next schedule without specifying the -p option results in the addition of a schedule. Executing the command with the -p option specified or postponing the next schedule without specifying the -p option results in the moving schedule to a later time.

For a nested jobnet, the command only modifies the scheduled date/time regardless of whether the -p option is specified.

If you specify this option with the -i option, the next execution schedule time for any jobnets in the specified jobnet are also changed relatively.

You can also use JP1/AJS3 - View to immediately execute a jobnet that has already been scheduled. For details about operation in JP1/AJS3 - View, see 9.4 Immediately executing the execution schedule of a jobnet in the JP1/Automatic Job Management System 3 Operator's Guide.

-w

Ends the command after the end of jobnet execution.

Only specify this option to register the root jobnet for immediate execution. You cannot specify it when the root jobnet is to be held or undergo a planned temporary change.

Even if you specify this option, the command will terminate without waiting for the end of the jobnet in the following cases:

  • The scheduler service stops during jobnet execution.

  • The generation with a termination wait is left unexecuted when using the carryover method.

  • The generation with a termination wait is deleted. (For example, the generation that is unregistered for execution or registered for immediate execution or fixed execution discontinues its execution.)

  • The generation with a termination wait specified is left unplanned. (For example, the subsequent schedule is left unplanned as a result of a schedule or calendar change in a jobnet registered for planned execution)

You can specify this option only in the root jobnet. Specify together with the -q option. You cannot specify this option with the -m or -k option.

-i

Relatively changes the starting time for executing a specified job.

You can specify these options only for a jobnet. Specify this option with the -d, -t, -b, -c, or -q option.

-u

Resets the schedule changed temporarily by the -d, -t, -b, -c, -q, or -p option to the original status.

If you temporarily change the schedule multiple times, the information prior to the first change is restored.

-h

Temporarily holds the next jobnet or job execution.

-r

Temporarily releases a held jobnet or job.

-n {priority-value|none}

Temporarily changes the priority of jobnet execution.

You cannot specify this option for a job.

  • priority-value

    You can specify a value between 1 and 5.

    The lowest priority is 1 and the highest is 5.

  • none

    Sets the priority of execution defined for the jobnet.

-s {none|hours:minutes|M-minutes|U-minutes|C-minutes}

Specify the next delayed start time.

You can specify this option only for a jobnet.

  • none

    Does not monitor the delayed start.

  • hour:minutes

    Specify absolute hours and minutes.

    You can specify a value between 0 (or 00) and 47 for the hours.

    You can specify a value between 0 (or 00) and 59 for the minutes.

  • M-minutes

    Specify the next delayed start time by the relative minutes from the time when the root jobnet starts to be executed.

    You can specify a value between 1 (or 01) and 2,879 (minutes).

  • U-minutes

    Specify the next delayed start time by the relative minutes from the time when the upper-level jobnet starts to be executed.

    You can specify a value between 1 (or 01) and 2,879 (minutes).

  • C-minutes

    Specify the next delayed start time by the relative minutes from the time when the jobnet starts to be executed.

    You can specify a value between 1 (or 01) and 2,879 (minutes).

-e {none|hours:minutes|M-minutes|U-minutes|C-minutes}

Specify the next delayed end time.

You cannot specify this option for a job.

  • none

    Does not monitor the delayed end.

  • hour:minutes

    Specify an absolute time.

    You can specify a value between 0 (or 00) and 47 for the hours.

    You can specify a value between 0 (or 00) and 59 for the minutes.

  • M-minutes

    Specify the next delayed end time by the relative minutes from the time when the root job net starts to be executed.

    You can specify a value between 1 (or 01) and 2,879 (minutes).

  • U-minutes

    Specify the next delayed end time by the relative minutes from the time when the upper jobnet starts to be executed.

    You can specify a value between 1 (or 01) and 2,879 (minutes).

  • C-minutes

    Specify the next delayed end time by the relative minutes from the time when the jobnet starts to be executed.

    You can specify a value between 1 (or 01) and 2,879 (minutes).

-f {none|minutes}

Specify the end delay monitoring time using the time required to execute the next jobnet or remote jobnet.

You cannot specify this option for a job.

  • none

    Does not monitor the delayed end based on the time required for execution.

  • minutes

    Monitors the delayed end based on the time required for execution.

    You can specify a value between 1 (or 01) and 2,879 minutes.

-B execution-registration-number

Specify the execution registration number of a jobnet whose next execution schedule is to be changed temporarily, in the YYYYMMDDNNN format. The meaning of YYYYMMDDNNN is as follows:

YYYY: Year of the scheduled date of execution

MM: Month of the scheduled date of execution

DD: Day of the scheduled date of execution

NNN: Execution registration sequence number for the scheduled date of execution

For details of the execution registration number, see 4.5.13 Methods of specifying generations when executing commands in the manual JP1/Automatic Job Management System 3 Overview.

-j

Invalidates start conditions set for a jobnet.

You can specify this option only in the root jobnet. You cannot specify this option with the -m or -k option.

-m {hours:minutes|M-minutes|unlimited}

Specify the wait time until start conditions are met.

You can specify this option only for the root jobnet. Specify this option with the -k option. You cannot specify it with the -w or -j option.

  • hour:minutes

    Specify the wait time by the absolute time.

    You can specify a value between 0 (or 00) and 47 for the hours.

    You can specify a value between 0 (or 00) and 59 for the minutes.

  • M-minutes

    Specify the wait time by relative minutes from the time when the jobnet starts to be executed.

    You can specify a value between 1 (or 01) and 2,879 (minutes).

  • unlimited

    Waits for an unlimited period of time until the conditions are met.

-k {number-of-times|unlimited}

Specify the number of times the system waits for start conditions to be met.

You can specify this option only in the root jobnet. Specify this option with the -m option. You cannot specify it with the -w or -j option.

  • number-of-times

    You can specify a value between 1 and 999 (times).

  • unlimited

    Sets an unlimited number of times for waiting until the conditions are met.

-l {y|n}

Specify this option to temporarily change the execution order control method only if execution order control is enabled in the unit definition for a root jobnet or planning group.

  • y: The execution order is synchronous with the jobnet connector.

  • n: The execution order is asynchronous with the jobnet connector.

You can specify this option for only a jobnet or planning group to which a jobnet connector is connected.

-xw {enable|disable}

Specify this option to temporarily enable or disable a wait condition assigned to a job or jobnet.

  • enable

    Enables the wait condition.

  • disable

    Disables the wait condition.

You can specify this option only for units with wait conditions.

Use this option together with the -xn option. The -xn option specifies the unit whose end is being waited for to which the change applies.

This feature is only available when the database uses a standard configuration.

You cannot specify multiple -xw options. Execute the command multiple times if you want to operate on multiple units with wait conditions.

You cannot specify this option with options other than -R, -E, -T, -N, -J, -B, -X, or -F.

-xn unit-whose-end-is-being-waited-for

Specify the name of the unit whose end is being waited for by the job or jobnet whose wait condition you want to enable or disable by the -xw option. Note that if you specify only the unit name, the AJSPATH environment variable does not supply the rest of the path.

Specify this option together with the -xw option.

This feature is only available when the database uses a standard configuration.

You can specify a character string of 1 to 930 bytes as the name of the unit whose end is being waited for. You can also use regular expressions.

You cannot specify multiple -xn options. To modify a wait condition targeting multiple units whose ends are being waited for, either execute the command multiple times or use regular expressions to specify the unit names. If you use a regular expression, the command enables or disables the wait conditions for all units whose ends are being waited for that match the regular expression.

You cannot specify this option with options other than -R, -E, -T, -N, -J, -B, -X, or -F.

An error occurs when:

  • You specify a nonexistent unit whose end is being waited for

  • You specify a unit that is not assigned a wait condition

  • The unit whose end is being waited for is deleted while the command is executing

  • No units whose ends are being waited for match the regular expression

-R

Temporarily changes all the jobnets and jobs contained in the specified unit.

If you specify this option with the -E, -T, -N, and/or -J options, the system temporarily changes the jobnets or jobs according to the specification of each option.

-E

Temporarily changes the schedule of a jobnet registered for execution.

-T

Temporarily changes the schedule of the root jobnet.

-N

Temporarily changes the schedules of all jobnets.

You cannot specify this option with the -J option.

-J

Temporarily changes the job status.

You cannot specify this option with the -N option.

-X {yes|no|auto}

Specify whether to automatically select the current unit for operation from the units listed in a planning group. The units in the job group are not, however, automatically selected regardless of the specified value. You cannot omit a root jobnet name.

  • yes

    Specify this to automatically select a target unit.

    When specifying a unit name in the command, omit a root jobnet name in a planning group.

  • no

    Specify this if you do not want to automatically select a target unit.

    You must specify a unit for which the command will operate. You cannot omit a root jobnet name in a planning group.

  • auto

    Whether a target unit will automatically be selected depends on how the unit name is specified.

    • If you want to automatically select a target unit

      Specify a unit name without a root jobnet name in a planning group.

    • If you do not want to automatically select a target unit

      Specify a unit name with a root jobnet name in a planning group. The command will operate for the specified unit only. However, if there is a unit having the same name as the path name specified without a root jobnet name in a planning group, a root jobnet name is assumed to be omitted so that a target unit will be selected automatically.

job-name-or-jobnet-name-or-job-group-name

Specify the name of the job or jobnet whose schedule or status you want to temporarily change. You can also specify a job, jobnet, or job group name with the -R, -N, -E, or -T option.

You can specify a character string of 1 to 930 bytes.

You can specify more than one job, jobnet, or job group names. You cannot specify a manager job group name or manager jobnet name.

You can specify a logical host name or execution ID as a job, jobnet or job group name. If you specify an execution ID, however, the -B option is disabled. For details about how to specify the execution ID, see 1.1 Command syntax.

Notes

Return values

0

Normal end

Multiple of 4 within the range from 4 to 124

Abnormal end

Additional information

When yes is specified for the -X option

When specifying a unit name in the command, omit a root jobnet name in a planning group.

This causes the command to automatically select the current unit for operation from the root jobnets in the planning group.

Example: Specifying /net1 for a unit name
ajsplan  -h -X yes /net1
Explanation:

In this case, the command automatically selects the current unit for operation from /net1/net1-1 and /net1/net1-2.

For units under root jobnets in the planning group, the command selects the current unit for operation from the units having the same path name under a root jobnet.

Example: Specifying /net1/job1 for a unit name
ajsplan  -h -X yes /net1/job1
Explanation:

In this case, the command automatically selects the current unit for operation from /net1/net1-1/job1 and /net1/net1-2/job1.

When no is specified for the -X option

Specify a unit name in the planning group without omitting a root jobnet name.

Example: Specifying /net1/net1-1/job1 for a unit name
ajsplan  -h -X no /net1/net1-1/job1
Explanation:

In this case, the command operates for the specified unit /net1/net1-1/job1.

When auto is specified for the -X option

Whether a target unit will automatically be selected depends on how the unit name is specified.

If you want to automatically select a target unit

The specification format is the same as that used when yes is specified for the -X option.

If the command cannot find a unit having the path name with a root jobnet name omitted in the planning group, however, it assumes that you specified the unit name without omitting a root jobnet name and operates for the specified unit.

Example 1: Specifying /net1 for a unit name
ajsplan  -h -X auto /net1
Explanation:

In this case, the command assumes that a unit name is omitted, and automatically selects the current unit for operation from /net1/net1-1 and /net1/net1-2.

Example 2: Specifying /net1/net1-2 for a unit name
ajsplan -h -X auto /net1/net1-2
Explanation:

In this case, the command assumes that a unit name is omitted, and automatically selects the current unit for operation from /net1/net1-1/net1-2 and /net1/net1-2/net1-2.

If you want to execute the command for /net1/net1-2, specify either of the following:

  • Specify no for the -X option.

  • Specify NO for the AJSAUTOJUDGE environment variable without specifying the -X option.

If you do not want to automatically select a target unit

The specification format is the same as that used when no is specified for the -X option. However, if there is a unit having the same name as the path name specified without the root jobnet name in the planning group, the root jobnet name is assumed to be omitted so that a target unit will be selected automatically.

Example: Specifying /net1/net1-1 for a unit name
ajsplan -h -X auto /net1/net1-1
Explanation:

In this case, the command attempts to operate assuming that a unit name is omitted. There is, however, no unit having the unit name without a root jobnet in the planning group, so that the command operates for /net1/net1-1.

When -X option is not specified

According to the value specified in the AJSAUTOJUDGE environment variable, the command determines the target unit in the planning group.

  • AJSAUTOJUDGE is set to YES.

    The specification format is the same as that used when yes is specified for the -X option.

  • AJSAUTOJUDGE is set to NO.

    The specification format is the same as that used when no is specified for the -X option.

  • AJSAUTOJUDGE is set to AUTO or not set

    The specification format is the same as that used when auto is specified for the -X option.

Example 1

The following command temporarily changes the start time of the jobnet net1 to 17:00.

ajsplan -t 17:00 net1

Example 2

The following command temporarily stops the unit with wait conditions, job1 (/RootJobNet1/job1), from waiting for the unit whose end is being waited for, job2 (/RootJobNet2/job2).

ajsplan -xw disable -xn /RootJobNet2/job2 /RootJobNet1/job1

To disable all wait conditions for job1 (/RootJobNet1/job1), execute the command as follows:

ajsplan -xw disable -xn * /RootJobNet1/job1