My Task Monitor (TASKMON)

First off, if you are running a Turnkey 3 system with BSPPILOT then you probably don't want this. As BSPPILOT already does a much better job of system startup and shutdown you need to stick with that if you are already using it.

If you don't use BSPPILOT this may be of use if you havn't already written your own.

Note: there will be no maintenance/fixes for this, I no longer use it as I have merged the moinitor/start function into My MMPF automation utility instead.

Purpose and operation of program

Runs as a started task to periodically checks to see that started tasks are in the state they are supposed to be in, which may be either up or down (yes, can be prefered down).

It supports the following operator commands

TASKMON card image rules



Card deck rules

Any line with a * in position 1 is a comment line, the actual data card rules are

  1. columns 1 to 8, the STC jobname to monitor
  2. column 10, the desired task state, U or D (up or down)
  3. column 12, what to do if the task is nor running, C or M (issue a Command or Message)
  4. column 14, determines if it is to be processed by a killall request (K is yes, anything else no)
  5. columns 20 to 49, the job start command or NOP
  6. columns 50 to 69, the job stop command or NOP
  7. columns 70 to 80, reserved at this time


Card deck example

*---+----1----+----2----+----3----+----4----+----5----+----6----+----7
JES2     U C       S JES2,PARM='WARM,NOREQ'      $PJES2
MMPF     U C       S MMPF                        P MMPF
TSO      U C K     S TSO                         P TSO
NET      U C K     S NET                         Z NET,QUICK
MF1      U C K     S MF1                         P MF1 
FRED     U M       NOP                           NOP

JCL to run this job

This JCL should be placed into one of you system procedure libraries so you can 'S TASKMON' it.

//TASKMON  PROC MEMBER=TASKMON
//TASKMON  EXEC PGM=TASKMON
//STEPLIB  DD   DSN=SYS9.LINKLIB.APFAUTH,DISP=SHR    <== change dsn
//STCLIST  DD   DSN=SYS9.CONTROL(&MEMBER),DISP=SHR   <== change dsn

Current Limitations

As coded it allows a maximum of 20 started tasks to be monitored (I only have 5 so havn't increased it), there are a few constants coded to be changed if you want to increase that. Theoretically (if my multiplication is correct) now I have moved the card rules into a separate DSECT you can use up to 58 rules with no more effort than changing the constants; any more than that and you will need to manage another DSECT. The comments at the top of the code explain what to change if you need more.

Read this far, you probably want it then

The job to assemble TASKMON is available here. Remember to change the dataset name for the library it is to be assembled into.

Change History