Nonstop Database, HiRDB Version 9 System Operation Guide

[Contents][Index][Back][Next]

20.17.6 Determining the number of records necessary for unit restart

Determine the number of records necessary for unit restart, and then restart the unit. If the number of system log file records is insufficient, the unit cannot be restarted.

Organization of this subsection
(1) Formula for determining the number of records that are needed
(2) Example: determining the necessary size

(1) Formula for determining the number of records that are needed

The formula given below can be used to determine the number of system log file records that are needed for unit restart. If system log files are duplexed, the number of records determined by the formula is needed by both systems A and B.


Number of records needed for unit restart = A [Figure] B + C

A: Number of system log file records that become input files during unit restart

B: Either of the following values:
  • If HiRDB Text Search Plug-in is used: 3
  • If abnormal termination occurred during updatable online reorganization: 3
  • All other cases: 2

C: Either of the following values:
  • If the unit terminated abnormally during updatable online reorganization, and updatable online reorganization is continued after the unit restarts: A [Figure] B + D
    If the unit terminated abnormally due to a system log file shortage during updatable online reorganization: the size of the system log file necessary for completing updatable online reorganization after the unit restarts.
  • All other cases: 0

D: Number of records in the system log files that are in overwriting denied status for online reorganization
The following procedure can be used to determine the number of records in the system log files that are in overwriting denied status for online reorganization:
  1. From the execution result of the pdlogls d- sys command, identify the current system log file and the system log files that are in overwriting denied status for online reorganization (the far right value in the Ex-Status column is r).

    [Figure]

  2. From the execution result of the pdlogls -d sys -e command, total the number of records (the value on the right side of Record-count) for the system log files identified in step 1.

    [Figure]

Database recovery processing executed during unit restart also outputs system logs. The size varies depending on the SQL statement that updated the database and the operation of HiRDB. The formula above is used to estimate the number of records that will be needed, so that no system log file shortage will occur even if the size of the output system logs increases.

(2) Example: determining the necessary size

The method of determining the number of records that will be needed during unit restart is explained using an example.

Example
A system log file shortage occurred at the back-end server bes1, causing the unit to terminate abnormally. This example determines the number of records needed during unit restart.
  • All system log files are in overwriting permitted status for online reorganization.
  • HiRDB Text Search Plug-in is not being used.

Procedure
  1. Check the output content of the KFPS01229-I message.
     
    KFPS01229-I HRDB UNT1 Next bes1 log file restart point, generation number=3, block
                number=15. restart end point, generation number=6, block number=3a2.
                last acquired syncpoint dump 2012/10/20 00:25:06
     
    See syslogfile or the message log file to check the content of the KFPS01229-I message, which was output when the unit terminated abnormally. Information on the system log files that become input files during unit restart is output in the KFPS01229-I message. In this example, system log files of generation numbers 3 through 6 become input files during unit restart.
    Note
    In the following cases, because the unit that was to be restarted terminated abnormally again, the KFPS01229-I message is output two or more times:
    • AUTO or MANUAL1 is specified for the pd_mode_conf operand.
    • The pdstart command was executed after the unit terminated abnormally due to a system log file shortage.
    In these cases, check the KFPS01229-I message, which was output when the unit terminated abnormally the first time.
  2. Execute the pdlogls command to check the information on the system log files.

    [Figure]

    The Gen No. column shows the generation numbers of the system log files. System log files log003 to log006 become input files during unit restart.
  3. Execute the pdlogls command to check the number of system log file records.

    [Figure]

    See the Record-count column for log003 to log006. The number of records in each system log file is displayed in hexadecimal on the right side of the Record-count column.
    Convert the hexadecimal record count to a decimal number to determine the total for log003 to log006.
    System log file name Record count
    Hexadecimal Decimal
    log003 4e1c 19996
    log004 4e1c 19996
    log005 61a4 24996
    log006 61a4 24996
    total -- 89984
  4. Calculate the number of system log file records that are needed during unit restart.
    The number of system log file records that are needed during unit restart is as follows:
    89,984 [Figure] 2 = 179,968 records
    The size of system log files that are needed during unit restart is as follows:
    179,968 [Figure] 4,096 = 737,148,928 bytes
    In the above formula, 4,096 indicates the system log file record length. You can check this in the Record-size column in the execution result in step 3 above.
    The values determined using the above formulas are needed in each system log file. If system log files are duplexed, the above number of records and the size are needed by both systems A and B.