15.00 - Checksum Fields - Teradata Database

Teradata Database Utilities

Product
Teradata Database
Release Number
15.00
Content Type
Configuration
Publication ID
B035-1102-015K
Language
English (United States)
Last Update
2018-09-25

Checksum Fields

Checksums can be used to check the integrity of Teradata Database disk I/O operations. A checksum is a calculated numeric value computed from a given set of data, or specific portions of the data. For a given set of data, the checksum value will always be the same, provided the data is unchanged.

Checksums can be used to detect when there are errors in disk I/O operations. When checksums are enabled, and data is initially read, a checksum is calculated for the data and stored in the system. When the same data is subsequently read, the checksum is recalculated and compared to the original checksum value. Differing checksum values for a given set of data indicate an inconsistency in the data, most often due to errors in disk I/O operations.

Because calculating checksums requires system resources, and may affect system performance, the checksum feature is usually enabled only when disk corruption is suspected.

 

Checksum Levels

Checksum levels define different data sampling percentages that are used to calculate the checksum value. For example, a checksum level of 2% uses 2% of the bytes that are read in a single I/O to calculate the checksum for the data read. Because higher sampling percentages use more of the data to calculate the checksum, they are more likely to detect errors that smaller sampling rates might miss. However, higher sampling percentages are also more computationally intense, requiring more system resources, and therefore are likely to affect system performance to a greater degree.

Use the Checksum Level Definitions fields of DBS Control (Checksum fields 7 through 9) to customize the LOW, MEDIUM, and HIGH checksum levels. The NONE and ALL levels are fixed at 0% sampling (checksums are disabled) and 100% sampling (checksums calculated based on every byte of data), respectively. The default definitions for LOW, MEDIUM, and HIGH are listed below.

Checksum levels are selectable based on table types. You can select from the following checksum levels:

 

Checksum Level

Description

NONE

Checksums are disabled for classes of tables for which the checksum level is NONE. The definition of this level cannot be changed.

LOW

Checksum calculations use a low percentage of the data read to generate a checksum value. The default is 2%. The valid range is 1 - 100%.

MEDIUM

Checksum calculations use a medium percentage of the data read to generate a checksum value. The default is 33%. The valid range is 1 - 100%

HIGH

Checksums calculations use a high percentage of the data read to generate a checksum value. The default is 67%. The valid range is 1 - 100%.

ALL

100% of the data read is used to generate a checksum value of tables for which the checksum level is ALL. The definition of this level cannot be changed.

Enabling Checksums

Use the Checksum Levels fields of DBS Control (Checksum fields 1 through 6) to set checksum levels for these six classes of tables:

  • System
  • System Journal
  • System Logging
  • User
  • Permanent Journal
  • Temporary
  • These table classes are described in the sections that follow.

    Note: Setting a checksum level for Checksum field 0 applies the specified checksum level to all classes of tables.

    Examples  

     _______
        |                                |              |
        |    ___     __     ____         |    ____    __|__    ____
        |   /      |/  \    ____|    ____|    ____|     |      ____|
        |   ---    |       /    |   /    |   /    |     |     /    |
        |   \___   |       \____|   \____|   \____|     |__   \____|
     
        Release 14.00.00.00 Version 14.00.00.00
        DBSControl Utility (Dec 99)
     
    The current DBS Control GDO has been read.
    Enter a command, HELP, or QUIT:

    modify checksum 6 = medium
    The Temporary Tables field has been modified to MEDIUM
    NOTE: This change will become effective after the DBS Control Record
           has been written.

    m c 0=none
    The System Tables field has been modified to NONE
    The System Journal Tables field has been modified to NONE
    The System Logging Tables field has been modified to NONE
    The User Tables field has been modified to NONE
    The Permanent Journal Tables field has been modified to NONE
    The Temporary Tables field has been modified to NONE
    NOTE: This change will become effective after the DBS Control Record
           has been written.
     

    Enabling Checksums on Individual Tables

    To enable or display checksums on individual tables, use the CHECKSUM option of the following Teradata SQL statements:

  • CREATE TABLE
  • CREATE JOIN INDEX
  • CREATE HASH INDEX
  • ALTER TABLE
  • SHOW TABLE
  • SHOW JOIN INDEX
  • SHOW HASH INDEX
  • For more information on these statements, see SQL Data Definition Language.