暂无图片
暂无图片
暂无图片
暂无图片
暂无图片

【DB2】Reorg表重组中断导致索引重建失败

2119

Problem

SQL1279W error messages might be noticed in the db2diag.log file when a Classic Table Reorganization (offline reorg) is interrupted.


Symptom

Similar error messages will be reported in the db2diag.log:

2010-05-25-13.37.01.757112-240 I172369A888 LEVEL: Error
PID : 262272 TID : 65668 PROC : db2sysc 0
INSTANCE: db2inst1 NODE : 000 DB : SAMPLE
APPHDL : 0-12345 APPID: *LOCAL.db2inst1.100525155705
AUTHID : TEST
EDUID : 12345 EDUNAME: db2agent (SAMPLE) 0
FUNCTION: DB2 UDB, relation data serv, sqlrreorg_table, probe:850
MESSAGE : Remap rc to 1279, Reorg: Recreate index return rc =
-2147221501
DATA #1 : SQLCA, PD_DB2_TYPE_SQLCA, 136 bytes
sqlcaid : SQLCA sqlcabc: 136 sqlcode: 0 sqlerrml: 0
sqlerrmc:
sqlerrp : SQL09054
sqlerrd : (1) 0x00000000 (2) 0x00000000 (3) 0x00000000
(4) 0x00000000 (5) 0x00000000 (6) 0x00000000
sqlwarn : (1) (2) (3) (4) (5) (6)
(7) (8) (9) (10) (11)
sqlstate:

'Remap rc to 1279' leads to "SQL1279W Some indexes may not have been created" and 'rc = -2147221501' leads to "SQL0952N Processing was cancelled due to an interrupt".


Cause

SQL0952N and SQL1279W errors confirm that the table reorg has been interrupted and some of the indexes are not created. A classic table reorganization (offline reorg) rebuilds the indexes during the last phase. The SQL1279W warning messages are highly possible when the reorg is interrupted.


Resolving The Problem

It is recommended not to interrupt the offline reorg process. And the failed indexes will be rebuilt based on the INDEXREC configuration parameter. Once the index rebuild starts, following messages can be observed in the db2diag.log:

2010-05-25-15.59.37.079483-240 E295571A505 LEVEL: Warning
PID : 1675492 TID : 32641 PROC : db2sysc 0
INSTANCE: db2inst1 NODE : 000 DB : SAMPLE
APPHDL : 0-11 APPID: *LOCAL.db2inst1.100525180610
AUTHID : TEST
EDUID : 32641 EDUNAME: db2agntp 0
FUNCTION: DB2 UDB, data management, sqldBeginIndexCreate, probe:1
MESSAGE : ADM5540W Beginning index rebuild of "13" index(es) on table
"TESTSCHEMA.EMPLOYEE"

NOTE
The Select on the table involved may take longer after an interrupted reorg process. This could be possible if there are many indexes to be rebuilt.

「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。

评论