Hitachi

Hitachi Advanced Database Command Reference


17.10.7 If an error occurs during re-execution of the adbimport command

If an error occurs during re-execution of the adbimport command, identify the cause of the error and take the necessary action according to the following procedure.

Procedure

  1. Check whether the KFAA50244-E message has been issued.

    If the KFAA50244-E message has been issued, an access error occurred on a command status file (file under the $DBDIR/ADBSYS/ADBUTL directory). Execute the adbidxrebuild command with the --force option specified. The adbidxrebuild command can inherit index creation processing by the adbimport command.

    For details, see (2) Executing the adbidxrebuild command with the --force option specified.

    If the KFAA50244-E message has not been issued, proceed to either of the following steps.

    • If an index was defined for the table to be processed while the adbimport command was stopped:

      Proceed to step 2.

    • If an index was not defined for the table to be processed while the adbimport command was stopped:

      Proceed to step 3.

  2. Check whether the KFAA50209-E message has been issued.

    If the KFAA50209-E message has been issued, the adbimport command cannot be re-executed because an index in unfinished status exists. Execute the adbidxrebuild command with the --force option specified. The adbidxrebuild command can inherit index creation processing by the adbimport command.

    For details, see (2) Executing the adbidxrebuild command with the --force option specified.

    If the KFAA50209-E message has not been issued, proceed to step 3.

  3. Check whether the KFAA50247-E message has been issued.

    If the KFAA50247-E message has been issued, an access error occurred on a temporary work file. Execute the adbidxrebuild command with the --create-temp-file option specified. The adbidxrebuild command can inherit index creation processing by the adbimport command.

    For details, see (1) Executing the adbidxrebuild command with the --create-temp-file option specified.

    If the KFAA50247-E message has not been issued, proceed to step 4.

  4. Check whether a message other than KFAA50209-E, KFAA50244-E, or KFAA50247-E has been issued.

    Check the message that was issued and identify the cause of the error. After removing the cause of the error, execute the adbimport command.

For an overview of the process during which the adbidxrebuild command inherits index creation processing, see (2) Inheriting index creation processing from the adbimport command in 16.1.3 Optional functions of the adbidxrebuild command.

Organization of this subsection

(1) Executing the adbidxrebuild command with the --create-temp-file option specified

If the KFAA50247-E message has been issued, an access error occurred on a temporary work file. Execute the adbidxrebuild command with the --create-temp-file option specified.

Important
  • Do not delete the command status file (file under the $DBDIR/ADBSYS/ADBUTL directory) for the adbimport command until the executed adbidxrebuild command terminates normally. If there is no command status file when the adbidxrebuild command is executed, an error might occur in the adbidxrebuild command. (The KFAA50244-E message is issued.) In this case, execute the adbidxrebuild command with the --force option specified instead of the --create-temp-file option.

  • It is assumed that the --create-temp-file option of the adbidxrebuild will be specified when there is no temporary work file necessary for re-execution (index record file or sort result file). If the adbidxrebuild command is executed when a temporary work file exists, the existing file will be re-built. However, if you do not have write or read privileges for the applicable file, an access error might occur during execution of the adbidxrebuild command. (The KFAA30959-E, KFAA40204-E, KFAA40205-E, KFAA40214-E, KFAA41205-E, or KFAA41206-I message is issued. 13 (EACCES) is output for the error number.) In such a case, first delete the applicable file using the OS's rm command or a similar method, and then re-execute the adbidxrebuild command.

  • When the --create-temp-file option is specified for the adbidxrebuild command, the adbidxrebuild command is executed, inheriting the content of the options that were specified for the adbimport command. If the -b, -m, or --status wait option was specified, the specified content is also inherited.

    These options cannot be specified for the adbidxrebuild command since they are adbimport command options. These options are only inherited when the --create-temp-file option is specified.

  • After cancelation of the adbidxrebuild command with the --create-temp-file option specified, if the adbidxrebuild command is executed, the command resumes index rebuild processing from the point of table retrieval in the chunk for which processing was canceled, regardless of whether the --create-temp-file option is specified.

The following table shows the information to specify for the adbidxrebuild command when it is executed with the --create-temp-file option specified.

