First, the preparatory work
1. Determine the two hosts are in the same network segment, can ping each other.
Two, Windows NTP Server Configuration
1. Click "Start" - "click" Run ", type regedit, and click" OK. "
2. Modify the registry
a) HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Parameters\Type
Right "Type", click "Edit" in the "Edit value" in the "Value data" box, type NTP, and then click "OK" (some machines do not do this step).
b) HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpServer\Enabled
Is set to 1, open the NTP server function. (Default is not open NTP Server service)
c) HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\Config\AnnounceFlags
Is set to 5, the setting force to declare itself as a master of a reliable time source, thereby using the built-in complementary metal oxide semiconductor (CMOS) clock.
If the time to be used outside of a server with the default value.
d) If the server and the internet connection, then in order to avoid the ntp synchronization server and the internet, is preferably added as follows:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient\enable
Set to 0 to prevent the outside world as a client automatically synchronize time service
3. In the DOS command line command to restart Win32Time services to ensure that the above changes to take effect
a) Start command-line tool as an administrator
i) the right "administrator" to run cmd
ii) win8, win + X ---> Command Prompt (Administrator)
b) net stop w32time
c) net start w32time
4. NTP port 123 open.
5. NTP server configuration starts this success.
Three, Window Client Configuration
1. Modify the registry
a) HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient\SpecialPollInterval
3600 modified into decimal values (seconds, 3600 1 hour, the value update interval)
b) HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W32Time\TimeProviders\NtpClient\SpecialPollTimeRemaining
Modified value [Time Synchronization Server], such as 0: 192.168.1.1,0 as a server address ntp
c) HKEY_LoCAL_MACHINE\SOFTWARE\MICROSOFT\WINDOWS\CURRENTVERSION\DATETIME\SERVERS\default
Modify the default update server
2. Restart Win32Time Service
a) net stop w32time
b) net start w32time
Reproduced in: https: //www.cnblogs.com/liuming8080/p/3807003.html