Synchronize Microsoft Windows to a NTP Server / Sync Windows 10 internet time

http://www.timetoolsglobal.com/2013/06/21/how-to-synchronize-microsoft-windows-to-a-ntp-server-1/

How To Synchronize Microsoft Windows to a NTP Server

Most modern operating systems, including Windows, can synchronize their system time to a NTP server. Windows utilizes a time service called ‘Windows Time’, which is automatically installed in the service list. The program executable is ‘w32time.exe’. The service is installed and enabled by default during installation.

Windows synchronizes time in different ways, depending on the network implementation utilized. When peer-to-peer networking is employed, each individual workstation sync to a time reference independently.

However, when Windows Domain Networking is deployed, only the Primary Domain Controller (PDC) synchronizes with a time reference. All other servers and workstations in the domain sync to the PDC using Windows proprietary protocol. The default installation procedure automatically configures workstations and servers to sync to the controlling PDC. Only the PDC needs to be configured to synchronize to an external time reference.
Configuring a Windows Server to Sync to an External Time Reference.

Applies to:
Microsoft Windows Server 2008
Microsoft Windows Server 2003

To configure a Windows PDC to synchronise with an external NTP server requires registry entry changes.

1. Change the server type to NTP.
Registry Key: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Parameters\Type
Change value data to: NTP

2. Set announce flags.
Registry Key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config\AnnounceFlags
Change value data to: 5

3. Enable NTP server
Registry Key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpServer
Change value data to: 1.

4. Specify the time sources.
Registry Key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Parameters
Change value data to: <peerlist>
< peerlist> is a list of space-delimited NTP peers from which time can be received. If DNS names are used, you must append ‘,0x1’ to each DNS name. Alternatively, a list of IP addresses can be specified.

5. Select poll interval.
Registry Key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient\SpecialPollInterval
Change value data to: <period>
< period> is the time in seconds between each poll. Microsoft recommends a value of 900, which equates to a polling frequency of once every 15 minutes.

6. Set the time correction settings.
These settings specify a time frame to validate time stamps received from an external reference. Only if the received timestamp falls between these registry settings will they be accepted. It provides a facility to reject timestamps that are too far away from the hosts system time. Microsoft recommends a setting of 1 hour (3600) or 30 minutes (1800).
Registry Key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config\MaxPosPhaseCorrection
Change value data to: <seconds>
Where <seconds> is the maximum positive offset of the received time stamp from the system time.

Registry Key:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config\MaxNegPhaseCorrection
Change value data to: <seconds>
Where <seconds> is the maximum negative offset of the received time stamp from the system time.

7. Restart the windows time service.
Stop and restart the Windows Time Service using the ‘net stop’ and ‘net start’ commands:
net stop w32time && net start w32time
Synchronizing a Windows Workgroup


Applies to:
Microsoft Windows XP.
Microsoft Windows Vista.
Microsoft Windows 7.

When Windows for Workgroups is deployed, you have to manually configure time synchronization settings. You need to specify the time server that the Windows Time Service is to use as a reference clock. This is a very straightforward process; simply specify the time reference that the host is to synchronise with using the ‘net time’ command:

Net time \\<ntpserver> /set /yes

Where <ntpserver> is the DNS name or IP address of the time reference.

Alternatively, you can utilize the date and time properties applet from the control panel. Select the ‘Internet Time’ tab from the applet, check ‘Automatically Synchronize with an Internet Time Server’ and enter the DNS name or IP address of the server. If you select ‘Update Now’ the time service will attempt to contact and synchronise with the time reference immediately.


Where do I find the “Internet Time” (NTP) settings in Windows 10?

"Internet Time Settings" dialog box

1.    Go to Control Panel.
2.    Search for "Date and Time".
3.    Click on "Set the time and date".
4.    Click on the "Internet Time" tab.
5.    Click on "Change settings…".

Registry key

You can still modify the default server registry key at
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\DateTime\Servers to set a custom NTP server.


For domain users, the domain controller will also be missing the Internet Time, as well as all domain workstations. Once the Domain Controller is set to a manual peer, the workstations can run, from a comment prompt, which may have to be elevated:
net time \\domaincontroller.domain.tld /set /y
to sync with the DC. Ex: net time \\dc.domain.local /set /y

For virtual servers, the DC/member servers, clients will have issues even with these settings set on the DC. The core server controls it and it does have the Internet Time tab, so you can set the manual peer there and then everything will work as it should because virtual servers utilize the physical resources from the core server.

REGISTRY SETTINGS:

SpecialPollInterval :
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient

Explanation :

Version : Windows XP, Windows Vista, Windows Server 2003, and Windows Server 2008
This entry specifies the special poll interval in seconds for manual peers. When the SpecialInterval 0x1 flag is enabled (see next key : NtpServer) , W32Time uses this poll interval instead of a poll interval determine by the operating system. The default value on domain members is 3,600 (1 hour). The default value on stand-alone clients and servers is 604,800 (7 days).

NtpServer
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Parameters

Explanation :

Version : Windows Server 2003 and Windows Server 2008
This entry specifies a space-delimited list of peers from which a computer obtains time stamps, consisting of one or more DNS names or IP addresses per line. Each DNS name or IP address listed must be unique. Computers connected to a domain must synchronize with a more reliable time source, such as the official U.S. time clock.
0x01 SpecialInterval
There is no default value for this registry entry on domain members. The default value on stand-alone clients and servers is time.windows.com,0x1.

UpdateInterval :
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config

Explanation :

Version : Windows XP, Windows Vista, Windows Server 2003, and Windows Server 2008
This entry specifies the number of clock ticks between phase correction adjustments. The default value for domain controllers is 100. The default value for domain members is 30,000. The default value for stand-alone clients and servers is 360,000.

MinPollInterval :
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config

Explanation :

Version : Windows XP, Windows Vista, Windows Server 2003, and Windows Server 2008
This entry specifies the smallest interval, in log2 seconds, allowed for the system polling interval. Note that while a system does not request samples more frequently than this, a provider can produce samples at times other than the scheduled interval. The default value for domain controllers is 6. The default value for domain members is 10. The default value for stand-alone clients and servers is 10.

TASKSCHEDULER

 

No Comments

Geef een reactie

Het e-mailadres wordt niet gepubliceerd. Vereiste velden zijn gemarkeerd met *