$H Job - Hold specific jobs

Function

To place specific jobs in hold status.

Syntax

Read syntax diagramSkip visual syntax diagram$H JobJOBQJQStcTsu nn-mm*'job'(,nn*-mm*job'job') ,/CMDauth=^=cmdauth(,cmdauth),/Age/DAys><days,/Hours><hours,/JOBGROUP=^=><jobgroupname,/JM/JOBMASK=^=><jobmask,/Queue=^=CNVINPUTOUTPPUPURGERCVSETUPSPINXEQXMT,/REBUILD=^=NoYes,/SPL/SPOOL=(,/%/Percent><percent/Tgs><tgs/Volumes=^=volume(,volume)),/TYPE=^=JOBSTCTSU,BUSY=YESANYNONONE,CARDS,Class,OFFS,Priority,SCHENV,SCHENV_AFF,SECLABEL,SECLABEL_AFF,SRVCLASS/Sysaff=memnameANYIND(memnameANY,=^=memnameANYIND3),USERID,/XEQNode=^=xeqnodeSelection limiting keywords
Selection limiting keywords
Read syntax diagramSkip visual syntax diagram,/JC/JOBCORR=^=><job correlator,/XEQHours><hours
Notes:
  • 1 cmdauth can be coded up to 2 times
  • 2 volume can be coded up to 253 times
  • 3 Multiple Sysaff values can be coded up to 33 times

Parameters

Age|DAys<days | Age|DAys>days
Specifies the age of affected jobs in days. Only jobs more (with DAYS>nn) or less (with DAYS<nn) than the specified number of days in age are affected. The days are counted from the current hour.
Age is computed by subtracting the job's "begin time" from the current time. That is, the time that the job was initially added to its current queue is the "begin time" except:
  • The "begin time" for jobs that are actively running is the same as the time the command was entered. That is, the age for running jobs is always zero days and hours.
  • The "begin time" for jobs in the OUTPUT or HARDCPY queue is the time that the job ended execution. If the job does not run, then the time is the time that the job was placed in its prior queue.
BUSY=
Specifies one of the following:
  • The system name or number on which the job is busy. Note that you can specify a value of 0 to indicate that the job is not busy. You can also specify values above 32 to match systems with invalid values in the BUSY value (for example, $HJOBQ,BUSY>32)
  • YES or ANY, indicating that all busy jobs are to match
  • NO or NONE, indicating that all non-busy jobs are to match
