IBM Support

Converting a Collection Services File for New Metrics

News


Abstract

Converting a Collection Services File for New Metrics

Content

You are in: IBM i Technology Updates > Performance Tools > Performance Data Collectors > Documentation and Tips > Converting a Collection Services File for New Metrics

 

When new fields are added to a Collection Services database file in a PTF, the cover letter will contain special instructions to convert existing Collection Services file-based collections to the new database file format.

The instructions provided below are generic instructions for upgrading existing Collection Services file-based collections to the latest database file formats. See the PTF cover letter for the exact instructions related to the PTF being applied.

The Collection Services database files can be converted to the latest file formats in any library. If the management collection objects (*MGTCOL) still exist for file-based collections in an existing library, an alternative option is to run Create Performance Data (CRTPFRDTA) for each *MGTCOL into a new library. Collection Services will create the database files in the new library using the latest file formats that include the new metrics. The Collection Services database files in the active configured collection library can be upgraded similarly.

Restarting Collection Services in a new collection library

For the active configured collection library, it may be easiest to simply restart Collection Services data collection into a newly created library. Collection Services will create the database files in the new library using the latest file formats that include the new metrics. To do this, follow the instructions below.

  1. End Collection Services:
    ENDPFRCOL FRCCOLEND(*YES)
  2. Rename the existing configured collection library:
    RNMOBJ OBJ(QPFRDATA) OBJTYPE(*LIB) NEWOBJ(xxxxxxxx)      
    Note: Your active configured library may not be QPFRDATA. If you prompt on command CFGPFRCOL, the Collection library (LIB) parameter specifies the configured collection library.
  3. Create a new configured collection library:
    CRTLIB LIB(QPFRDATA)
  4. Start Collection Services:
    STRPFRCOL
    Note: The Collection Services CRTPFRDTA job will create the database files in the new library using the latest file formats that include the new metrics.

Converting database files in an existing library to new file formats

The Collection Services database files can be converted to the latest file formats in any library. The instructions provided below are generic instructions for upgrading existing Collection Services file-based collections to the latest database file formats. See the PTF cover letter for the exact instructions related to the PTF being applied.

  1. If the library being upgraded is the active configured collection library, Collection Services must be ended:
    ENDPFRCOL FRCCOLEND(*YES)
  2. For each physical file that you want to update to the latest file format, determine if there are any dependent objects by examining the output of the following command:
    DSPDBR FILE(your-lib/physical-file)
  3. For each physical file that you want to update to the latest file format, move it from the existing library to a backup library:
    MOVOBJ OBJ(col-lib/physical-file) OBJTYPE(*FILE) TOLIB(your-backup)
  4. For each dependent object identified in step 2, move it from the existing library to a backup library:
    MOVOBJ OBJ(col-lib/dependent-obj) OBJTYPE(obj-type) TOLIB(your-backup)
  5. For each physical file you moved in step 3, create a copy of the physical file with the latest file format in QSYS to the existing library:
    CRTDUPOBJ OBJ(physical-file) FROMLIB(QSYS) OBJTYPE(*FILE) TOLIB(col-lib)
  6. For each physical file you moved in step 3, grant users in the QPMCCDATA authorization list access to the new file in the existing library:
    GRTOBJAUT OBJ(col-lib/physical-file) OBJTYPE(*FILE) AUTL(QPMCCDATA)
  7. For each physical file you moved in step 3, copy all members from the physical file in the backup library to the new file in the existing library:
    CPYF FROMFILE(your-backup/physical-file) TOFILE(col-lib/physical-file) FROMMBR(*ALL) TOMBR(*FROMMBR) MBROPT(*REPLACE) FMTOPT(*MAP *DROP)
  8. For each dependent object you moved in step 4, create a copy from the backup library to the existing library:
    CRTDUPOBJ OBJ(dependent-obj) FROMLIB(your-backup) OBJTYPE(obj-type) TOLIB(col-lib) DATA(*YES)
  9. For each dependent object you moved in step 4, delete it from the backup library:
    DLTOBJ OBJ(your-backup/dependent-obj) OBJTYPE(obj-typ)
    Note: If you do not delete the dependent objects from the backup library, they could prevent the deletion of the collections in the existing library.
  10. Restart Collection Services performance data collection if you ended it in step 1:
    STRPFRCOL

[{"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Product":{"code":"SWG60","label":"IBM i"},"Component":"","Platform":[{"code":"PF012","label":"IBM i"}],"Version":"All Versions","Edition":"","Line of Business":{"code":"LOB57","label":"Power"}}]

Document Information

Modified date:
24 January 2020

UID

ibm11172182