Table 17‒20: Information to specify for the adbidxrebuild command (when the --create-temp-file option is specified)

No.

adbidxrebuild command specification format

Whether options can be changed from the canceled adbimport command

Remarks

1

adbidxrebuild

Specify adbidxrebuild.

--

2

-u authorization-identifier

N

--

3

[-p password]

N

--

4

[-g output-interval-for-index-rebuild-processing-progress-message]

O

--

5

[-w {temporary-work-file-storage-directory-name|name-of-directory-path-file-specifying-temporary-work-file-storage-locations}]

Y

If the disk that stores temporary work files runs out of free space, specify another disk with a larger capacity as the storage destination. For details about the actions to take if the disk that stores temporary work files runs out of free space, see Steps to take in the event of a shortage of disk space for storing temporary work files during command execution in Command-related problems in Troubleshooting in the HADB Setup and Operation Guide.

6

[-z index-rebuild-option-file-name]

Y

For details about the values to be specified for index rebuild options, see Table 17‒21: Index rebuild options that correspond to import options (when the --create-temp-file option is specified).

7

[-i index-identifier-file-name]

There is no need to specify an option. (An option will be ignored even if it is specified.)

Applies to the indexes defined for the table to be processed.

8

[{--create-temp-file|--force}]

Specify --create-temp-file.

--

9

table-to-be-processed

N

--

Legend:

Y: The specification value can be changed from the option of the canceled adbimport command.

O: Option specification is optional.

N: The specification value cannot be changed from the option of the canceled adbimport command.

--: Not applicable

If there are index rebuild options that correspond to the import options you specified when executing the canceled adbimport command, specify values that are close to the values specified for the import options. If you specify for the index rebuild options values that are different from the values specified for the import options, the adbidxrebuild command is executed with the values specified for the index rebuild options.

The following table shows index rebuild options that correspond to import options.

Table 17‒21: Index rebuild options that correspond to import options (when the --create-temp-file option is specified)

No.

Import option

Corresponding index rebuild option

1

adb_import_errdata_file_name

N

2

adb_import_errdata_num

N

3

adb_import_errmsg_lv

N

4

adb_import_rthd_num

adb_idxrebuild_rthd_num#

5

adb_import_read_size

N

6

--

adb_idxrebuild_scan_buff_size

7

adb_import_buff_blk_num

adb_idxrebuild_buff_blk_num

8

adb_import_sort_buff_size

adb_idxrebuild_sort_buff_size

9

adb_import_dividx_rd_buff_size

adb_idxrebuild_dvix_rdbuff_size

10

adb_import_dividx_wt_buff_size

adb_idxrebuild_dvix_wtbuff_size

11

adb_import_txt_buff_size

adb_idxrebuild_txt_buff_size

12

adb_import_decompress_buff_size

N

13

adb_import_null_string

N

Legend:

N: There is no corresponding index rebuild option.

--: There is no applicable import option. Specify a value based on the explanation in the specification guidelines for index rebuild options. For details about the specification guidelines for index rebuild options, see (2) Explanation of specification format in 16.2.2 Format of index rebuild options.

#

If a value smaller than 3 is specified for import option adb_import_rthd_num, specify 3 for index rebuild option adb_idxrebuild_rthd_num.

(2) Executing the adbidxrebuild command with the --force option specified

In the following cases, you need to execute the adbidxrebuild command with the --force option specified.

In these cases, take the necessary action according to the following procedure.

Procedure

  1. Delete the temporary work files.

    Delete the files under the following directories (temporary work files) using the OS's rm command or a similar method. If there are any files for which you do not have write or read privileges, you might not be able to execute the adbidxrebuild command.

    • If the -w option was specified during execution of the previous command that was canceled:

      The temporary work file storage directories specified in the -w option

    • If the -w option was omitted during execution of the previous command that was canceled:

      The $DBDIR/ADBWORK directory

  2. Execute the adbidxrebuild command with the --force option specified.

    Execute the adbidxrebuild command with the --force option specified.

    If the previously canceled command was the adbimport command with background import processing applied (the -b option specified), proceed to step 3. In all other cases, skip step 3.

  3. Execute the adbimport command with the -b option specified.

    After cancellation of the adbimport command with background import processing applied (the -b option specified), executing the adbidxrebuild command with the --force option specified deletes the storage information of table data that was being processed by the adbimport command. Therefore, after the adbidxrebuild command completes, re-execute the canceled adbimport command with the -b option specified.

