Sync Your Server 2003 Time

For nearly all servers you don’t really need to worry about configuring this since most servers can keep their time by themselves.

But every once in a while you run in to one of those black sheep servers that seems to lose time every time you turn around.  The particularly annoying thing is that if the server’s time is incorrect, all computers attached to that domain will be incorrect.  This can make troubleshooting difficult if you’re going off of times in logs, and log times are completely wrong.  I ran across such a server today.  I KNOW I have set this server’s time in the past and it seems every time I get back around to checking it, it’s is out of sync by 10, 15, 30 minutes, or even more then an hour!

So after digging around and trying a couple different things, I came across some instructions and a handy utility that got the server’s time sync’ing to the NTP’s time servers reguarlarly to ensure the server never loses time again, which I’ll share with you.

First off, I’ll point you to a program called Atomic Clock Sync.  I like it because it takes away some of the nastyness of dealing with the Windows Time service.  I say some because we’re still going to have to dive in to the registry in the next part where we will actually set up the NTP server settings for the Windows Time service:

1. Change Windows to use the NTP protocol for time synchronization:
Key: HKLM\SYSTEM\CurrentControlSet\Services\W32Time\Parameters
Value: Type
Data: NTP

2. Configure the AnnounceFlags value:
Key: HKLM\SYSTEM\CurrentControlSet\Services\W32Time\Config
Value: AnnounceFlags
Data: 5

3. Enable the NTP server value:
Key: HKLM\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient
Value: Enabled
Data: 1

4. Specify the NTP server to use:
Key: HKLM\SYSTEM\CurrentControlSet\Services\W32Time\Parameters
Value: NtpServer
Data: pool.ntp.org,0x1

5. Select the NTP polling interval:
Key: HKLM\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient
Value: SpecialPollInterval
Data: 900

6. Configure the time correction settings:
Key: HKLM\SYSTEM\CurrentControlSet\Services\W32Time\Config
Value: MaxPosPhaseCorrection
Radix: Decimal
Data: 3600

Key: HKLM\SYSTEM\CurrentControlSet\Services\W32Time\Config
Value: MaxNegPhaseCorrection
Radix: Decimal
Data: 3600

After this, stopping and restarting the NTP service should get you working.

You can easily do this with the handy Atomic Clock tool I linked above.

On the Repair Service tab, click Stop Service.  Then Start Service.  And finally, click Sync Time.

If all went according to plan you should see a message telling you that the time was synced!

That’s it.  Now your pesky Server 2003 box will keep sync with the NTP’s servers, so all of your workstations will stay in sync as well!