Log data set definitions

Use this topic to decide on the most appropriate configuration for the log data sets.

This topic contains information to help you answer the following questions:


Should your installation use single or dual logging?

In general we should use dual logging for production, to minimize the risk of losing data. If we want your test system to reflect production, both should use dual logging, otherwise your test systems can use single logging.

With single logging data is written to one set of log data sets. With dual logging data is written to two sets of log data sets, so in the event of a problem with one log data set, such as the data set being accidentally deleted, the equivalent data set in the other set of logs can be used to recover the data.

With dual logging you require twice as much DASD as with single logging.

If we are using dual logging, then also use dual BSDSs and dual archiving to ensure adequate provision for data recovery.

Dual active logging adds a small performance cost.

Attention: Use of disk mirroring technologies, such as Metro Mirror, are not necessarily a replacement for dual logging and dual BSDS. If a mirrored data set is accidentally deleted, both copies are lost.

If you use persistent messages, single logging can increase maximum capacity by 10-30% and can also improve response times.

Single logging uses 2 - 310 active log data sets, whereas dual logging uses 4 - 620 active log data sets to provide the same number of active logs. Thus single logging reduces the amount of data logged, which might be important if your installation is I/O constrained.


How many active log data sets do we need?

The number of logs depends on the activities of our queue manager. For a test system with low throughput, three active log data sets might be suitable. For a high throughput production system you might want the maximum number of logs available, so, if there is a problem with offloading logs you have more time to resolve the problems.

We must have at least three active log data sets, but it is preferable to define more. For example, if the time taken to fill a log is likely to approach the time taken to archive a log during peak load, define more logs.

We should also define more logs to offset possible delays in log archiving. If we use archive logs on tape, allow for the time required to mount the tape.

Consider having enough active log space to keep a day's worth of data, in case the system is unable to archive because of lack of DASD or because it cannot write to tape. If all the active logs fill up, then IBM MQ is unable to process persistent messages or transactions. It is very important to have enough active log space.

It is possible to dynamically define new active log data sets as a way of minimizing the effect of archive delays or problems. New data sets can be brought online rapidly, using the DEFINE LOG command to avoid queue manager 'stall' due to lack of space in the active log.

To define more than 31 active log data sets, we must configure your logging environment to use a version 2 format BSDS. Once a version 2 format BSDS is in use, up to 310 active log data sets can be defined for each log copy ring. See Plan to increase the maximum addressable log range for information on how you convert to a version 2 format BSDS.

We can tell whether your queue manager is using a version 2 or higher BSDS, either by running the print log map utility (CSQJU004), or from the CSQJ034I message issued during queue manager initialization. An end of log RBA range of FFFFFFFFFFFFFFFF, in the CSQJ034I message, indicates that a version 2, or higher, format BSDS is in use. An end of log RBA range of 0000FFFFFFFFFFFF, in the CSQJ034I message, indicates that a version 1 format BSDS is in use.

When a queue manager is using a version 2, or higher, format BSDS, it is possible to use the DEFINE LOG command to dynamically add more than 31 active log data sets to a log copy ring.


How large should the active logs be?

From IBM MQ Version 8.0, the maximum supported active log size, when archiving to disk, is 4 GB. In previous releases of the product, the maximum supported active log size when archiving to disk is 3 GB.

When archiving to tape the maximum active log size is 4 GB.

We should create active logs of at least 1 GB in size for production and test systems.

Important: We need to be careful when allocating data sets, because IDCAMS rounds up the size you allocate.To allocate a 3 GB log specify one of the following options:

  • Cylinders(4369)
  • Megabytes(3071)
  • TRACKS(65535)
  • RECORD(786420)

Any one of these allocates 2.99995 GB. To allocate a 4GB log specify one of the following options:

  • Cylinders(5825)
  • Megabytes(4095)
  • TRACKS(87375)
  • RECORD(1048500)

Any one of these allocates 3.9997 GB. When using striped data sets, where the data set is spread across multiple volumes, the specified size value is allocated on each DASD volume used for striping. So, if we want to use 4 GB logs and four volumes for striping, we should specify:

  • CYLinders(1456)
  • Megabytes(1023)

Setting these attributes allocates 4*1456 = 5824 Cylinders or 4 * 1023 = 4092 Megabytes.Note: Striping is supported when using extended format data sets. This is usually set by the storage manager.


Active log placement

We should work with your storage management team to set up storage pools for the queue managers. We need to consider:

  • A naming convention, so the queue managers use the correct SMS definitions.
  • Space required for active and archive logs. Your storage pool should have enough space for the active logs from a whole day.
  • Performance and resilience to failures.

For performance reasons we should consider striping your active log data sets. The I/O is spread across multiple volumes and reduces the I/O response times, leading to higher throughput. See the preceding text for information about allocating the size of the active logs when using striping.

We should review the I/O statistics using reports from RMF or a similar product. Perform the review of these statistics monthly (or more frequently) for the IBM MQ data sets, to ensure there are no delays due to the location of the data sets.

In some situations, there can be much IBM MQ page set I/O, and this can impact the IBM MQ log performance if they are located on the same DASD.

If we use dual logging, ensure that each set of active and archive logs is kept apart. For example, allocate them on separate DASD subsystems, or on different devices.

This reduces the risk of them both being lost if one of the volumes is corrupted or destroyed. If both copies of the log are lost, the probability of data loss is high.

When creating a new active log data, set we should preformat it using CSQJUFMT. If the log is not preformatted, the queue manager formats the log the first time it is used, which impacts the performance.

With older DASD with large spinning disks, you had to be careful which volumes were used to get the best performance.

With modern DASD, where data is spread over many PC sized disks, we do not need to worry so much about which volumes are used.

Your storage manager should be checking the enterprise DASD to review and resolve any performance problems. For availability, you might want to use one set of logs on one DASD subsystem, and the dual logs on a different DASD subsystem.


Active log encryption with z/OS data set encryption

We can apply the z/OS data set encryption feature to page sets for queue managers running at IBM MQ for z/OS Version 9.1.4 or later.

We must allocate these page sets with EXTENDED attributes, and a data set key label that ensures the data is AES encrypted.

See the section, confidentiality for data at rest on IBM MQ for z/OS with data set encryption. for more information.

Parent topic: Plan your logging environment