ALTJOB

Generated from C.65.00 /SYSADMIN/PUB/MYCICAT last modified on Sun Aug 29 15:08:37 2004

Back to Main Index


ALTJOB


     Alters the attributes of waiting or scheduled jobs.

SYNTAX


     ALTJOB [JOB=] {#Jnnn}
                   {#Snnn}

            [[;INPRI=]inputpriority]

            [[;OUTDEV=]{ldev    }]
                       {devclass}

            [;JOBQ=queuename]

            [;HIPRI]


PARAMETERS


#Jnnn               A job number.

#Snnn               A session number. (Although syntactically
                    correct, this parameter is rarely used
                    sessions do not wait.)

inputpriority       Specifies the new input priority ( 0 = lowest;
                    14 = highest).

ldev or devclass    Specifies the logical device number or device
                    class name of the destination device job's
                    $STDLIST.

queuename           Name of the job queue into which the job is to be
                    moved.

HIPRI               The HIPRI option is used for two different
                    purposes when altering a job's priority.  It can be
                    used to override the system jobfence, or it can be
                    used to override the job limit.  When using the
                    HIPRI option to override the jobfence/joblimit, the
                    system will first check to see if you have system
                    manager (SM) or system operator (OP) capability.
                    Use of the HIPRI option without SM or OP capability
                    causes the following warning to be displayed:

                    MUST HAVE 'SM' OR 'OP' CAP. TO SPECIFY HIPRI,
                    MAXIMUM INPRI OF 13 IS USED (CIWARN 1460)



OPERATION


     The ALTJOB command, in conjunction with the JOBFENCE
     command, allows you to control the flow of all jobs on the
     system with the exception of HIPRI jobs.  It can be used to
     alter only jobs in the INTRO and WAIT, or SCHED state.  Jobs
     with input priority less than or equal to the current
     JOBFENCE, a numerical value from 0 to 14, will be deferred.
     When HIPRI option is used the job will be put in EXEC state,
     irrespective of the value of JOBFENCE or JOBLIMIT.  If both
     INPRI parameter and HIPRI option are used, the following error
     message will be displayed:

     The INPRI and HIPRI parameters may not be specified
     together. (CIERR 12266)

     User can move jobs waiting or executing in a queue to other
     queues by using the ;JOBQ parameter. User must have System
     Manager (SM) or Operator (OP) capability to move jobs.

     When an executing job is moved, the limit of the target queue
     is ignored and the job continues to execute in the new queue.
     A waiting job continues to wait in the new queue if queue has
     already reached its limits.

     This command may be issued from a session, job, program or in
     BREAK. Pressing [Break] has no effect on this command.  Users
     may execute ALTJOB to change their own jobs.  To change
     other users' jobs, the command must be issued from the
     console unless it has been distributed to users with the ALLOW
     command, or if JOBSECURITY is set LOW.


EXAMPLE(S)


     Consider three jobs that are submitted by a user and suppose
     that all of these jobs have an INPRI value of 8.  To change
     their INPRI values to ensure that JOB1 runs first, JOB2 runs
     last, and JOB3 runs second with LP allocated as the OUTDEV
     for JOB3, enter the following commands

JOBFENCE 14
1511/#J1/24/DEFERRED JOB INTRODUCED ON LDEV #53  ** Prevents all   **
1511/#J2/25/DEFERRED JOB INTRODUCED ON LDEV #53  ** jobs from      **
1513/#J3/26/DEFERRED JOB INTRODUCED ON LDEV #53  ** running while  **
                                                 ** the user       **
                                                 ** changes the    **
                                                 ** INPRI values.  **

SHOWJOB


JOBNUM   STATE  IPRI  JIN   JLIST  INTRODUCED  JOB NAME

#S23     EXEC          20   20     THU  215P   OPERATOR.SYS
#J1      WAIT    D 8   10S  12     THU  311P   JOB2,OPERATOR.SYS
#J2      WAIT    D 8   10S  12     THU  311P   JOB3,SARAH.PAYROLL
#J3      WAIT    D 8   10S  12     THU  313P   JOB1,JOHN.ACCTNG

4 JOBS
0 INTRO

3 WAIT; INCL 3 DEFERRED
1 EXEC; INCL 1 SESSIONS
0 SUSP
JOBFENCE= 14; JLIMIT= 5; SLIMIT= 16

ALTJOB #J1;INPRI=10
ALTJOB #J3;INPRI=9;OUTDEV=LP
ALTJOB #J2;INPRI=8
JOBFENCE 6                  ** Resets the jobfence to 6 **

SHOWJOB


JOBNUM   STATE  IPRI  JIN   JLIST  INTRODUCED  JOB NAME

#S23     EXEC          20   20     THU  215P   OPERATOR.SYS
#J1      WAIT    D10   10S  12     THU  313P   JOB1,JOHN.ACCTNG
#J3      WAIT    D 9   10S  12     THU  311P   JOB2,OPERATOR.SYS
#J2      WAIT    D 8   10S  LP     THU  311P   JOB3,SARAH.PAYROLL

4 JOBS
     0 INTRO
     3 WAIT; INCL 3 DEFERRED
     1 EXEC; INCL 1 SESSIONS
     0 SUSP
JOBFENCE= 6; JLIMIT= 5; SLIMIT= 16

The sequence above first sets the jobfence to 14 to prevent all jobs
from running.  Then the priority of each of the three jobs is changed
to run in the desired sequence (with J# sent to the LP).  Lastly, the
jobfence is reset to 6 to allow all jobs with an input priority of 7
(or above) to run.



     Consider two jobs, JOB1 and JOB2, executing on the queues
     HPSYSJQ and SYSMGRQ respectively.

SHOWJOB;JOBQ

JOBNUM  STATE IPRI JIN  JLIST JOBQ     INTRODUCED  JOB NAME

#J3     EXEC        20  LP    HPSYSJQ  WED 11:46A  JOB1,OPERATOR.SYS
#J7     EXEC         3  LP    SYSMGRQ  WED  5:47P  EMG,MGR.SYSMGR


    To move the job #J7 to the queue HPSYSJQ, enter

    ALTJOB #J7;JOBQ=HPSYSJQ

SHOWJOB;JOBQ

JOBNUM  STATE IPRI JIN  JLIST JOBQ     INTRODUCED  JOB NAME

#J3     EXEC        20  LP    HPSYSJQ  WED 11:46A  JOB1,OPERATOR.SYS
#J7     EXEC         3  LP    HPSYSJQ  WED  5:47P  EMG,MGR.SYSMGR

ADDITIONAL INFORMATION


Commands:  JOBFENCE

Manuals :  Performing System Operation Tasks (32650-90137)

Back to Main Index