AUTOSTAT (Report on MUF Information)

The AUTOSTAT function creates a Snapshot of selected MUFs with their active tasks.
datacom
The AUTOSTAT function creates a Snapshot of selected MUFs with their active tasks.
This function opens the AutoStatus database in the repository MUF using the standard DBSIDPR connection and then calls an internal API to collect information about the tasks running on one or more target MUFs in this same LPAR. The repository MUF can also be a target MUF.
To execute AutoStatus, the repository MUF must be at 
Datacom/DB
 Version 14.0. AutoStatus allows a target MUF to be 
Datacom/DB
 r11 or greater.
The AutoStatus database is installed as part of a new install or upgrade. The default database ID is 1018. If you decide to change the AutoStatus database to a different DBID, we recommend that the database be left as 1018.
The process allows a single Snapshot to collect information about up to 100 active MUFs in the targeted LPAR. Since AutoStatus uses the standard DBSIDPR to communicate to the repository MUF, the repository MUF can be on a different LPAR (assuming that you have the cross LPAR communication set-up in the repository MUF).
When more than one MUF is selected as a target for an AutoStatus Snapshot, the data is collected from the target MUFs in serial fashion in alphabetic order. For AutoStatus executions that have a significant number of MUFs, the actual process may run for a few seconds. To view all of this information as a single rowset, the same timestamp is loaded into each record recorded by this Snapshot (S_MUF_DATETIME).
For more information about how to implement and use AutoStatus, see the Autoscope user documentation.
This page discusses the following topics:
 
 
When to Use AUTOSTAT
Use the AUTOSTAT function when you want to create a Snapshot of selected MUFs with their active task information so that you can process the information and analyze the results. The data is saved in the AutoStatus database.
How to Use AUTOSTAT
Use the following syntax to write this command.
┌─ , ───────────────┐ ►►─ AUTOSTAT ─▼─ MUFNAME=
mufname
─┴─┬───────────────────────┬─────────────────► └─ ,DBID= ─┬─ 1018 ◄ ─┬─┘ └─
nnnn
───┘ ┌───────────────────────────────────┐ ►─┬──────────────────────────────┬─▼─┬───────────────────────────────┬─┴─────► └─ ,REPEATS= ─┬─ 0 ◄ ────────┬─┘ └─ ,SNAPEXCL= ─┬─ DURATION0 ──┬─┘ └─ 3 to 64800 ─┘ ├─ HEADER ─────┤ ├─ NOTACTIVE ──┤ ├─ REPCONNECT ─┤ └─ WARNMSG ────┘ ►─┬────────────────────────────┬─────────────────────────────────────────────►◄ └─ ,OUTTAG=
cccccccccccccccc
─┘
 
Command
 
  •  
    AUTOSTAT
    Invokes the AUTOSTAT function. Specifies to create a Snapshot of the specified MUFs with their active tasks.
 
Required Keyword
 
  •  
    MUFNAME=
    Identifies the MUF from which the task data is retrieved. You can repeat this parameter to include more than one MUF. Alternately, you can use a wild card character (*) to specify to select all MUFs whose names begin with the characters you specify.
    •  
      Valid Entries:
      The MUF name or beginning portion of a mufname with an asterisk (*)
    •  
      Default Value:
      (No default)
 
