TechTip: Pseudo Journal—Estimate the Overhead of System i Journaling

DB2
Typography
  • Smaller Small Medium Big Bigger
  • Default Helvetica Segoe Georgia Times
Many System i customers are aware of the benefits provided by journaling, but these same customers may be reluctant to use journaling because of the overhead that it can add to a system. Unfortunately, this reluctance is often based on journal performance experiences when the AS/400 was first released. And many of these customers forget about the countless improvements IBM has made over the years in terms of disk and CPU speeds as well as the efficiency of i5/OS journal software itself. Other System i customers are more open to journaling but avoid taking this step because they just don't know how much overhead will be added to the system.

To address this fear and uncertainty, IBM has recently made a no-charge, downloadable tool available to help customers better estimate the amount of overhead that journaling would add to their system. The toolset, known as Pseudo Journal, can be downloaded along with an installation guide and tutorial.

The Pseudo Journal toolset enables you to have i5/OS monitor changes (inserts, updates, and deletes) made to your database objects. After monitoring your database activity, the toolset can be used to provide an estimate of how much disk and CPU resources would be consumed if journaling had been active when the monitored database activity took place.

The toolset consists of two CL commands that are created during the installation process. The Start Pseudo Journal (STRPSJRN) command identifies which database objects you would like to monitor. This activation step can be a long-running operation, so it's recommend that the STRPSJRN command be executed in a batch process. In the following example, you'll see that only a single DB2 object has been specified on the FILE parameter.
   STRPSJRN FILE(KKTEST/DT1) DTAFILE(QGPL/PSJEST1) MBROPT(*CREATE) 
                     NBRSAMPLE(50) INTERVAL(20)          


The FILE parameter also supports a generic (i.e., wildcard) file name or *ALL to allow you to monitor all the DB2 tables in a library. The DTAFILE parameter specifies where the command will keep all of the monitoring statistics. You can use the NBRSAMPLE and INTERVAL parameters to control how much overhead the STRPSJRN command adds to your system. The NBRSAMPLE parameter controls how many times the Pseudo Journal tool will wake up and collect activity statistics for the specified DB2 object(s). The associated INTERVAL parameter specifies in seconds how frequently the Pseudo Journal tool is activated. In this example, the tool will collect 50 activity samples with the samples occurring every 20 seconds.

Once all the samples have been collected, the Display Pseudo Journal Data (DSPPSJDTA) command is used to take all the raw data and generate reports that display the estimated disk and CPU resources that would be added if journaling were started for the specified database objects and the monitored changes. Here's an example of the command:

   DSPPSJDTA DTAFILE(QGPL/PSJEST1) FILE(*ALL) RPTTYPE(*SUMMARY)

The DTAFILE parameter must match the same value used on the STRPSJRN command. The FILE parameter allows you to display the journal estimate reports for all the database objects (i.e., *ALL) monitored by the STRPSJRN command, or you can specify individual DB2 table or file names to focus your journal analysis to a smaller set of DB2 objects. The Report Type (RPTTYPE) parameter allows you to select one of three ways to view the journal estimate reports.

The Summary report (*SUMMARY) is probably the easiest report to start with. If you're displaying the journal estimates for multiple database objects, this report will show the journal overhead estimates for all of the DB2 objects. The List report (*LIST) returns the journal overhead estimate for each individual database object.

Here's a snapshot of the more interesting estimates returned by the Summary and List reports:

DISK WRITE SUMMARY==========
Disk Writes                                             4.014 K
Disk Writes W/Caching                         3

JOURNAL STORAGE SUMMARY=======
Total Data                                               353.044 KB
Total Data (W/O Before Image)           348.873 KB (without Before Images)

JOURNAL DISK I/O THROUGHPUT SUMMARY========
Average Throughput                             361 B /s
Maximum Throughput                           4.936 KB/s

PERFORMANCE SUMMARY=======
CPU Overhead                                     48.168 ms
CPU Overhead w/caching                   24.084 ms
.
Added Elapsed Time                           1.204 ms
Added Elapsed Time w/caching         0.001 ms

One key thing to notice in these reports is that not only do you get raw estimates for the disk and CPU resources required by journaling, but you will see that the report also includes more advanced estimates that take into account optional journal settings—for example, how much reduction can occur in the journal disk storage requirements if before images are not journaled or how much disk and CPU performance be improved with Journal Caching (i5/OS licensed feature number 42) installed.

A Histogram report type is also supported, allowing you to see if there are any periods in time when the estimated journal activity would peak severely or if the journal overhead is constant. You should be aware that none of the reports produce a recommend system configuration. The customer is responsible for using these CPU and disk resource estimates to determine whether any system upgrades are needed in order to accommodate journaling on your server.

There's not enough room to go into all of the details of this new toolset, but there's plenty here to get you started. The Pseudo Journal tool can be used on any V5R3 or V5R4 server. IBM does plan to improve the toolset and documentation, so you should visit the Web site on a regular basis. It should be noted that this toolset is not officially supported by IBM, so the toolset is provided to you "as is" without any warranties of any kind.

BLOG COMMENTS POWERED BY DISQUS

LATEST COMMENTS

Support MC Press Online

$0.00 Raised:
$