Important

After the adbidxrebuild command with the --force option specified is canceled, if you re-execute the adbidxrebuild command, index rebuild processing is forcibly re-executed from the beginning even if you do not specify the --force option. Therefore, even if you specify the --create-temp-file option, it is ignored. When index rebuild processing is forcibly re-executed from the beginning, the KAFF80215-I message is issued.

The following table shows the information to specify for the adbidxrebuild command when you execute it with the --force option specified.

Table 17‒22: Information to specify for the adbidxrebuild command (when the --force option is specified)

No.

adbidxrebuild command specification format

Whether options can be changed from the canceled adbimport command

Remarks

1

adbidxrebuild

Specify adbidxrebuild.

--

2

-u authorization-identifier

Y

If the executing user of the adbimport command was deleted or if the IMPORT TABLE privilege was revoked, and as a result the same executing user can no longer execute the adbimport command, take the following action: Execute the adbidxrebuild command by specifying an authorization identifier that has the REBUILD INDEX privilege.

3

[-p password]

Y

If the authorization identifier was changed, specify the password for the authorization identifier.

4

[-g output-interval-for-index-rebuild-processing-progress-message]

O

--

5

[-w {temporary-work-file-storage-directory-name|name-of-directory-path-file-specifying-temporary-work-file-storage-locations}]

Y

If the disk that stores temporary work files runs out of free space, specify another disk with a larger capacity as the storage destination. For details about the actions to take if the disk that stores temporary work files runs out of free space, see Steps to take in the event of a shortage of disk space for storing temporary work files during command execution in Command-related problems in Troubleshooting in the HADB Setup and Operation Guide.

6

[-z index-rebuild-option-file-name]

Y

For details about the values to be specified for index rebuild options, see Table 17‒23: Index rebuild options that correspond to import options (when the --force option is specified).

7

[-i index-identifier-file-name]

There is no need to specify an option. (An option will be ignored even if it is specified.)

Applies to the indexes defined for the table to be processed.

8

[{--create-temp-file|--force}]

Specify --force.

--

9

table-to-be-processed

N

--

Legend:

Y: The specification value can be changed from the option of the canceled adbimport command.

O: Option specification is optional.

N: The specification value cannot be changed from the option of the canceled adbimport command.

--: Not applicable

If there are index rebuild options that correspond to the import options specified when executing the canceled adbimport command, specify values that are close to the values specified for the import options. If you specify for the index rebuild options values that are different from the values specified for the import options, the adbidxrebuild command is executed with the values specified for the index rebuild options.

The following table shows index rebuild options that correspond to import options.

Table 17‒23: Index rebuild options that correspond to import options (when the --force option is specified)

No.

Import option

Corresponding index rebuild option

1

adb_import_errdata_file_name

N

2

adb_import_errdata_num

N

3

adb_import_errmsg_lv

N

4

adb_import_rthd_num

adb_idxrebuild_rthd_num#

5

adb_import_read_size

N

6

--

adb_idxrebuild_scan_buff_size

7

adb_import_buff_blk_num

adb_idxrebuild_buff_blk_num

8

adb_import_sort_buff_size

adb_idxrebuild_sort_buff_size

9

adb_import_dividx_rd_buff_size

adb_idxrebuild_dvix_rdbuff_size

10

adb_import_dividx_wt_buff_size

adb_idxrebuild_dvix_wtbuff_size

11

adb_import_txt_buff_size

adb_idxrebuild_txt_buff_size

12

adb_import_decompress_buff_size

N

13

adb_import_null_string

N

Legend:

N: There is no corresponding index rebuild option.

--: There is no applicable import option. Specify a value based on the explanation in the specification guidelines for index rebuild options. For details about the specification guidelines for index rebuild options, see (2) Explanation of specification format in 16.2.2 Format of index rebuild options.

#

If a value smaller than 3 is specified for import option adb_import_rthd_num, specify 3 for index rebuild option adb_idxrebuild_rthd_num.