Optional Keywords
 
  •  
    DBID=
    Specifies the database ID of the database where the Snapshot rowset is recorded.
    •  
      Valid Entries:
      1 to 5000
    •  
      Default Value:
      1018
  •  
    OUTTAG=
    Specifies a 1- to 16-character string that is used to fill in the USERTAG column on each row in the table. You can use this in various ways. For example, if you are collecting status information from multiple LPARs, you can indicate the LPAR where a given status was collected. In another case, you can process the status rows with your own program and, once a row has been read, you could place a value in the USERTAG column to indicate it has been processed.
    •  
      Valid Entries:
      1 to 16 characters
    •  
      Default Value:
      Blanks
  •  
    REPEATS=
    Specifies whether the AutoStatus function should remain active and perform periodic Snapshots (until stopped by the user). A value of zero indicates that the function should run only once and then end. A numeric value between 3 and 64800 indicates that the function should remain active and the interval between the Snapshots will be set equal to the selected value in seconds. The interval is measured as the time from the end of one Snapshot and the beginning of the next Snapshot. You may want to set the parameter to a sufficient value, such as 600 (10 minutes), to keep the function from generating large numbers of rows in the AutoStatus database. If you are setting a repeats value, you need to set-up the appropriate job parameters to keep the system from canceling the job due to long execution times.
    •  
      Valid Entries:
      0 for none or from 3 to 64800
    •  
      Default Value:
      0 (Indicates that the function should not repeat)
  •  
    SNAPEXCL=
    Specifies the items to exclude.
    •  
      DURATION0
      Suppresses the creation of any detail task rows that have a DURATION of blanks. During the task inquiry, any task that has not had a given command in process for at least one second has a duration of blanks. This parameter is used to reduce the amount of detail task rows that are written to the AUTOSTAT database. With this option in place, only tasks with a command in process for a duration of one second (:01) or greater are written to the SNAPSHOT database.
    •  
      HEADER
      Suppresses the writing of a new page header as each SYSPRINT page fills. When you want to keep the SYSPRINT to a minimum, you can use this option.
    •  
      NOTACTIVE
      Suppresses the creation of any detail task rows that have a CURRENT_STATUS of NOTACTIVE. This parameter is used to reduce the amount of detail task rows that are written to the AUTOSTAT database.
    •  
      REPCONNECT
      Suppresses the open and close of the AUTOSTAT database URT for each Snapshot (see REPEATS). Specifying SNAPEXCL=REPCONNECT tells the utility to open the URT at the beginning of the AUTOSTAT function and to leave it open until the function is ended. In this mode, the AUTOSTAT function will issue a COMMIT at the end of each Snapshot process, but not close the URT.
      Without the SNAPEXCL=REPCONNECT, the AUTOSTAT function disconnects from the repository MUF after each status Snapshot. Then, just prior to the next Snapshot, the function re-opens the URT and re-establishes communication to the repository MUF. This ensures that the URT does not remain open for long periods of time while the function is in a "wait" between Snapshots. When you want to limit the amount of opens and closes, and the associated messages in the repository MUF region, you should specify the SNAPEXCL=REPCONNECT option.
       With the SNAPEXCL=REPCONNECT option specified, you must terminate AUTOSTAT before issuing the EOJ to the repository MUF.
    •  
      WARNMSG
      Suppresses the creation of warning messages when specified MUFs are not found (not active) when the status Snapshot is executed.
    •  
      Valid Entries:
      DURATION0, HEADER, NOTACTIVE, REPCONNECT, WARNMSG
    •  
      Default Value:
      Do not exclude
Console Commands (AUTOSTAT)
When you specify a REPEATS= value, AUTOSTAT attaches a console subtask to allow you to communicate to AUTOSTAT while it is executing.
Any console command that changes an operational parameter except REPEATS, such as EXCLUDE DURATION0, will go into effect at the next processing cycle.
For example, if the task is running with REPEATS=600 (10 minutes), and you issue the console command EXCLUDE DURATION0, the change will be made in the operational parameters, but it will not take effect until the next Snapshot process. Issuing the REPEATS command changes the current operational value for the REPEATS parameter and also triggers an immediate Snapshot to be taken.
When you have a long REPEATS value, the console interaction allows you to make the change and also force an immediate Snapshot. In cases, where you want to force a Snapshot without changing the overall operational parameters, you can do this by just issuing the REPEATS command with a value equal to the current REPEATS value.
Issuing the AS_OPTIONS command does not change any operational values or trigger a Snapshot. AS_OPTIONS only requests that the current operational values are printed to SYSPRINT for review purposes.
Console interaction is provided through the following /STOP, /CANCEL, and /MODIFY processes.
  •  
    /STOP 
    jobname
     
    Terminates the AUTOSTAT task. The process is the same as the following /MODIFY 
    jobname
    ,EOJ process.
  •  
    /CANCEL 
    jobname
     
    Causes the AUTOSTAT task to be canceled with a S222 abend.
  •  
    /MODIFY 
    jobname,command
     
    Issues changes using a specific command format as documented in the following section. It allows you to pass information to the active AUTOSTAT task.
MODIFY Command Format
The MODIFY command has the following format:
►►─ /MODIFY ─
jobname,command
────────────────────────────────────────────────►◄
The jobname is the name of the AUTOSTAT job and command is the action to be taken and value is the optional value supplied to the command. There must only be a comma separating the jobname and the command and there must be a space separating the command and the value, if specified.
Console commands will be echoed to the SYSPRINT output.
 
