DB2 - L

  • 1.  Background of collect data at IBM db2 performance expert

    Posted 6 days ago
    Hi,I
    I use IBM Db2 Performance Expert on z/OS for monitoring ,. Now I want to know how it collects data in the backgrounds. 
    I monitored it and I see it doesn't issue any commands ,  so how calculate or display values at system overview.
    I know it gets  some of values from zparm but they are fix values but what about the other values?
    please help me if anybody knows about that.

    Regards,
    Pirayeh 


    ------------------------------
    PirayehBeyzaeisadad co
    ------------------------------


  • 2.  RE: Background of collect data at IBM db2 performance expert

    Posted 6 days ago
    I would hazard a guess by using IFCIDs....

    Roy Boxwell

    SOFTWARE ENGINEERING GmbH and SEGUS Inc.
    -Product Development-

    Vagedesstrasse 19
    40479 Dusseldorf/Germany
    Tel. +49 (0)211 96149-675
    Fax +49 (0)211 96149-32
    Email: R.Boxwell@seg.de
    Web http://www.seg.de
    Link zur Datenschutzerklärung

    Software Engineering GmbH
    Amtsgericht Düsseldorf, HRB 37894
    Geschäftsführung: Gerhard Schubert, Ulf Heinrich




  • 3.  RE: Background of collect data at IBM db2 performance expert

    Posted 6 days ago
    Thanks Roy 
    yes it is using IFCIDs but I want to know how read it?  with commands , jobs or another ways ... , I want to know what happens in the background for collecting data?!


    ------------------------------
    PirayehBeyzaeisadad co
    ------------------------------



  • 4.  RE: Background of collect data at IBM db2 performance expert

    Posted 6 days ago

    You have traces running on your system which externalize the IFCIDs to specified destinations. Monitors and reporters read this data from these destinations and present the information to users appropriately organized and formatted. You can try -DIS TRACE to see what traces are running and where the output is going. It's all documented in some manual that I can't currently recall.

     

    Khalid

     






  • 5.  RE: Background of collect data at IBM db2 performance expert

    Posted 6 days ago
    Some of the "cleverer" (quotation marks are intended) monitors reach into Db2 itself and
    extract data directly from Db2 control blocks. These do not use IFCID traces for that
    purpose.

    The -START TRACE commands that Performance Expert uses would be logged as IFCID
    type 4 records in SMF.

    Internally it would use the instrumentation facility interface to issue the commands and read the records.
    https://www.ibm.com/docs/en/db2-for-zos/12?topic=data-programming-instrumentation-facility-interface-ifi

    James Campbell


    On 22 Nov 2021 at 18:49, Mohammad Khan via Internation wrote:

    > You have traces running on your system which externalize the IFCIDs to specified destinations. Monitors and reporters read this data from these destinations and present the information to users appropriately organized and formatted. You can try -DIS TRACE to see what traces are running and where the output is going. It's all documented in some manual that I can't currently recall.
    >
    > Khalid
    >
    >
    >
    > -------------------------------------------
    > Original Message:
    > Sent: 11/22/2021 1:11:00 PM
    > From: Pirayeh Beyzaei
    > Subject: RE: Background of collect data at IBM db2 performance expert
    >
    > Thanks Roy
    > yes it is using IFCIDs but I want to know how read it? with commands , jobs or another ways ... , I want to know what happens in the background for collecting data?!
    >
    >
    > ------------------------------
    > PirayehBeyzaeisadad co
    > ------------------------------
    > -------------------------------------------
    > Original Message:
    > Sent: Nov 22, 2021 04:15 AM
    > From: Roy Boxwell
    > Subject: Background of collect data at IBM db2 performance expert
    >
    > I would hazard a guess by using IFCIDs....
    >
    > Roy Boxwell
    >
    > SOFTWARE ENGINEERING GmbH and SEGUS Inc.
    > -Product Development-
    >
    > Vagedesstrasse 19
    > 40479 Dusseldorf/Germany
    > Tel. +49 (0)211 96149-675
    > Fax +49 (0)211 96149-32
    > Email: R.Boxwell@seg.de


  • 6.  RE: Background of collect data at IBM db2 performance expert

    Posted 5 days ago

    James mentioned the Instrumentation Facility Interface (IFI), its is the official DB2 API. In principle one has to distinguish between the real-time (snapshot – what is current status?) data and the event trace data, like "end of thread".
    Both types can be started via a Db2 -START TRACE command with a specific destination (SMF, GTF, OPx buffer). For Snapshot requests the Db2 IFI API READS command has to be used. Event trace data are externalize by Db2 asynchronously and can either be directly used from SMF or GTF, or need to be read by a monitor via IFI API READA command.
    IBM (OMEGAMON) Db2 Performance Expert is using both approaches depending on its configuration and usage.  



    ------------------------------
    NorbertJenningerNorbert Jenninger
    ------------------------------



  • 7.  RE: Background of collect data at IBM db2 performance expert

    Posted 5 days ago
    Depends what data you're after.

    Statistics records (In SMF, the "100s" and "102s") can be read on-command using the READS command of the Db2 IFI.

    If you remember when EPVT VSTOR was a problem, IBM released a REXX called "MEMUSAGE" to read the IFCID0225 memory info for the subsystem and format it. Here's the REXX block where they invoked READS:

    /* Issue READS for IFCID225 */
    READS = substr('READS',1,8)
    IFCA = '00B40000'X||'IFCA'||copies('00'X,172)
    RTRNAREASIZE = 4096
    RTRNAREA = d2c(RTRNAREASIZE+4,4)left(' ',RTRNAREASIZE,' ')
    IFCIDAREA = '0006000000E1'X
    ADDRESS LINKPGM "DSNWLI2 READS IFCA RTRNAREA IFCIDAREA"
    RETCD = c2d(substr(IFCA,13,4))
    REASCD = d2x(c2d(substr(IFCA,17,4)))
    if RETCD > 4 then do
    say 'READS RETCODE = ' RETCD
    say 'READS REASON = ' REASCD
    if tracemon then call stotra tno
    exit 8
    end

    You can use that to pull IFCID 0001, 0002, 0106 among others...amazing what you can learn about the subsystem as a whole with that. I wrote a whole ISPF monitor based on it.



    If you want accounting data, as others have said, you'd probably want to turn on a trace to collect the IFCIDs you want, collect the data, then parse it. Or you can pull it directly from Db2 using READA, but I'm not as familiar with that...the manual documents all of this, though. Db2 will tell you whatever you want to know about it, as long as you ask properly.

    Check out the link that James posted previously...it documents exactly what the IFI data looks like, and how to address it. All of the IFCIDs are also documented byte-for-byte in SDSNMACS.

    ------------------------------
    MarkWieczorkowski...
    ------------------------------