6.2 Logrec

 < Day Day Up > 



6.2 Logrec

The Logrec log stream is an alternative to the use of LOGREC data sets. The LOGREC data sets normally contain an accumulation of records (called LOGREC records) describing errors that have occurred on the system. The information provides you with a history of all hardware failures, selected software errors, and selected system conditions. The use of the log stream instead of LOGREC data sets allows you to have a single source of information for errors across all systems in the sysplex.

6.2.1 Functional description

You can choose where the system will record Logrec error records. When a system is not in a sysplex, an installation can use a LOGREC data set, associated with an individual system, to record error records.

In a sysplex, however, because each system requires its own Logrec data set, you might need to look at each LOGREC data set when an error occurs.

To eliminate the problem of having to manage multiple LOGREC data sets, an installation can choose to define one CF-Structure Logrec log stream. Using a CF-Structure Logrec log stream eliminates the following:

  • Running IFCDIP00 to initialize multiple LOGREC data sets

  • Having the LOGREC data set fill up on you

  • Scheduling the daily offload of LOGREC data sets

  • Concatenating multiple history data sets

  • Archiving Logrec records

The Logrec log stream is a funnel-type log stream. Each system writes records as they get generated. The records never get referenced unless the installation browses the log stream to retrieve information about specific errors.

The name of the Logrec log stream is fixed: SYSPLEX.LOGREC.ALLRECS. There can only be one Logrec log stream in a sysplex, but each system can independently choose to record the error data in the log stream or in the LOGREC data set.

Criticality/persistence of data

While Logrec data is a valuable tool to help you diagnose problems, the data would not be considered critical. Loss of the data will not result in any adverse impact on the system or its availability.

Logrec keeps the log records in the log stream merged from all the systems in the sysplex that are connected to the log stream. In order to be able to fall back to the use of the LOGREC data sets, we recommend that you IPL with a LOGREC data set initialized by IFCDIP00 and then immediately switch to the Logrec log stream via a command. If you do not IPL with a Logrec data set, you will not be able to change the Logrec recording medium from LOGSTREAM to DATASET using the SETLOGRC command.

If you wish to share the Logrec across multiple z/OS instances, the log stream must be placed in a CF structure. It is usually mapped to a dedicated Coupling Facility structure. In a single system sysplex you can use a DASD-only log stream. This provides similar benefits to a CF log stream, with the exception of course that it only contains data from a single system.

Logrec data can reside in the log stream indefinitely. If you choose this option, you need to pay attention to the size of the offload data sets and on how to manage them. You need sufficiently large offload data sets that you do not generate so many that you run out of DSEXTENTS (by default you get up to 168 offload data sets per log stream). In this case, you will probably need some means of migrating older data sets using a product like HSM. This automatic migration will provide some relief in space consumption if you are planning to keep the logrec records for a long time. However, if your installation keeps these records for a long time (a number of years, for example), you might want to consider whether the log stream is the correct archival place for the Logrec data. If not, you can use a utility to move data from the log stream to a GDG data set, for example.

Log stream sizing

Logrec is a funnel type log stream; that is, it never deletes old records itself. Regardless of the size of the structure containing the log stream, eventually the data will be offloaded to an offload data set - how many there are and how frequently it happens will depend on the overall configuration of the Logrec environment.

For an initial sizing of your Logrec log stream, check how many records are written per second to the Logrec data set on each of your systems, aggregate them, and use the CFSizer tool to determine the size of the CF structure. The tool can be located at the IBM web site:

http://www.ibm.com/servers/eserver/zseries/pso

6.2.2 Definition

Subsystem definition

The suggested way to set up the Logrec environment is to IPL each system using its own Logrec data set specified in the IEASYS parmlib member as in Example 6-5.

Example 6-5: IEASYS Parmlib member for Logrec data set

start example
    LOGCLS=L,    LOGLMT=010000,    LOGREC=SYS1.&SYSNAME..LOGREC,    MAXUSER=128,    MLPA=00, 
end example

You can then switch to using the log stream by using the SETLOGRC command. This process allows your installation to fall back to using the data set should you so wish.

Alternately, you can choose to use the log stream as the recording medium immediately from the IPL. In this case, you specify LOGREC=LOGSTREAM in the IEASYS Parmlib member as shown in Example 6-6.

Example 6-6: IEASYS Parmlib member for log stream

start example
    LOGCLS=L,    LOGLMT=010000,    LOGREC=LOGSTREAM,    MAXUSER=128,    MLPA=00, 
end example

In this configuration, if you become unable to use the log stream for some reason, the system will lose the recording capability. This means that the system will continue to run, but any Logrec records that are generated will be lost. However, if the log stream is not available at IPL time, the system doesn't complete initialization.

