I am migrating client's database to my hosted environment, the client runs SQL Server 2008 R2, and we run SQL Server 2014.

I am stuck on restoring one log file, which left below error message when I restore it:

Restoring files
Error Message: System.Data.SqlClient.SqlException (0x80131904): SQL Server detec
ted a logical consistency-based I/O error: incorrect checksum (expected: 0x512cb
ec3; actual: 0x512dbec3). It occurred during a read of page (1:827731) in databa
se ID 49 at offset 0x000001942a6000 in file 'F:\MSSQL12.INSTANCE9\MSSQL\Data\Ody
sseyTSIAKL_Data.mdf'.  Additional messages in the SQL Server error log or system
 event log may provide more detail. This is a severe error condition that threat
ens database integrity and must be corrected immediately. Complete a full databa
se consistency check (DBCC CHECKDB). This error can be caused by many factors; f
or more information, see SQL Server Books Online.
RESTORE LOG is terminating abnormally.
   at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolea
n breakConnection, Action`1 wrapCloseInAction)
   at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception
, Boolean breakConnection, Action`1 wrapCloseInAction)
   at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObj
ect stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)
   at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand
 cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler,
TdsParserStateObject stateObj, Boolean& dataReady)
   at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()
   at System.Data.SqlClient.SqlDataReader.get_MetaData()
   at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, Run
Behavior runBehavior, String resetOptionsString)
   at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBe
havior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 time
out, Task& task, Boolean asyncWrite, SqlDataReader ds)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehav
ior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletio
nSource`1 completion, Int32 timeout, Task& task, Boolean asyncWrite)
   at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehav
ior, RunBehavior runBehavior, Boolean returnStream, String method)
   at System.Data.SqlClient.SqlCommand.ExecuteScalar()
   at OnBoardingTrnRestore.FileRestorer.FileIsRestored(SqlConnection connection,
 String sourceBackupFileName, String sourceDatabaseName, String destinationDatab
aseName, String databaseName, String strFileName) in c:\Dev\WiseCloud\OnBoarding
TrnRestore\OnBoardingTrnRestore\FileRestorer.cs:line 223

I have run restore filelistonly and verifyonly in both client and my box, and both worked well:

XXX_Data D:\Program Files (x86)\XXX\Data\YYY_Data.mdf

restore filelistonly:

70922469376 35184372080640
1 0  0 00000000-0000-0000-0000-000000000000
0 0  0 512 1
NULL 279441000014839500242
66CC6D17-575C-41E5-BB58-3FB4D33E288C  0 1 NULL
XXX_Log E:\Program Files (x86)\XXX\Log\YYY_Log.ldf
L NULL  31985762304 35184372080640
2 0  0 00000000-0000-0000-0000-000000000000
0 0  0 512 0
NULL 0  00000000-0000-0000-0000-000000000000 0

restore verifyonly:

Attempting to restore this backup may encounter storage space problems. Subsequent messages will provide details.
The path specified by "D:\Program Files (x86)\XXX\Data\YYY_Data.mdf" is not in a valid directory.
Directory lookup for the file "E:\Program Files (x86)\XXX\Log\YYY_Log.ldf" failed with the operating system error 3(The system cannot find the path specified.).
The backup set on file 1 is valid.

Dbcc checkdb also confirmed there is no error in client sql server database.

dbcc checkdb (XXX, NOINDEX) 

Results as follows:
DBCC results for 'XXX'.
Warning: NO_INDEX option of checkdb being used. Checks on non-system indexes will be skipped.
Service Broker Msg 9675, State 1: Message Types analyzed: 17.
Service Broker Msg 9676, State 1: Service Contracts analyzed: 9.
Service Broker Msg 9667, State 1: Services analyzed: 7.
Service Broker Msg 9668, State 1: Service Queues analyzed: 7.
Service Broker Msg 9669, State 1: Conversation Endpoints analyzed: 0.
Service Broker Msg 9674, State 1: Conversation Groups analyzed: 0.
Service Broker Msg 9670, State 1: Remote Service Bindings analyzed: 0.
Service Broker Msg 9605, State 1: Conversation Priorities analyzed: 0.
DBCC results for 'sys.sysrscols'.
There are 23808 rows in 350 pages for object "sys.sysrscols".
DBCC results for 'BMBoard'.
There are 0 rows in 0 pages for object "BMBoard".
DBCC results for 'CusOutturnHeader'.
There are 0 rows in 0 pages for object "CusOutturnHeader".
CHECKDB found 0 allocation errors and 0 consistency errors in database 'XXX'.
DBCC execution completed. If DBCC printed error messages, contact your system administrator.

We use ftp to transfer the log files from the another country to here, I confirmed the file's MD5(checksum) is same as the copy in client's environment, we have tried to upload the file a couple of times, same outcome.

The full backup is fine, I have successfully restored a series log backups prior to this file.

Has anyone seen this issue before? It is strange, all information indicates the file is good,but somehow it goes wrong.

Below are the version details:


MICROSOFT SQL SERVER 2008 R2 (SP2) - 10.50.4000.0 (X64) 
My environment:

Microsoft SQL Server 2014 - 12.0.2480.0 (X64) 
Jan 28 2015 18:53:20 
Copyright (c) Microsoft Corporation
Enterprise Edition (64-bit) on Windows NT 6.3 <X64> (Build 9600: )
  • 1
    Have you tried restoring it to SQL Server 2008 R2 at your end? – Max Vernon Apr 7 '15 at 2:32
  • We don't have SQL Server 2008 R2 installed. but I think I can find the installation file, will give it a try – AlbertZOZ Apr 7 '15 at 4:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.