Installing NTP Server On Windows Server
Windows

Installing NTP Server On Windows Server

Installing NTP server on Windows Server Operating System step by step has been described in this article.

The Network Time Protocol (NTP) synchronizes time across all network devices. It listens on User Datagram Protocol (UDP) port 123 and ensures that time inconsistencies are mitigated and that client systems are always in sync with the server. It ensures that the server is always in synchronize with the client systems.

It involves exchanging time-stamp data between the server and the client, which allows the client’s system clock to be adjusted as accurately as possible to match the NTP server’s time.

A unique Windows time service specifically designed for Windows Server contexts manages time synchronization between the windows server and windows client systems. Windows Time service is used for this. From Windows XP and Windows Server 2008 up to the most recent versions of each operating system, PowerShell offers a command-line tool with the name of w32tm.exe.

Configure NTP on Windows Server

 

Step1: Open windows PowerShell run as Administrator and check time synchronization Source and Time Zone as well.

w32tm /query /source
Get-Date -Format "dd/MM/yyyy HH:mm K"

 

Below is the output from windows 2019 server operating system.

As per above screenshot NTP is not used if the output says Free-running System Clock or Local CMOS (Complementary Metal Oxide Semiconductor) Clock.

 

Step2: Installing NTP on Windows server check current status

Check the NTP time synchronization status since it is using CMOS as a source.

w32tm /query /status

Output

PS C:\Users\Administrator> w32tm /query /status
Leap Indicator: 3(not synchronized)
Stratum: 0 (unspecified)
Precision: -23 (119.209ns per tick)
Root Delay: 0.0000000s
Root Dispersion: 0.0000000s
ReferenceId: 0x00000000 (unspecified)
Last Successful Sync Time: unspecified
Source: Local CMOS Clock
Poll Interval: 6 (64s)

 

Step3: Now will configure NTP Pool server for Proper time zone synchronization. For millions of Internet users, pool.ntp.org provides a reliable, easy-to-use timeserver cluster.

In my scenario need Indian time zone so used in.pool.ntp.org

Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Services\w32time\Parameters" -Name "NtpServer" -Value in.pool.ntp.org

 

Step4: Enable NTP Server as per below command it make entry in Windows Registry.

Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\Services\w32time\TimeProviders\NtpServer" -Name "Enabled" -Value 1
w32tm /config /syncfromflags:manual /manualpeerlist:”0.in.pool.ntp.org 1.in.pool.ntp.org” /update
Set-ItemProperty -Path "HKLM:\SYSTEM\CurrentControlSet\services\W32Time\Config" -Name "AnnounceFlags" -Value 5

 

Step5: In Windows Server default firewall is enabled, you need to allow UDP 123 port at Inbound and Outbound rules on Firewall.

netsh advfirewall firewall add rule name="NTP Server" dir=out protocol=udp localport=123 profile=any enable=yes action=allow
netsh advfirewall firewall add rule name="NTP Server" dir=in protocol=udp localport=123 profile=any enable=yes action=allow

 

Step6: Restart Windows Time service by using the below command

Restart-Service w32Time

 

Step7: Now test the NTP synchronization status.

w32tm /query /source

 

conclusion:

Configure NTP Server on windows server operating system has been explained step by step. In my previous article discussed about delete recovery partition in windows operating system without any data loss for extended the local disk C.

Thanks for reading this article. I hope you find it useful. If you have a question about Installing NTP on Windows Server Operating System, please let me know.

 

Next PostHow to Disable HTTP TRACE/TRACK method for Apache Previous PostHow to Delete Recovery Partition in Windows

Leave a Reply

Your email address will not be published. Required fields are marked *