Logrec log stream structure definition in the CFRM Policy

Before using the Logrec log stream, you have to make sure that the corresponding CF structure has already been defined in the CFRM policy and that the CFRM policy has been activated in the sysplex through the SETXCF command. Example 6-7 contains a sample to define the Coupling Facility structures for the Logrec log stream.

Example 6-7: Structure definition for Logrec

start example
 //LOGREC JOB CLASS=A,MSGCLASS=A //POLICY EXEC PGM=IXCMIAPU //SYSPRINT DD SYSOUT=A //SYSIN DD *    DATA TYPE(CFRM)    STRUCTURE NAME(LOGREC)       SIZE(2048)       INITSIZE(1024)       PREFLIST(FACIL01,FACIL02) 
end example

Logger definitions

Most installations use a CF-Structure log stream for Logrec. For this reason, the following is an example on how to define the Logrec log stream into the LOGR policy. Refer to "Logrec log stream structure definition in the CFRM Policy" on page 208 for the further informations on CFRM parameters for the Logrec structure.

Example 6-8: Logger policy definition sample for Logrec log stream

start example
 //DEFINE EXEC PGM=IXCMIAPU //SYSPRINT DD SYSOUT=A //SYSIN DD *    DATA TYPE (LOGR)    DEFINE STRUCTURE NAME(LOGREC)       LOGSNUM(1)       AVGBUFSIZE(4068)       MAXBUFSIZE(4068)    DEFINE LOGSTREAM NAME(SYSPLEX.LOGREC.ALLRECS)       STRUCTNAME(LOGREC)       LS_DATACLAS(LOGR4K)       HLQ(IXGLOGR)       LS_SIZE(1024)       LOWOFFLOAD(0)       HIGHOFFLOAD(80)       STG_DUPLEX(NO)       RETPD(0)       AUTODELETE(NO) 
end example

MAXBUFSIZE: MAXBUFSIZE must be at least 4068 because Logrec writes records in one page blocks.

AVGBUFSIZE: On the structure definition, AVGBUFSIZE specifies the average size, in bytes, of individual log blocks that can be written to log streams allocated to the coupling facility. You can use the 4068 value suggested that fits most of the installation.

LOWOFFLOAD: The LOWOFFLOAD value defines the amount of data which may be retained in the log stream interim storage following an offload process. In the Logrec environment, the LOWOFFLOAD value should be 0 since there is no need to keep any data in the interim storage.

LS_SIZE: The LS_SIZE specifies the size, in 4K blocks, of the log stream offload data sets for the log stream. An initial value for the LS_SIZE is to allocate as much space as is allocated for all the Logrec data sets on the systems in the sysplex before migrating to a Logrec log stream

Caution 

Be sure you either specify an LS_SIZE value on the log stream definition or you use an LS_DATACLAS where you have space allocation defined. If LS_SIZE is not specified in the log stream definition, and an extent size is not specified in the data class pointed to by LS_DATACLAS, the value is taken from the ALLOCxx Parmlib member. The default value in ALLOCxx is 2 tracks. Refer to the z/OS MVS Initialization and Tuning Reference, SA22-7592.

Both methods are valid, it depends on your installation and on the variety of the log streams. If you do not have a big variety of offload data set, you can use SMS dataclas to manage the allocation space and simply omit the LS_SIZE parameter. If your installation has multiple different type of offload data set that will generate too many SMS Dataclas, than you might want to consider to use LS_SIZE on each log stream

HLQ: The HLQ specifies the high level qualifier for both the log stream data set name (and the staging data set name if used). If you do not specify a high level qualifier, a high level qualifier IXGLOGR is defaulted.

AUTODELETE and RETPD: If your installation is planning to use the Logrec log stream as the accumulation place for the errors records, you should specify AUTODELETE(YES) and RETPD(x) where x is the longest time you would like to keep the data in your installation. In such a configuration, it is recommended that you migrate the offload data sets to avoid high usage of DASD space. At the beginning, when you activate this configuration, you should monitor the amount of offload data sets that are created to avoid potential directory full condition on the LOGR inventory couple data set.

Security definitions

The Logrec log stream can be protected in the Security Access Facility (SAF) LOGSTRM class. You can provide default READ access so all the users will be able to browse and retrieve records from this log stream. If you have batch job to archive Logrec records, you need to give UPDATE permit to that userid in order to perform deletion of records.

Example 6-9: Sample log stream security definitions

start example
 RDEFINE LOGSTRM SYSPLEX.LOGREC.ALLRECS UACC(READ) SETROPTS CLASSACT(LOGSTRM) 