Command
 
  •  
    ADDMUF 
    newmuf
     
    Add the new MUFNAME to the list of MUFs that are being targeted for the status Snapshots. 
    newmuf
     is 1 to 8 alphanumeric characters.
     There is a limit of 100 MUFNAMEs per AUTOSTAT execution.
  •  
    AS_OPTIONS
    Produces a listing of all AUTOSTAT options in effect to the SYSPRINT output.
  •  
    COMM EOJ
    Same as EOJ.
  •  
    EOJ
    Complete current Snapshot, set return code, and terminate the AUTOSTAT program.
  •  
    EXCLUDE DURATION0
    Excludes tasks that have a "blank" duration.
  •  
    EXCLUDE HEADER
    Tells the utility to stop producing heading pages to the SYSPRINT output file.
  •  
    EXCLUDE NOTACTIVE
    Excludes tasks that have a NOT ACTIVE status.
  •  
    EXCLUDE REPCONNECT
    Suppresses the URT open and close that occurs in conjunction with the REPEATS= parameter.
     With the EXCLUDE REPCONNECT option specified, you must terminate AUTOSTAT before issuing the EOJ to the repository MUF.
  •  
    EXCLUDE WARNMSG
    Suppresses warning messages.
  •  
    INCLUDE DURATION0
    Includes tasks regardless of duration.
  •  
    INCLUDE HEADER
    Produces a page header at the top of each new page of the SYSPRINT output file. Each page is typically 60 lines.
  •  
    INCLUDE NOTACTIVE
    Includes tasks regardless of task status.
  •  
    INCLUDE REPCONNECT
    Activates the URT open and close that occurs in conjunction with the REPEATS= parameter.
  •  
    INCLUDE WARNMSG
    Enables warning messages.
  •  
    OUTTAG 
    tag1
     
    Changes the current OUTTAG value to a new value. Value must be between 1 and 16 alphanumeric characters.
  •  
    REMOVEMUF 
    oldmuf
     
    Remove the existing MUFNAME from the list of MUFs that are being used as the source for the status Snapshots.
     There must be at least one valid MUFNAME per AUTOSTAT execution. If you attempt to remove the last MUFNAME, the command will be ignored and a message issued.
  •  
    REPEATS 
    nnnnn
     
    Changes the current REPEATS= parameter timer to this new value. Value must be 0 or between 3 and 64800. Changing the value to 0 causes the utility to do one last Snapshot and end. Changing the value to other than 0 forces an immediate Snapshot and changes the wait interval between further Snapshots and the utility continues to execute in the loop with the new REPEATS value.
Example JCL (AUTOSTAT)
Following is an example of the JCL for this function.
 Use the following as a guide to prepare your JCL. The JCL statements are for example only. Lowercase letters in a statement indicate a value you must supply. Code all statements to your site and installation standards.
//jobname See the previous note
and JCL Requirements
. // EXEC PGM=DBUTLTY,REGION=2M //STEPLIB See the previous note
and JCL Requirements
. //SYSIN DD * Command input AUTOSTAT MUFNAME=DBDVMV1,MUFNAME=PRGMUF01,OUTTAG=SAMPLE /*
Sample Report
Following is a sample report page. For an example report header, see Sample Report Headers.
CONTROL CARD(S) .........1.........2.........3.........4.........5.........6 AUTOSTAT DBID=1018,OUTTAG=OUTTAG1, REPEATS=6, MUFNAME=MUF4 FUNCTION=AUTOSTAT DBID=01018 MUFNAME=MUF4 OUTTAG=OUTTAG1 REPEATS=00006
This page of the report shows the following:
  • The command exactly as entered.
  • An analysis of keywords encountered and expected. Any errors found are flagged with a note in the left margin.
  • Any messages related to syntax processing.
-------------------------------------------------------------------------------- REPOSITORY DBID: 1018 REPOSITORY MUF: MUF4 CURRENT DATETIME: 22:58:01.6078100000 2009/03/02 PROCESSED MUF: MUF4 < MUF4 RECORDS PROCESSED: 1 TOTAL MUFS PROCESSED: 1 OUT OF 1 TOTAL ROWS SNAPPED: 1 -------------------------------------------------------------------------------- REPOSITORY DBID: 1018 REPOSITORY MUF: MUF4 CURRENT DATETIME: 22:58:07.6399570000 2009/03/02 PROCESSED MUF: MUF4 < MUF4 RECORDS PROCESSED: 1 TOTAL MUFS PROCESSED: 1 OUT OF 1 TOTAL ROWS SNAPPED: 1 -------------------------------------------------------------------------------- . . . -------------------------------------------------------------------------------- REPOSITORY DBID: 1018 REPOSITORY MUF: MUF4 CURRENT DATETIME: 22:58:31.7494190000 2009/03/02 PROCESSED MUF: MUF4 < MUF4 RECORDS PROCESSED: 1 TOTAL MUFS PROCESSED: 1 OUT OF 1 TOTAL ROWS SNAPPED: 1 -------------------------------------------------------------------------------- ** 22:58:36.4478340000 2009/03/02 DB30050I - COMM EOJ ISSUED - PROGRAM TERMINATED