TAA Tools
SYSACT          SYSTEM ACTIVITY                        TAASYTZ

The  System  Activity tool  is  a  series  of commands  that  lets  you
capture  and  work  with the  data  produced  by  the WRKSYSACT  system
command.   This  provides performance  information for  jobs/tasks that
have occurred during  one or more  intervals.  The  SYSACT tool can  be
helpful  in reviewing  performance characteristics  such as  CPU usage,
I/O  counts and a breakdown of reads/writes  for data base and non-data
base activity.

The system WRKSYSACT command
----------------------------

WRKSYSACT was  part  of the  performance tools,  but  is now  a  system
command.

WRKSYSACT allows  either an  interactive approach to  view the  data or
the ability to create an outfile.

If an  outfile is specified, a batch job is  submitted.  The outfile is
always QAITMON with a  default library name of  QPFRDATA.  An  interval
of  time in  seconds  and the  number  of intervals  that  you want  to
capture  information for may  be specified.   No data is  written until
all  intervals are  complete.  The  command is always  submitted to the
QBATCH job queue in  QGPL.  The job queue  is shipped as a  'single job
at a time'  job queue which makes it awkward to  determine when the job
will  run.  The  data in the  specified output file  is always replaced
thus making it  awkward to  compare information at  different times  of
the day or on different days.

CPU time is reported in units where each unit is 4096 microseconds.

No command is provided to work with the data.

Benefits of using the SYSACT tool
---------------------------------

The SYSACT  tool provides  a CAPSYSACT  command which allows  WRKSYSACT
to run  from the QSYSNOMAX job queue thus  allowing you to control when
the performance information should be gathered.

A separate job is also run from  QSYSNOMAX to copy the data when it  is
complete  to the  TAA  file SYSACTP.    You control  when  the data  is
cleared  by  using the  MBROPT  parameter on  CAPSYSACT.   This  allows
different time periods to be compared.

A  TAA DSP  command works  with the  data in  SYSACTP to  provide basic
performance  information.    A  query  may  be  written   for  specific
comparisons.

Getting started with SYSACT
---------------------------

  **   As  an *ALLOBJ  user, ensure  the  QAITMON file  in QPFRDATA  is
       created by entering:

             WRKSYSACT   OUTPUT(*FILE) INTERVAL(1) NBRITV(1)

       Wait  for the  message that  says WRKSYSACT  is complete.   This
       creates the  QAITMON  file in  QPFRDATA  which  is used  by  the
       SYSACT tool.

  **   As an  *ALLOBJ user,  create the  SYSACTP file  in a library  of
       your choice (a library on your library list is best):

             CRTSYSACT  SYSACTLIB(xxx)

  **   If the library is not on your library list, add it.

             ADDLIBLE   LIB(xxx)

  **   Capture  the system  activity by prompting  for CAPSYSACT.   The
       defaults are  for 10  second intervals  and 5  intervals.   This
       means that  statistics  will be  accumulated for  all jobs  that
       were  running during  the interval  (including system  jobs) and
       that  5 intervals should be taken.   Keep both numbers low until
       you familiarize  yourself  with the  tool.   Enter  the  command
       with the defaults:

             CAPSYSACT

       This submits two batch jobs.

       The  first  job  (WRKSYSACT)  will  run  the  system  command  I
       WRKSYSACT.   The job is  submitted in a 'held'  status, moved to
       the QSYSNOMAX job  queue, and  then released.   The data  always
       written to the QAITMON file (member QAITMON) in QPFRDATA.

       The  second job  (CPYSYSACT) also  runs from  the QSYSNOMAX  job
       queue and  waits for the first job  to complete.  When WRKSYSACT
       completes, it copies  all data from  all intervals and  replaces
       the data  in the QAITMON  file in QPRFDATA.   CPYF is  then used
       to  copy  the  data   to  the  SYSACTP  file  that  was  created
       previously.    Records  are  added  to  the  SYSACTP  file  (not
       replaced).

       You should  see  a  completion  message for  the  CPYSYSACT  job
       about one minute after entering CAPSYSACT.

  **   Use the display command to display the data.

            DSPSYSACT

       A  display  will  appear  with   the  data  in  a  basic  format
       describing  each  job  that  ran  during  each  interval.    The
       qualified job name  is described  along with the  date and  time
       of the interval.   CPU usage, total I/O activity  and the number
       of  data base  reads/writes and  non-data base  reads/writes are
       shown.

  **   After  capturing  information,  you   would  normally  run   the
       DSPSYSACT with defaults  to assist in determining what  you want
       to select on to minimize the amount of output.

       After reviewing  the information, you  may want to  run it again
       and  specify  some selection  criteria.   For  example,  you may
       want to look  at a specific job  or user which can  be specified
       on DSPSYSACT.

  **   The THRESHOLD  parameter on DSPSYSACT allows only  the jobs that
       meet or exceed a minimum threshold to be listed.

       The  default is  for TYPE(*CPU), but  you could  specify a value
       such as *TOTALIO.  The  THRESHOLD parameter works with the  TYPE
       parameter.   For  example, you  can  list only  those jobs  that
       have more than 100 I/Os by specifying:

             DSPSYSACT  TYPE(*TOTALIO) THRESHOLD(100)

  **   The  FORMAT  parameter  can  be  used  to  focus on  either  the
       'reads' or 'writes' that  have occurred.   For example, you  can
       specify:

             DSPSYSACT  FORMAT(*READS) TYPE(*SYNDBR)
                          THRESHOLD(5)

       This will describe the  jobs that have had at least  5 data base
       'synchronous reads' during an interval.

  **   You  should  clear  the  SYSACTP  file  if  you  are  no  longer
       interested  in the data.   No special command  is provided.  Use
       the system command:

              CLRPFM  FILE(SYSACTP)