end example

The log stream name defined to RACF is the name specified on the NAME parameter of the DEFINE LOGSTREAM statement in the LOGR policy

6.2.3 Operational considerations

The following are considerations on how to operate in the Logrec environment:

Displaying Logrec status

The status of Logrec recording can be displayed using D Logrec command:

Example 6-10: D Logrec command

start example
    D Logrec    IFB090I 10.09.40 Logrec DISPLAY 276    CURRENT MEDIUM = LOGSTREAM    MEDIUM NAME = SYSPLEX.LOGREC.ALLRECS    STATUS = CONNECTED 
end example

Where CURRENT MEDIUM can be:

  • IGNORE Recording of Logrec error and environmental records is disabled.

  • LOGSTREAM The current medium for recording Logrec error and environmental records is a log stream.

  • DATASET The current medium for recording Logrec error and environmental records is data set.

MEDIUM NAME can be:

  • SYSPLEX.LOGREC.ALLRECS (if the current medium is LOGSTREAM)

  • The data set name where Logrec errors are recorded (if the current medium is DATASET)

The STATUS line is only displayed if the current medium is LOGSTREAM. Its values can be:

  • CONNECTED

  • NOT CONNECTED

  • LOGGER DISABLED

If the STATUS shows as CONNECTED, then the log stream is connected and active.

Changing Logrec recording medium

Logrec recording can be changed dynamically via:

 SETLOGRC {LOGSTREAM|DATASET|IGNORE} 

Where the operands indicate:

LOGSTREAM: The desired medium for recording Logrec error and environmental records is a log stream. To use a log stream in your installation, the Logrec log stream must be defined.

DATASET: The desired medium for recording Logrec error and environmental records is a data set. Setting the medium to data set works only if the system had originally been IPLed with a data set as the Logrec recording medium. If the system was not IPLed with a data set Logrec recording medium and the attempt is made to change to DATASET, the system rejects the attempt and maintains the current Logrec recording medium.

IGNORE: This indicates that recording Logrec error and environmental records is to be disabled. It is not recommended to use the IGNORE option except in a test environment.

Running EREP

There is a sample job, IFBEREPS, in SYS1.SAMPLIB that can be used as a template for running EREP jobs. It must be modified to match your installation's setup. The job can be used to extract data from the Logrec log stream, create history data sets, and clear records from the log stream.

A sample job which creates a system exception report is shown in Example 6-11.

Example 6-11: Sample EREP job to browse Logrec log stream

start example
 //EREP JOB (999,POK),MSGLEVEL=(1,1),MSGCLASS=X,NOTIFY=&SYSUID, // CLASS=A,REGION=4M //EREPSER EXEC PGM=IFCEREP1,REGION=4M,PARM='CARD' //ACCIN DD DSN=SYSPLEX.Logrec.ALLRECS, // SUBSYS=(LOGR,IFBSEXIT,,'DEVICESTATS'), // DCB=(RECFM=VB,BLKSIZE=4000) //ACCDEV DD DUMMY //SERLOG DD DUMMY //DIRECTWK DD UNIT=SYSDA,SPACE=(CYL,15,,CONTIG) //TOURIST DD SYSOUT=*,DCB=BLKSIZE=133 //EREPPT DD SYSOUT=*,DCB=BLKSIZE=133 //SYSABEND DD SYSOUT=* //SYSIN DD *    HIST    ACC=N    SYSEXN 
end example

6.2.4 Recovery

As described in "Functional description" on page 206, your installation can prevent any loss of data condition if the configuration is planned carefully. Follow the suggested method to implement and to activate the Logrec recording on the log stream media.

6.2.5 Performance

After your initial log streams allocation, performance data is produced in a number of forms that can be useful to determine if any adjustments are necessary to your installation:

  • SMF 88 data produced by the MVS System Logger

  • SMF 70–78 data produced by various MVS components

There are several tools which aide in the analysis of log stream performance problems.

  • IXGRPT1 formats and reports the SMF 88 data produced by the MVS System Logger

  • ERBRMFPP reports on the data captured in the SMF 70 -78 records

Usually this is not a critical log stream from a performance perspective. There are some fields in the SMF88 that you might want to check against this log stream: DASD SHIFT, STRUCTURE FULL, ENTRY FULL. Refer to "SMF Type 88 records and IXGRPT1 program" on page 281 for a description of these fields and what to do in case of one of this condition happens in your installation.



 < Day Day Up > 



Systems Programmer's Guide to--Z. OS System Logger
ASP.NET for Web Designers
ISBN: 738489433
EAN: 2147483647
Year: 2002
Pages: 99
Authors: Peter Ladka

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net