Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 Data Corruption Issues
 Database consistency errors

Author  Topic 

aparks
Starting Member

2 Posts

Posted - 2006-02-15 : 11:33:32
Hi all,

Would appreciate your words of wisdom on the errors below. It's SQL Server 2000 SP3 on Windows 2000. We had hardware problems on one of the disks in the array the data files are on, which precipitated a number of errors in the Application Event log:

Event ID 17052,MSSQLSERVER,Error: 823, Severity: 24, State: 2 I/O error (torn page) detected during read at offset 0x000002ed448000 in file 'E:\SQLDATA2\XDB_Data.MDF'.

Running DBCC CHECKDB resulted in the following:

Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1901458048, index ID 0: Page (1:1534500) could not be processed. See other errors for details.
Server: Msg 8939, Level 16, State 1, Line 1
Table error: Object ID 1901458048, index ID 0, page (1:1534500). Test (IS_ON (BUF_IOERR, bp->bstat) && bp->berrcode) failed. Values are 2057 and -1.
DBCC results for 'XDB'.
DBCC results for 'sysobjects'.
There are 328 rows in 18 pages for object 'sysobjects'.
DBCC results for 'sysindexes'.
There are 843 rows in 56 pages for object 'sysindexes'.
DBCC results for 'syscolumns'.
There are 4018 rows in 98 pages for object 'syscolumns'.
DBCC results for 'systypes'.
There are 26 rows in 1 pages for object 'systypes'.

<snip lots more successful checks>

DBCC results for 'tblXMLListsRecords'.
There are 3302391 rows in 79187 pages for object 'tblXMLListsRecords'.
CHECKDB found 0 allocation errors and 2 consistency errors in table 'tblXMLListsRecords' (object ID 1901458048).
DBCC results for 'tblPhotosFolder'.
There are 6121 rows in 228 pages for object 'tblPhotosFolder'.
DBCC results for 'tblImageUpload'.
There are 5 rows in 1 pages for object 'tblImageUpload'.
DBCC results for 'tblLogs'.
There are 2049298 rows in 50892 pages for object 'tblLogs'.
CHECKDB found 0 allocation errors and 2 consistency errors in database 'XDB'.
repair_allow_data_loss is the minimum repair level for the errors found by DBCC CHECKDB (XDB ).
DBCC execution completed. If DBCC printed error messages, contact your system administrator.


So the questions are - what does the first error mean (the table error)? And does a report of 2 consistency errors in tblXMLListRecords mean that we will lose two records? We have a backup but it would mean losing today's work if we went back to it - admittedly not much, but I'd like to be able to make an informed choice as to whether repairing the database or restoring it would be favourite. Any thoughts gratefully received!

I've also taken a backup of the corrupted database, restored it to another server and run
DBCC CHECKDB ('XDB',REPAIR_ALLOW_DATA_LOSS) with the following results. So now I'm thinking restoring from backup is probably best after all - correct?

DBCC results for 'XDB'.
DBCC results for 'sysobjects'.
There are 329 rows in 18 pages for object 'sysobjects'.
DBCC results for 'sysindexes'.
There are 843 rows in 56 pages for object 'sysindexes'.
DBCC results for 'syscolumns'.
There are 4018 rows in 95 pages for object 'syscolumns'.

<snip successful checks>