CARDS=cards
Specifies the number of input cards associated with the job.
Class=class
Specifies a job class used to select a subset of jobs that have a matching job class. Wildcard characters can also be specified: see Using wildcards for details.
CMDauth=(auth1{,auth2})
Only the jobs that can be affected from the specified remote(s) or node(s) are held. The valid specifications are:
LOCAL|ANYLOCAL
Only the local devices at the local node can affect the output.
Nnnnn|nodename
Only local devices at the specified node can affect the output.
Rnnnn
Only the specified remote device can affect the output.
NnnnnRnnnn|nodename.Rnnnn
Only the specified remote device at the specified remote node can affect the output.
destid
A destid corresponding to any of the above remote devices.
Note: Specification of the CMDAUTH filter does not override the authority of the console from which the command is issued; both the authority of the console and the specified CMDAUTH filter must match for the job to be affected.
Hours=hours
Specifies the age of affected jobs in hours. Only jobs more (with HOURS>nn) or less (with HOURS<nn) than the specified number of hours in age are affected.
JC|JOBCORR=job correlator
Specifies a combination of 1-64 alphanumeric, special (colon, period or underscore) and wildcard characters that can be used to select a subset of jobs that have a matching job correlator. For a description of wildcard characters, refer to Using wildcards.
JOBGROUP=jobgroupname
Specifies 1 to 8 alphanumeric, special ($, #, or @) or wildcard characters (or a combination of them) that can be used to select a subset of jobs whose job group name matches this combination of characters (mask).
JM|JOBMASK=jobmask
Specifies 1 to 8 alphanumeric, special ($, #, or @) or wildcard characters (or a combination of them) that can be used to select a subset of jobs whose job name matches this combination of characters (mask). For a description of wild cards, see Using wildcards.
Note:
  1. This is a positional parameter. Specify this following the job_id (JOB, STC, or TSU), or JOBQ parameter.
  2. The JOBMASK parameter is not valid with the ‘jobname ' parameter.
job
Specifies 1 to 8 alphanumeric, special ($, #, or @) or wildcard characters (or a combination of them) that can be used to select a subset of jobs whose job name matches this combination of characters (mask).
‘job'
The name of the job that is held. This name must appear as coded on the JOB statement and must be enclosed in apostrophes. If more than one job exists with this name, no action is taken.
Job
A Batch job or range of batch jobs is to be held.
JOBQ|JQ
Specifies all jobs, STCs, and TSUs across the MAS for processing.
OFFS=offs
Specifies offload device numbers on which the job has been archived.
Priority=priority
Specifies the priority of the job.
Queue={CNV|INPUT|OUT|PPU|PURGE|RCV| SETUP|SPIN|XEQ|XMT}
Only jobs on the specified job queue are to be held.
CNV
Only jobs awaiting conversion are to be held.
INPUT
Only jobs on the JES2 $INPUT queue are to be held.
OUT
Only jobs awaiting output processing are to be held.
PPU
Only jobs awaiting print/punch processing are to be held.
PURGE
Only jobs awaiting purge processing are to be held.
RCV
Only jobs on the JES2 $RECEIVE queue are to be held.
SETUP
Only jobs on the JES2 $SETUP queue are to be held.
SPIN
Only jobs awaiting spin processing are to be held.
XEQ
Only jobs awaiting execution are to be held.
XMT
Only jobs queued for network transmission are to be held.
REBUILD={No|Yes}
Jobs on the rebuild queue are to be held (Yes) or not held (No).
SCHENV=schenv
Specifies the scheduling environment associated with the job.
SCHENV_AFF=member
Specifies the JES2 MAS members on which the scheduling environment for this job is available.
SECLABEL_AFF=member
Specifies the JES2 MAS members on which the SECLABEL for this job is available but only if the RACF® SECLABEL_BY_SYS is also active.
SECLABEL=seclabel
Specifies the security label associated with the job.
SPL|SPOOL={Percent|%|Tgs|Volumes}
Only jobs with specific SPOOL characteristics are to be held:
Percent|%
Only jobs using more (with %>nn) or less (with %<nn) than the specified percentage of the total available spool space are to be held.
Tgs
Only jobs using more (with Tgs>nn) or less (with Tgs<nn) than the specified number of track groups are to be held.
Volumes=(v1,v2,...)
Only jobs which have allocated spool space on the specified spool volume(s) are to be held.
SRVCLASS=srvclass
Specifies the service class of the job. The service class is available for batch jobs only. It is not available for started tasks or time-sharing users. The default workload manager (WLM) policy assigns a service class of blanks to all jobs, and WLM-managed initiators can then select such jobs for processing.
Stc
A started task or range of started tasks is to be held.
Sysaff
Specifies jobs to process based on this system affinity. Up to 33 entries can be coded by using a combination of the following values:
memname
Specifies the identifier (1 to 4 characters using A-Z, 0-9, $, #, and @) of a member in the JES2 multi-access spool configuration that a job has in its system affinity list.
ANY
Specifies jobs that are eligible to run on any member in the JES2 multi-access spool configuration. If you specify ANY followed by the IND parameter, they must be separated by a comma and the list must be enclosed in parentheses, for example, (ANY,IND).
IND
Specifies the job that is selected and must be executed on a processor operating in independent mode.
Tsu
A time-sharing user or range of time-sharing users is to be held.
TYPE={JOB|STC|TSU}
Indicates whether only batch jobs (JOB), started tasks (STC), or time-sharing users (TSU) are to be held.
USERID=userid
Specifies the user ID associated with the job.
XEQHours=hours
Specifies the number of hours that a job has been executing. Only jobs that run more (with XEQH>nn) or less (with XEQH<nn) than the specified number of hours are affected, with the restriction that requires that the jobs must be executing.
XEQNode=xeqnode
Only jobs that are destined to execute at the specified node, or that have already executed at the specified node, are to be held. The node name may be specified using the decimal node number (Nnnnnn) or an EBCDIC node name.

Related Commands

To hold entire job classes, or all jobs, see the $A Job, $H A, or $T JOBCLASS commands.

Authority Required

This command requires job authority. The description of the $T RDRnn command explains how to ensure that the authority of the appropriate MVS™ system command group is assigned.

This command requires update security access authority. For a description of assigning command input authority, see z/OS JES2 Initialization and Tuning Guide.

Processing considerations

When a job is restarted using the automatic restart management. The hold status of the job is carried over to the restarted job.

If a $H command is issued against a job that is currently in executing status, the HOLD process is honored when the job completes execution, that is when control of the job is returned to JES2. The job is immediately held, just before the OUTPUT phase. Because the job has not completed the OUTPUT phase, the spool files that are created by the job are not collected into Output Groups and are not available for printing, NJE, and so on. A release command ($AJ) removes the hold status and cause the job to complete the OUTPUT phase and move into the final HARDCOPY phase.

Scope

MAS-wide. This command has an effect across the entire MAS.

Messages

The $HASP890 message displays the current status of the indicated job.

Examples

 1   $h j34-36

  JOB00034  $HASP890 JOB(TESTA)
  $HASP890 JOB(TESTA)     STATUS=(AWAITING XMITTER N2),CLASS=A,
  $HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)
  JOB00035  $HASP890 JOB(HOLDJOB)
  $HASP890 JOB(HOLDJOB)   STATUS=(AWAITING EXECUTION),CLASS=H,
  $HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)
  JOB00036  $HASP890 JOB(SPINTWO)
  $HASP890 JOB(SPINTWO)   STATUS=(AWAITING EXECUTION),CLASS=A,
  $HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)
JES2 places batch jobs 34, 35, and 36 in hold status.
 2   $h j100-105,jm=?ebg*

  JOB00100  $HASP890 JOB(IEBGENER)
  $HASP890 JOB(IEBGENER)  STATUS=(AWAITING HARDCOPY),CLASS=A,
  $HASP890                PRIORITY=1,SYSAFF=(ANY),HOLD=(JOB)
  JOB00102  $HASP890 JOB(IEBGENEZ)
  $HASP890 JOB(IEBGENEZ)  STATUS=(AWAITING EXECUTION),CLASS=B,
  $HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)
  JOB00103  $HASP890 JOB(IEBGENEY)
  $HASP890 JOB(IEBGENEY)  STATUS=(AWAITING EXECUTION),CLASS=B,
  $HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)
