informix資料庫頁故障的處理方法

tonykorn97發表於2008-08-28
1,在做資料庫全備的時候出現下列錯誤:
16:28:45 Assert Warning: Archive detects that page 7:45157032 is corrupt.
16:28:45 IBM Informix Dynamic Server Version 10.00.UC4
16:28:45 Who: Session(3535, , 15099, 0xbb97f724)
Thread(4372, arcbackup1, baeaaa20, 4)
File: rsarcbu.c Line: 2953
16:28:45 stack trace for pid 10517 written to /home/informix/tmp/af.14fcbebc
16:28:45 See Also: /home/informix/tmp/af.14fcbebc
16:28:45 Archive detects that page 7:45157032 is corrupt.
16:28:45 Assert Warning: Archive detects that page 7:45157033 is corrupt.
16:28:45 IBM Informix Dynamic Server Version 10.00.UC4
16:28:45 Who: Session(3535, , 15099, 0xbb97f724)
Thread(4372, arcbackup1, baeaaa20, 4)
File: rsarcbu.c Line: 2953
16:28:45 stack trace for pid 10517 written to /home/informix/tmp/af.14fcbebc
16:28:45 See Also: /home/informix/tmp/af.14fcbebc
16:28:45 Archive detects that page 7:45157033 is corrupt.[@more@]



2,執行oncheck -pe 檢測這個頁所屬的資料空間
[informix@tonykorn ~]$ oncheck -pe datadbs2 > datadbs2_oncheck_20080827.log
[informix@tonykorn ~]$

3,根據日誌內容檢視當時錯誤頁所屬的表:
rrldbshop:'informix'.pdykcostitem 45143269 2048
rrldbshop:'informix'.pdgoodscost 45145317 8192
rrldbshop:'informix'.syslog 45153509 8192
rrldbshop:'informix'.pdgoodsitem 45161701 8192

透過上面可以得到45157032和45157033的頁都屬於syslog表


4,執行oncheck -cd 檢測一下這個表的資訊
[informix@tonykorn ~]$ oncheck -cd rrldbshop:syslog

TBLspace data check for rrldbshop:informix.syslog

BAD PAGE 7:45157136: pg_addr 0:0 != bp->bf_pagenum 7:45157136
BAD PAGE 7:45157137: pg_addr 0:0 != bp->bf_pagenum 7:45157137
BAD PAGE 7:45157138: pg_addr 0:0 != bp->bf_pagenum 7:45157138
BAD PAGE 7:45157139: pg_addr 0:0 != bp->bf_pagenum 7:45157139
BAD PAGE 7:45157140: pg_addr 0:0 != bp->bf_pagenum 7:45157140
BAD PAGE 7:45157141: pg_addr 0:0 != bp->bf_pagenum 7:45157141
BAD PAGE 7:45157142: pg_addr 0:0 != bp->bf_pagenum 7:45157142
BAD PAGE 7:45157143: pg_addr 0:0 != bp->bf_pagenum 7:45157143
BAD PAGE 7:45157144: pg_addr 0:0 != bp->bf_pagenum 7:45157144
BAD PAGE 7:45157145: pg_addr 0:0 != bp->bf_pagenum 7:45157145
BAD PAGE 7:45157146: pg_addr 0:0 != bp->bf_pagenum 7:45157146
BAD PAGE 7:45157147: pg_addr 0:0 != bp->bf_pagenum 7:45157147
BAD PAGE 7:45157148: pg_addr 0:0 != bp->bf_pagenum 7:45157148
BAD PAGE 7:45157149: pg_addr 0:0 != bp->bf_pagenum 7:45157149
BAD PAGE 7:45157150: pg_addr 0:0 != bp->bf_pagenum 7:45157150
BAD PAGE 7:45157151: pg_addr 0:0 != bp->bf_pagenum 7:45157151
BAD PAGE 7:45157152: pg_addr 0:0 != bp->bf_pagenum 7:45157152

5,看看是否能檢視這個表的資料,然後把這個表的內容匯出後重新匯入。

來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/312079/viewspace-1009781/,如需轉載,請註明出處,否則將追究法律責任。

相關文章