DBCC results for 'tblMenus'.
There are 0 rows in 1 pages for object 'tblMenus'.
DBCC results for 'tblImageProcessingFilenames'.
Server: Msg 8928, Level 16, State 1, Line 1
Object ID 1901458048, index ID 0: Page (1:1534500) could not be processed. See other errors for details.
Server: Msg 8939, Level 16, State 1, Line 1
Table error: Object ID 1901458048, index ID 0, page (1:1534500). Test (IS_ON (BUF_IOERR, bp->bstat) && bp->berrcode) failed. Values are 2057 and -1.
Server: Msg 8978, Level 16, State 1, Line 1
Table error: Object ID 1901458048, index ID 1. Page (1:1180423) is missing a reference from previous page (1:1534500). Possible chain linkage problem.
Server: Msg 8976, Level 16, State 1, Line 1
Table error: Object ID 1901458048, index ID 1. Page (1:1534500) was not seen in the scan although its parent (1:1243134) and previous (1:1232752) refer to it. Check any previous errors.
There are 687 rows in 188 pages for object 'tblImageProcessingFilenames'.
DBCC results for 'tblData15C69B09E60A4DC5B19D8C8BD69E6C15'.
There are 842 rows in 23 pages for object 'tblData15C69B09E60A4DC5B19D8C8BD69E6C15'.
DBCC results for 'tblDataLinksChild15C69B09E60A4DC5B19D8C8BD69E6C15'.
There are 848 rows in 24 pages for object 'tblDataLinksChild15C69B09E60A4DC5B19D8C8BD69E6C15'.
DBCC results for 'tblUpdateFields'.
There are 1 rows in 3 pages for object 'tblUpdateFields'.
DBCC results for 'tblData1FDBC8FBD862435E8AD7C648F37F6D3A'.
There are 5 rows in 1 pages for object 'tblData1FDBC8FBD862435E8AD7C648F37F6D3A'.
DBCC results for 'tblDataLinksChild1FDBC8FBD862435E8AD7C648F37F6D3A'.
There are 5 rows in 1 pages for object 'tblDataLinksChild1FDBC8FBD862435E8AD7C648F37F6D3A'.
DBCC results for 'tblXML031029'.
There are 83683 rows in 3331 pages for object 'tblXML031029'.
DBCC results for 'tblXMLListsRecords'.
The error has been repaired.
The error has been repaired.
The error has been repaired.
The error has been repaired.
Repair: Page (1:1534500) has been deallocated from object ID 1901458048, index ID 0.
Clustered index successfully restored for object 'dbo.tblXMLListsRecords' in database 'XDB'.
There are 3302279 rows in 79187 pages for object 'tblXMLListsRecords'.
CHECKDB found 0 allocation errors and 4 consistency errors in table 'tblXMLListsRecords' (object ID 1901458048).
CHECKDB fixed 0 allocation errors and 4 consistency errors in table 'tblXMLListsRecords' (object ID 1901458048).
DBCC results for 'tblPhotosFolder'.
There are 6109 rows in 224 pages for object 'tblPhotosFolder'.
DBCC results for 'tblImageUpload'.
There are 5 rows in 1 pages for object 'tblImageUpload'.
DBCC results for 'tblLogs'.
There are 2048554 rows in 50870 pages for object 'tblLogs'.
CHECKDB found 0 allocation errors and 4 consistency errors in database 'XDB'.
CHECKDB fixed 0 allocation errors and 4 consistency errors in database 'XDB'.
DBCC execution completed. If DBCC printed error messages, contact your system administrator.


Please let me know if there is anything else I should post - many thanks in advance.

paulrandal
Yak with Vast SQL Skills

899 Posts

Posted - 2006-02-15 : 11:42:42
Your disk problems have caused a database page to go bad. The repair for this is to delete the entire page, and so you'll lose all records on that page. Given that this is a heap data page, there's no redundancy for these records.

It depends what is stored in the table in question. Given that the page is inaccessible, and its an unordered heap, you won't be able to tell what rows you're going to lose. If you can cope with losing/redoing today's work I would restore from your backup (and well done for having one).

Regards

Paul Randal
Lead Program Manager, Microsoft SQL Server Storage Engine
(Legalese: This posting is provided "AS IS" with no warranties, and confers no rights.)
Go to Top of Page

aparks
Starting Member

2 Posts

Posted - 2006-02-15 : 11:51:25
That was quick! Thanks Paul - much appreciated.
Go to Top of Page
   

- Advertisement -