Advanced Setup for DB2 (with data from TMON for DB2)

Table Of ContentsIT Service Vision Help


  1. Look at the supplied tables for TMON for DB2 data.

    From the IT Service Vision server's main menu, select

    PDB Admin -> Config Active PDB Dictionary -> Actions -> Add Table...

    You may want to search this list for TMON DB2 specific tables by selecting Filter List: and then by typing

       upcase(TABLENM) ? 'XTMD'

    and selecting OK. IT Service Vision displays a list that includes these tables:

    Table Description
    XTMDBA TMON for DB2 set current sqlid
    XTMDBB TMON for DB2 end of identify
    XTMDBC TMON for DB2 end of signon
    XTMDBD TMON for DB2 authorization failure
    XTMDBDA TMON for DB2 interval stats (V1 only)
    XTMDBDB TMON for DB2 thread detail (V1 only)
    XTMDBDE TMON for DB2 exception (V1 only)
    XTMDBDR TMON for DB2 thread resource (V1 only)
    XTMDBE TMON for DB2 grant and revoke
    XTMDBF TMON for DB2 ddl on audited object
    XTMDBG TMON for DB2 first write on audited obj
    XTMDBH TMON for DB2 first read on audited obj
    XTMDBI TMON for DB2 dml on audited object
    XTMDBJ TMON for DB2 utility start
    XTMDBK TMON for DB2 utility change
    XTMDBL TMON for DB2 utility end
    XTMDBM TMON for DB2 distributed authid trans
    XTMDBT TMON for DB2 sql trace
    XTMDDAB TMON for DB2 interval stats - buff pool
    XTMDDAF TMON for DB2 interval stats - ddf
    XTMDDA2 TMON for DB2 interval statistics
    XTMDDBB TMON for DB2 thread detail - buffer pool
    XTMDDBF TMON for DB2 thread detail - ddf
    XTMDDBK TMON for DB2 thread detail - package
    XTMDDBR TMON for DB2 thread detail - resource
    XTMDDB2 TMON for DB2 thread detail
    XTMDDC TMON for DB2 TMDBDC
    XTMDDD TMON for DB2 TMDBDD
    XTMDDE2 TMON for DB2 exception log
    XTMDDF TMON for DB2 unknown
    XTMDDW TMON for DB2 db2/irlm message

    (Additional table definitions may be added in future releases.)

  2. If you want to use these tables, create a a TMON test PDB (or use your DB2 test PDB) and add only those tables that you require for the PDB.

  3. Copy the appropriate MXG modules from MXG.MXG.SOURCLIB to MXG.USERID.SOURCE and customize them as described in CMAPP2.

  4. Process and reduce TMON data into the PDB.

    The JCL to load this data into a PDB is in the CMTMDBLD member member of CPMISC PDS, depending on the version of The Monitor for DB2 in use. Each of these members basically does the following:

    Copy member CMTMDBLD or CMTMD2LD from the CPMISC library into your own JCL library. The following is an annotated listing of the CMTMDBLD job.

       //CMTMDBLD JOB (accounting info),'Load TMON DB2 data',        #1
       //       REGION=32M,NOTIFY=
       //*
                       .
                       .                                             #2
                       .
       //*
       //STEP01  EXEC SAS,WORK='42000,6300',                         #3
       //        CONFIG='your.sascpe.CPMISC(CMCONFIG)'               #4
       //SASLIB   DD DSN=your.tmonexit.loadlib,DISP=SHR              #5
       //TMDBIN   DD DSN=your.tmon.DB2.log,DISP=SHR                  #6
       //SYSIN DD DATA,DLM='$$'
    
         *------------------------------------------------------------*
         * SAS/CPE will not run unless %CPSTART has been executed.    *
         * %CPSTART allocates IT Service Vision software and the PDB. *
         * The MXGLIB= and MXGSRC= parameters are required for the    *
         * MXG software tool used  within %CMPROCES below.            *
         * The ROOTSERV= and SHARE= parameters should only be used if *
         * SAS/SHARE is being used with IT Service Vision.            *
         * If the _RC= parameter is nonzero from %CPSTART,            *
         * check the explanatory message in the SAS log.              *
         *------------------------------------------------------------* ;
    
    
         %CPSTART(MODE=BATCH,SYSTEM=MVS,                             #7
                  ROOT='your.sascpe.',ROOTSERV=,                     #8
                  PDB='your.tmon.pdb',                               #9
                  DISP=OLD,SHARE=N/A,                                #10
                  MXGLIB=mxg.mxg.formats,                            #11
                  MXGSRC=('mxg.userid.sourclib' 'mxg.mxg.sourclib'), #12
                  _RC=cpstrc                                         #13
                 );
    
         %PUT CPSTART return code is &cpstrc;                        #14
    
    
         *------------------------------------------------------------*
         * Run MXG to process Landmark The Monitor for CICS data      *
         * into SAS data sets.                                        *
         *------------------------------------------------------------* ;
    
         RUN;
    
         *------------------------------------------------------------*
         * The %CMPROCES macro processes data into the PDB that was   *
         * established by the %CPSTART macro above.                   *
         * TOOLNM=SASDS and COLLECTR=GENERIC must be specified.       *
         * Only tables specified as the second parameter will be      *
         * processed in this example.                                 *
         * If the _RC= parameter is nonzero from %CMPROCES,           *
         * check the explanatory message in the SAS log.              *
         *------------------------------------------------------------* ;
    
         %LET cmprrc=.;                                              #15
    
    
         %CMPROCES(, [list of tables]              ,                 #16
                   COLLECTR=TMONDB2,TOOLNM=MXG,                      #17
                   _RC=cmprrc
               );
    
         %PUT CMPROCES return code is &cmprrc;
    
    
         *------------------------------------------------------------*
         * The following reduces data in the current PDB detail level *
         * into the day, week, month and year reduction levels.       *
         * The variables and statistics to be kept are defined        *
         * in the data dictionary.                                    *
         * If the _RC= parameter is nonzero from %CPREDUCE            *
         * check the explanatory message in the SAS log.              *
         *------------------------------------------------------------* ;
    
         %CPREDUCE(,_RC=cpredrc);                                    #18
    
         %PUT CPREDUCE return code is &cpredrc;                      #19
    
       $$
       //

    Notes:

    1. The JCL job card, which will need to be changed as appropriate for your site. If you have a large amount of TMON for DB2 data, you may want to increase the value of the time parameter on the job or you may want to decrease the number of days of TMON for DB2 data that you input at one time.

    2. The comments explaining the job and listing the customization instructions. Omitted for the sake of brevity.

    3. Invokes the SAS software in batch mode using a cataloged procedure. The values in WORK are in blocks.

    4. This is the configuration file to be used in batch IT Service Vision jobs.

    5. This job uses the TMONEXIT utility supplied with MXG. The utility was originally distributed by SAS Institute in SAS.BAMISC(TMONEXIT). See member EXITMON6 of your MXG.MXG.SOURCLIB for the JCL to assemble and link edit this utility if you are using compressed TMON data. Change your.tmonexit.loadlib to the name of the load library where the TMONEXIT utility resides.

    6. Change your.tmon.DB2.log to the dataset name of your TMON DB2 log data. The TMDBIN DD statement points to your TMON DB2 log data, which is probably on tape (in which case you will need to use additional parameters to meet your site's requirements).

    7. Initialize the macro variable to be used to contain the value of the return code from the %CPSTART macro.

    8. The %CPSTART macro can invoke the IT Service Vision server in foreground or in batch. Here you specify that you are invoking it in batch.

      IT Service Vision can run under more than one operating system. This identifies the operating system on which it runs.

    9. The high-level qualifier in the ROOT= parameter specifies the physical location of your IT Service Vision program library (PGMLIB). This parameter is required.

    10. The high-level qualifiers of your DB2 test PDB (the one created in the CMPDBALC job). Change 'your.tmonpdb.' to the high-level qualifier for your DB2 test PDB.

    11. To update the PDB (by adding tables, processing data into them, and reducing the data), specify DISP=OLD.

      The SHARE= parameter is only used if you are running with SAS/SHARE. It is not used in this example.

    12. The MXGLIB= parameter specifies MXG.MXG.FORMATS, the MXG supplied SAS library that contains SAS formats. Change the name MXG.MXG.FORMATS to the name of your MXG format library.

    13. The MXGSRC= parameter is shown with a concatenation of MXG.USERID.SOURCLIB and MXG.MXG.SOURCLIB. MXG searches them in the order listed and takes the first copy of a member that it finds, so be sure that the PDS with your customized members is listed before the PDS with the original members. Change MXG.USERID.SOURCLIB to the PDS that contains your customized MXG code, including the modified IMACTMDB member.

    14. The _RC= parameter identifies the name of the macro variable that is to contain the value of the return code from this macro.

    15. This statement prints the value of the %CPSTART macro's return code, stored in the CPSTRC macro variable.

    16. In this part of the job, you use MXG to transform data from the TMON logs into temporary (staging) SAS data sets. Member TYPETMDB in the MXG.MXG.SOURCLIB includes SAS code processing for the TMON for DB2 interval statistics, thread detail, and thread resource records.

    17. IT Service Vision processes the raw data into the PDB using the %CMPROCES macro. For the complete syntax of the %CMPROCES macro, see the Reference Documentation for IT Service Vision.

      For the list of tables provided in the second parameter (preceded with a comma), IT Service Vision automatically adds the table definitions from the master data dictionary to the PDB's data dictionary, if needed.

      Only data for the list of specified tables will be processed in this run.

      Note: If you do not specify a list of tables, the %CMPROCES macro processes data for all generic tables that are defined in the DB2 test PDB's data dictionary and that have KEPT=Y set.

    18. The COLLECTR= and TOOLNM= parameters indicate that MXG will be used to stage and process the TMON for DB2 data..

    19. The %CPREDUCE macro calculates the default summary statistics on the data that were processed into the PDB in the previous step and writes the statistics to the day, week, month, and year levels of the PDB. For the complete syntax of the %CPREDUCE macro, see the Reference Documentation for IT Service Vision.

  5. Use the tasks earlier in this document as models for working with this data.