Windows Server, Configuring Windows NTP Server

Configuring Windows as a NTP Server

The Windows operating systems from Windows 2000 onwards has an in-built time synchronization service – ‘Windows Time’. The Windows Time service facilitates a Windows network to provide synchronization of all machines within a domain. This article describes how to configure the Windows 2000 and Windows 2003 time service as a NTP server. It shows how to manipulate registry entries to configure the Windows Time Service.

Before modifying registry entries it is good practice to backup the Windows registry. This allows the registry to be restored in the event of problems.

Windows 2000 Configuration

Windows 2000 has an integrated time synchronization service, installed by default, which can synchronize to a NTP Server. Indeed, by manipulating registry settings, the service can act as both an SNTP client and SNTP server to synchronize other network clients.

The ‘Windows Time’ service should be present in the systems service list. The application executable is ‘w32time.exe’. The parameter list for w32time can be found in the registry at: HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeParameters

Windows 2000 can operate as an NTP client and synchronize to an NTP server by setting parameter ‘NTP Server’ to the IP address of a NTP Server.

By default, the Windows 2000 machine will synchronize to the specified NTP server every 8 hours (or 3 times a day), which may not be enough to maintain accurate synchronization. The period can be reduced by setting the ‘Period’ parameter to how many times a day synchronization is required. Setting the period to 48 will activate synchronization with the NTP server once every half hour.
Windows 2000 can also be configured to act as an NTP server by setting the ‘Local NTP’ parameter to ‘1′.

After editing any of the registry entries for the windows time service, the service must be restarted for the settings to take effect. The services can be started or stopped from the service control applet in ‘administrative tools’. Alternatively the service can be controlled via the DOS net command thus:

net start w32time
net stop w32time

Windows 2003 Configuration

Windows 2003 has expanded on the original Windows 2000 time service by providing a true NTP implementation. The time service, installed by default, can synchronize to a NTP Server. Indeed, by manipulating registry settings for the service it can act as both an NTP server and client to synchronize other network clients in the domain.

The ‘Windows Time’ service should be present in the systems service list. The application executable is ‘w32time.exe’. The parameter list for w32time can be found in the registry at:
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32Time

To configure a Windows 2003 machine to synchronize to an external NTP server, edit the following registry entries:
HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeParametersType
Change the server type to NTP by specifying ‘NTP’ in the ‘Type’ registry entry.

HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeConfigAnnounceFlags
Set the ‘Announce Flags’ registry entry to 5, to indicate a reliable time source.

HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeTimeProvidersNTPClientSpecialPollInterval
The ‘Special Poll Interval’ registry entry defines the period in seconds that the Windows 2003 machine should poll the NTP server. A recommended value is 900 seconds, which equates to every 15 minutes.

HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeTimeProvidersNTPServerEnabled
Changing the ‘Enabled’ flag to the value 1 enables the NTP Server.

HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesW32TimeParametersNtpServer
The ‘NTP Server’ parameter is used to provide a list of IP addresses or DNS names, separated by a space, of NTP servers that the Windows 2003 machine can synchronise to.

NTP Troubleshooting

A number of problems can be encountered when configuring the Windows Time Service. NTP operates using the UDP protocol over TCP/IP. Therefore the TCP/IP network infrastructure must be operational for NTP to be effective. Synchronization issues may arise when NTP attempts to synchronize to an inaccurate time reference or if network delays are excessive.

Synchronizing Network Infrastructures

As well as synchronizing Windows servers and workstations, NTP can also be used to synchronize network hardware, such as routers, switches and hubs. Any network hardware that can synchronize to a NTP server can be pointed to the Windows server to achieve time synchronization. In this way the whole network and accompanying infrastructure can be synchronized.

, , , ,

Leave a Reply

You must be logged in to post a comment.

PHVsPjxsaT48c3Ryb25nPndvb19hZHNfcm90YXRlPC9zdHJvbmc+IC0gdHJ1ZTwvbGk+PGxpPjxzdHJvbmc+d29vX2FkXzMwMF9hZHNlbnNlPC9zdHJvbmc+IC0gPC9saT48bGk+PHN0cm9uZz53b29fYWRfMzAwX2ltYWdlPC9zdHJvbmc+IC0gaHR0cDovL3d3dy53b290aGVtZXMuY29tL2Fkcy93b290aGVtZXMtMzAweDI1MC0yLmdpZjwvbGk+PGxpPjxzdHJvbmc+d29vX2FkXzMwMF91cmw8L3N0cm9uZz4gLSBodHRwOi8vd3d3Lndvb3RoZW1lc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