SYSACT escape messages you can monitor for
------------------------------------------

None.  Escape messages from based on functions will be re-sent.

CRTSYSACT Command parameters                          *CMD
----------------------------

   SYSACTLIB     The name of  the library where  the SYSACTP file  will
                 be created.

   SRCLIB        The  source  library  to  use  for  the  QATTDDS  file
                 source.  The default is *TAAARC.

                 A  specific user library may be  named, but the source
                 file must be QATTDDS.

   AUT           The authority to  the SYSACTP  file.   The default  is
                 *USE which allows  any user to use  DSPSYSACT after an
                 authorized  user  runs  CAPSYSACT.   An  AUT  value of
                 *CHANGE,  *LIBCRTAUT,  or   *EXCLUDE  could  also   be
                 entered.  Only  a user with *CHANGE authority  may use
                 CAPSYSACT.


CAPSYSACT Command parameters                          *CMD
----------------------------

   INTERVAL      The  interval  length  in  number  of  seconds.    The
                 default  is 10.   It  must be  a number between  1 and
                 900.

                 For example, if  10 is used,  the system will write  a
                 summary record  for each job  or task that  was active
                 during a 10 second interval.

   INFTYPE       The  type of information to be  captured.  The default
                 is *JOBS which differs  from the WRKSYSACT default  of
                 *ALL.    *TASKS  or  *ALL   (meaning  both  *JOBS  and
                 *TASKS) may be specified.

   NBRITV        The  number of  intervals to capture  information for.
                 5 is the default.  It  must be a number between 1  and
                 900.

   MBROPT        The member option for the SYSACTP file.

                 *ADD is  the  default to  add records  to the  SYSACTP
                 file.

                 *REPLACE  may be  specified to  clear the  file before
                 adding any records to SYSACTP.

   SYSACTLIB     The  name  of  the  library  where  the  SYSACTP  file
                 exists that was  created by CRTSYSACT.   *LIBL is  the
                 default.    A  specific  library  of  *CURLIB  may  be
                 entered.