JES2 places batch jobs in hold status that fall in the range of 100 through 105, and whose job name includes EBG as the second, third and fourth characters.
 3   $h jq,jm=ib*,q=xeq

  JOB00102  $HASP890 JOB(IBMUSERX)
  $HASP890 JOB(IBMUSERX)  STATUS=(AWAITING EXECUTION),CLASS=B,
  $HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)
  JOB00103  $HASP890 JOB(IBMUSERY)
  $HASP890 JOB(IBMUSERY)  STATUS=(AWAITING EXECUTION),CLASS=B,
  $HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)

JES2 places all batch jobs, STCs, and TSUs whose job name begins with the characters IB that are on the execution queue in hold status.

 4  $hj(*),jc=*:*overnightjob*

JOB00131  $HASP890 JOB(LATERUN1)                                        C
$HASP890 JOB(LATERUN1)  STATUS=(AWAITING EXECUTION),CLASS=A,             
$HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)               
JOB00132  $HASP890 JOB(BACKUP)                                          C
$HASP890 JOB(BACKUP)    STATUS=(AWAITING EXECUTION),CLASS=A,             
$HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)               
JOB00133  $HASP890 JOB(ENDOFDAY)                                        C
$HASP890 JOB(ENDOFDAY)  STATUS=(AWAITING EXECUTION),CLASS=A,             
$HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)               
JOB00134  $HASP890 JOB(D15USER4)                                        C
$HASP890 JOB(D15USER4)  STATUS=(AWAITING EXECUTION),CLASS=A,             
$HASP890                PRIORITY=9,SYSAFF=(ANY),HOLD=(JOB)               

JES2 places in hold status any batch job with a job correlator user portion containing OVERNIGHTJOB.