3

I do have two different Windows VM guests that seem to be drifting time seriously, reaching an offset of 10-15 seconds in less than a week.

Both the Windows guests and the XenServer 6.5 host are configured to update the time from the same internal ntp server.

[root@xshost ~]# ntpq -c peers && hwclock --show && date
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
*cbg-inf-bck-01- 10.70.160.68     4 u  659 1024  377    1.890    3.700   1.336
+clock.cmm.xxx-t 10.70.160.68     4 u  542 1024  377    1.235   14.060   0.167
 LOCAL(0)        .LOCL.          10 l   15   64  377    0.000    0.000   0.001
Wed 08 Jul 2015 09:14:21 BST  -0.877194 seconds
Wed Jul  8 09:14:38 BST 2015

The graphs shows you the two problematic Windows guests and another Linux machine. enter image description here

So why is this happening and how can I prevent it from happening?

Note: these machines are not part of any domain and I do no want to join them into a domain just to fix the drifting clock issue.

sorin
  • 8,016
  • 24
  • 79
  • 103

1 Answers1

1

I seems that Windows lacks the ability to synchronize time often enough and the easiest way to solve the problem was by installing nettime via:

choco install nettime

Nothing else was needed, it did manage to fix the problem without me having to configure anything on the machine, let's hope it will run as a service.

Details https://chocolatey.org/packages/nettime

sorin
  • 8,016
  • 24
  • 79
  • 103
  • 1
    As you've discovered, the Windows Time service wasn't designed for high accuracy. - http://blogs.technet.com/b/askds/archive/2007/10/23/high-accuracy-w32time-requirements.aspx – joeqwerty Jul 08 '15 at 17:21
  • 1
    You can adjust all that through [W32Time Global Configuration Settings](http://blogs.msdn.com/b/w32time/archive/2009/02/02/group-policy-settings-explained.aspx) in Group Policy or possibly Local Policy. – mortenya Jul 10 '15 at 23:59
  • Considering that issue is present on various different versions of window and they moved all of these all around, I would not consider it as an acceptable solution, as it clearly cannot easily be automated. My option, while is does install a 3rd party software still works with one command, perfect to automate. – sorin Jul 12 '15 at 12:29