Tuesday 6 May 2014

NTP on Windows


A Windows Domain needs NTP set on it's PDC Emulator to ensure the domain has correct time sync. These commands set this for Windows systems, with an emphasis on Australian settings.


This can be set simply by pasting the commands into a cmd window (I recommend setting NTP1 to your actual local NTP server/router if you have one). These commands are expected to work on Server 2008 onwards.

SET TARGET=localhost
SET NTP1=192.168.1.1
SET NTP2=2.pool.ntp.org
SET NTP3=3.pool.ntp.org
w32tm /config /computer:%TARGET% /update /manualpeerlist:"%NTP1% %NTP2% %NTP3%" /syncfromflags:MANUAL


Australian Settings

Same commands as above, just swap in these variables instead.

Internode version:

SET TARGET=localhost
SET NTP1=192.168.1.1
SET NTP2=ntp.on.net
SET NTP3=3.au.pool.ntp.org


Telstra version:

SET TARGET=localhost
SET NTP1=192.168.1.1
SET NTP2=toc.ntp.telstra.net
SET NTP3=tic.ntp.telstra.net

Confirm Settings

Validate this with the query command:
w32tm /query /configuration /computer:%TARGET%

2 comments:

  1. Generally I've found au.pool.ntp.org returns enough IP addresses to have some redundancy, otherwise use 0.au, 1.au etc, the returned addresses should be suitable for the ISP, and makes it portable for multi-homed systems or networks with backup routes.

    ReplyDelete
  2. I tend to use the ISP-specific ones first, as we are already paying for that service; even a dual-homed network/system generally has a primary link ,and that's what I would set as the primary server (often with a prefer keyword modifier), and theep the pool.ntp only as my final server - this should help to reduce the load on services that I don't directly pay for.

    I also use 3.au as my usual service, but specifically as a contrarian choice - given that most people use au.pool and/or {0,1,2}.au. and stop there, I figure that my choice of 3.au is spreading the load slightly.

    ReplyDelete