db2 reorg table failed处理

由于reorg table 失败导致的告警排查处理

$ db2 reorg table RMADMIN.RMMIGRATIONTASKS index SYSIBM.SQL120321193909130   use tempspace3

加参数use tablespaceName 指定表空间。不指定表空间,默认为reorg表所在表空间。

查询db2diag报错提示如下

MESSAGE : ZRC=0x85020021=-2063466463=SQLB_END_OF_CONTAINER 
"DMS Container space full"


ADM6044E The DMS tablespace "BASEDBS" (ID "3") is full

 符合报错信息为BASEDBS表空间所有表

Cause
If the SQL0289N is also reported at around the time of the DMS full error, then this suggests that the rebalance may be preventing an autoresize. In the SQL0289N error message reference, reasons 3 and 11 are relevant in this scenario:

**********

SQL0289N
Unable to allocate new pages in table space tablespace-name.
Explanation

3
A rebalance is in progress, but has not progressed far enough to enable the newly added space to be used. 

Diagnosing the problem

Look for a SQL0289N error in the db2diag.log file.

Collect a tablespace snapshot for that DMS tablespace, and check whether the "Last resize attempt failed = Yes"

db2pd -db UIDBSDNX -tablespaces
 db2 list utilities show detail 可以监控 LOAD ,BACKUP ,RESTORE, RUNSTATS
db2pd -reorgs index

监视表重组:

select
       substr(tabname, 1, 15) as tab_name,
       substr(tabschema, 1, 15) as tab_schema,
       reorg_phase,reorg_max_phase,
       substr(reorg_type, 1, 20) as reorg_type,
       reorg_status,
       reorg_completion,
       dbpartitionnum
     from sysibmadm.snaptab_reorg
     order by dbpartitionnum
或者

db2 GET SNAPSHOT FOR TABLES on DBName

db2 list history reorg all for DBName

db2pd -db DBName -reorgs index

总结

数据库在进行reorg时失败,无法分配新的页,表空间方面可能存在问题,需要扩充表空间或reorg表时重新指定表空间。

 http://www-01.ibm.com/support/docview.wss?uid=swg21398648

猜你喜欢

转载自www.cnblogs.com/dahaoran/p/9254744.html