Time stamp difference between different machines

Topics: General
Jun 16, 2014 at 7:21 PM
My team owns a few services that runs on multiple domain joined servers (physical as well as VMs). We uses semantic logging out of process service to capture out ETW tracing and send them to an endpoint (SQL Azure) for processing. However when we correlate traces from multiple servers, we often found that event’s time stamp from different servers differ greatly even though those events can only happen at the same time. Sometimes we have seen time difference between servers can be as big as couple hours. I know windows is not meant to be a real time OS but the time drift is still a bit too big to me.

We have tried a couple things such as config the time source with time.windows.com, shorten the resync interval in registry, but none of these seem to be a permanent fix. We still see time difference between servers sometimes greater than an hour. And this is not limited to VMs, physical machines are having the same problem as well. We are working around the issue by putting an auto column on our SQL Azure database as the time stamp instead of relying on the timestamp on the source, but that won’t work once we move our endpoint to Azure table instead of SQL Azure.

What’s everyone else’s experience? I would have thought this is something pretty common, but surprisingly my Bing search didn’t turn up anything specific. Would love to see if there are any existing solutions or best practice we can leverage.
Jun 17, 2014 at 6:30 AM
That's strange that you are seeing such a wide disparity in server times. Could the time zone settings be incorrect causing the issue?

Randy Levy
Enterprise Library support engineer
Support How-to
Jun 19, 2014 at 1:17 AM
The timezone is included in the timestamp in the log entry (2014-05-09 17:54:06.0242275 -07:00 for example) so it's already factored in when I mention time difference. I looked into the SLAB source code. The timestamp is coming from a simple DateTime.Now call which is completely reasonable.

Am I the only one having this issue? I am open to suggestions as to where I should look.