Synchronizing Windows slave time with the server

Background

A number of Hudson builds failed today due to time-synchronization issues between the Hudson server and Windows slave box. Synchronizing the time with our Windows domain controller didn’t seem to help, so I resorted to synchronizing the time on the slave box with the Hudson server itself using NetTime.

Configuration

The installation is straightforward, and you should accept the defaults. You will be prompted to install a service:

 

 

 

 

 

Then configure it:

 

 

 

 

 

 

You’ll want NetTime to synchronize with:

  • Server: Time Server
  • Protocol: SNTP
  • Port: 123

Not out of the woods yet

We had another time-sync-related build failure on uifactory this morning . This is in spite of the fact that slave box syncs itself every 10 minutes.

I did a little testing and data capture, and discovered that in 4 minutes, the Windows machine clock drifted by more than 30 seconds! Here’s the information. Note the time that the slave box was synchronized, the “current” time on the server and the “current” time on the slave box:

In table form:

SeRVER time SlAVE time
09:12:01 09:12:01 Set slave clock from server
09:16:00 09:15:28 Alarming time drift

As a fix/work-around/hack, I’ve set the slave box to sync with the server every 60 seconds.

It's only fair to share...
Share on FacebookGoogle+Tweet about this on TwitterShare on LinkedIn

Leave a Reply