DSPSYSACT Command parameters                          *CMD
----------------------------

   FORMAT        The  format of  the  output.   The parameter  works in
                 conjunction with  the  TYPE parameter.    All  formats
                 include the  job/task name  specifics, the  date/time,
                 CPU usage, and Total I/O used.

                 *BASIC   is  the   default.     This   provides  basic
                 performance  information  which  combines  the  totals
                 for synchronous and asynchronous values.

                 *READS   may   be   specified    to   provide   detail
                 performance  information about  the  types  of 'reads'
                 that have occurred.

                 *WRITES   may   be   specified   to   provide   detail
                 performance information  about the  types of  'writes'
                 that have occurred.

   TYPE          The  type  of  information  to  be  displayed.    This
                 parameter  works in  conjunction  with the  FORMAT and
                 THRESHOLD parameters.   The TYPE  determines what  the
                 THRESHOLD value will be applied to.

                 *CPU is the  default for the amount of CPU  units.  It
                 may  be specified with  any TYPE  value.  CPU  time is
                 reported by  WRKSYSACT in  units  where each  unit  is
                 4096 microseconds.

                 *TOTALIO  may be  specified for  the  number of  I/Os.
                 It may be specified with any TYPE value.

                 *DBR  may be  specified for  the  number of  data base
                 reads.   This  a combination  of both  synchronous and
                 asynchronous reads.    It may  only be  specified  for
                 FORMAT(*BASIC).

                 *DBW  may be  specified for  the number  of  data base
                 writes.   This a  combination of  both synchronous and
                 asynchronous writes.   It  may only  be specified  for
                 FORMAT(*BASIC).

                 *NONDBR may  be specified  for the number  of non-data
                 base  reads.  This  a combination  of both synchronous
                 and asynchronous  reads.   It  may only  be  specified
                 for FORMAT(*BASIC).

                 *NONDBW may  be specified for  the number  of non-data
                 base writes.   This a combination  of both synchronous
                 and  asynchronous writes.   It  may only  be specified
                 for FORMAT(*BASIC).

                 *SYDBR   may   be  specified   for   the   number   of
                 synchronous  data   base  reads.    It   may  only  be
                 specified for FORMAT(*READS).

                 *ASYDBR   may   be  specified   for   the   number  of
                 asynchronous  data  base  reads.    It  may   only  be
                 specified for FORMAT(*READS).

                 *SYDBW   may   be   specified  for   the   number   of
                 synchronous  data   base  writes.    It  may  only  be
                 specified for FORMAT(*WRITES).

                 *ASYDBW  may   be   specified  for   the   number   of
                 asynchronous  data  base  writes.    It  may  only  be
                 specified for FORMAT(*WRITES).

                 *SYNDBR   may   be  specified   for   the  number   of
                 synchronous  non-data  base  reads.   It  may  only be
                 specified for FORMAT(*READS).

                 *ASYNDBR  may   be  specified   for   the  number   of
                 asynchronous  non-data base  reads.   It  may only  be
                 specified for FORMAT(*READS).

                 *SYNDBW   may   be  specified   for   the   number  of
                 synchronous non-data  base  writes.   It may  only  be
                 specified for FORMAT(*WRITES).

                 *ASYNDBW   may  be   specified  for   the  number   of
                 asynchronous  non-data base  writes.   It may  only be
                 specified for FORMAT(*WRITES).

   THRESHOLD     The threshold of  value for  the TYPE  value to  allow
                 the job  to appear in  the listing.   For example,  if
                 TYPE(*TOTALIO)  is specified  with  THRESHOLD(10), the
                 job  must  have  at least  10  I/Os to  appear  in the
                 listing.  The value must be greater than 0.

   PERIOD        A selection  by date/time of  the records in  SYSACTP.

                 The  beginning  date   defaults  to  *CURRENT  meaning
                 today's  date.  *BEGIN  may be  specified (meaning the
                 first record in  the file) or a  specific date may  be
                 entered in job format.

                 The  beginning time  defaults  to  *AVAIL meaning  the
                 first  time of  the beginning date.   A  specific time
                 may be entered in HHMMSS format.

                 The ending date defaults  to *CURRENT meaning  today's
                 date.   *END may be  specified (meaning the  record in
                 the file),  or *BGNDATE (meaning the same  date as the
                 beginning  date, or a specific  date may be entered in
                 job format.

                 The ending time  defaults to  *AVAIL meaning the  last
                 time  of the  ending date.    A specific  time may  be
                 entered in HHMMSS format.

   JOB           The  job name  to be  selected.   *ALL is  the default
                 for all jobs.   A specific job  or a generic job  name
                 may also be entered.

   USER          The user  name to  be selected.   *ALL is  the default
                 for  all users.   A  specific user  or a  generic user
                 name may also be entered.

   JOBNBR        The job  number to  be selected  *ALL is  the  default
                 for all job numbers.   A specific job number  may also
                 be entered.

   SYSACTLIB     The  name  of  the  library  where  the  SYSACTP  file
                 exists.   *LIBL  is the  default.   A specific library
                 of *CURLIB may be entered.

   OUTPUT        How to  output  the  results.   *  is the  default  to
                 display   a  listing   if  the   command  is   entered
                 interactively.

                 If  the  command  is entered  in  batch  or  *PRINT is
                 specified, a spooled file is created.


Restrictions
------------

You must have *ALLOBJ authority to use CRTSYSACT.

Prerequisites
-------------

The following TAA Tools must be on your system:

     CHKALLOBJ       Check *ALL object special authority
     CHKDBFMBR       Check data base file member
     CVTTIM          Convert time
     EDTVAR          Edit variable
     RSNLSTMSG       Resend last message
     RTVDAT          Retrieve date
     RTVJOBSTS       Retrieve job status
     RTVSBMJOB       Retrieve submitted job
     RTVSYSVAL3      Retrieve system value 3
     SNDCOMPMSG      Send completion message
     SNDESCINF       Send escape information
     SNDESCMSG       Send escape message
     SNDSTSMSG       Send status message

Implementation
--------------

None, the tool is ready to use.

Objects used by the tool
------------------------

   Object        Type    Attribute      Src member    Src file
   ------        ----    ---------      ----------    ----------

   DSPSYSACT     *CMD                   TAASYTZ       QATTCMD
   CRTSYSACT     *CMD                   TAASYTZ2      QATTCMD
   CAPSYSACT     *CMD                   TAASYTZ3      QATTCMD
   TAASYTZC      *PGM       CLP         TAASYTZC      QATTCL
   TAASYTZC2     *PGM       CLP         TAASYTZC2     QATTCL
   TAASYTZC3     *PGM       CLP         TAASYTZC3     QATTCL
   TAASYTZC13    *PGM       CLP         TAASYTZC13    QATTCL
   TAASYTZR      *PGM       RPG         TAASYTZR      QATTRPG
   TAASYTZP      *FILE      PF          TAASYTZP      QATTDDS

Structure
---------

DSPSYSACT   Cmd
   TAASYTZC   CL pgm
     TAASYTZR   RPG Pgm

CRTSYSACT   Cmd
   TAASYTZC2   CL pgm

CAPSYSACT   Cmd
   TAASYTZC3   CL pgm
     TAASYTZC13   CL pgm submitted by TAASYTZC3
					

Added to TAA Productivity tools July 15, 2010


Home Page Up to Top