How to change NTP time source for a server via command prompt
Posted on 6 April 2016 by Beaming SupportIf you are alerted to a server that is displaying the wrong time, the following may be of use.
When you need to change NTP time source for a server, use the specific commands in this article, which refer to the following operating systems; Windows Server 2008 R2 and SBS 2011.
If you have multiple servers on a domain, please ensure you know which server has the source NTP configured, as you will need to perform the commands on that server. If you are unsure, you can issue a command that will query the time service and display some information for you.
Firstly open a command prompt as an administrator and type the following:
w32tm /query /status
Within the displayed output, the second to last item should be source and could state the following:
- Local CMOS Clock
- windows.com (typically default)
- The hostname of the source server (if more than 1 server exists on the domain)
If you wish to test a different NTP server pool you can use the following website to identify one for your location:
http://support.ntp.org/bin/view/Servers/NTPPoolServers
Once you have identified the hostname, you can issue the command below to amend the source:
Please note this must also be from an elevated command prompt
w32tm /config /manualpeerlist:chosenhostname
Please see an example below that would change the source to a UK based pool:
w32tm /config /manualpeerlist:uk.pool.ntp.org
The time service will now need to be restarted, please see the commands below:
net stop w32time
net start w32time
Once this has been done, you can run the initial query command to confirm the amended source is now in place.
Avoid internet downtime
Download the report to understand the landscape of potential internet downtime, and find strategies to reduce the risk of failure and mitigate disruption and financial impact when it does occur.