locked
Peer to Peer sync getting UInt64 out of range error RRS feed

  • Question

  • Have a custom sync service in place for about 12 months now.  Peer to Peer, has been running fine.  Servers were changed over to a clustered environment about a month ago, sync service reinstalled and pointed to new SQL Server, ran fine for a little over a week, then started getting the following error:

    'Value was either too large or too small for a UInt64' at 'System.Convert.ToUInt64(Int64 value)'

    Sql2008 db to Sql2008 db, same server instance.  Using Sync Framework 2.0 SDK.  Using de-coupled tracking, no automatic change tracking in use.

    Sync service is running on a seperate machine (Windows Service is on Windows Server 2003).  Have tried installing the service on same machine as the databases, resulting in same error messages, so no issues with connectivity to db's, firewall issues, etc.

    Appears to be happening as soon as SyncOrchestrator.Synchronize() is called.  Strange thing is, not seeing the error on all tables in my scope, but most.  Believe it is happening on any tables where there are actually changes to be synced.  Seems to be an datetime anchor conversion problem, but it's deep down in in Framework and hard to trace.  Have looked at event logs to try to determine if anything has changed on either server around the time sync started failing.  Trying to figure out if error is server configuration related, possibly SQL Server settings have changed, or actually data related. 

    Error call stack:

    at System.Convert.ToUInt64(Int64 value)

    at System.Int64.System.IConvertable.ToUInt64(IFormatProvider provider)

    at System.Convert.ToUInt64(Object value, IFormatProvider provider)

    at Microsoft.Synchronization.Data.DbDataReaderHandler.BuildUpdateVersion()

    at Microsoft.Synchronization.Data.DbDataReaderHandler.get_UpdateVersion()

    at Microsoft.Synchronization.Data.RelationalSyncProvider.GetRowEnumerationState(DbDataReaderhandler readerHandler....

    at Microsoft.Synchronization.Data.RelationalSyncProvider.EnumerateChangesInternal(DbSyncScopeMetadata, DbSyncSession...

    at Microsoft.Synchronization.Data.RelationalSyncProvider.GetChanges(DbSYncScopeMetadata scopeMetadata, SyncKnowledge....

    Any help appreciated.

    Thursday, June 16, 2011 12:33 AM

All replies

  • can you try enabling the Sync Fx tracing? are you using DateTime as anchors for change tracking?
    Thursday, June 16, 2011 1:40 AM
  • Thanks for the reply.

    I have never used Sync Fx tracing, I'll take a look and see if I can include.

    Anchors are timestamps.  Have a scope_info table in each database, with one row for each table to be synced with a scope_timestamp column.

    Each table that syncs has a related {tablename}_tracking table as well.  One anchor (local_update_peer_timestamp) is also a timestamp.  Others are BigInt (scope_update_peer_timestamp, scope_create_peer_timestamp, local_create_peer_timestamp).

    Believe I based off of a peer to peer example provided by Microsoft, but it's been a while.

    Will let you know when I have tracing included so I can provide you with more info.

    Thanks

     

    Thursday, June 16, 2011 3:14 AM
  • Hi,

    Did you find a workaround for this?


    gladson
    Tuesday, July 26, 2011 9:15 AM