Windows Time Troubleshooting

Windows time has two components. First is the Domain Controller. The Domain Controller should be sync’ed to the master NTP server in the environment. Microsoft’s excellent document on the steps necessary can be found HERE.

The Windows clients will need to be configured to point to the Domain Controllers (DC’s.) If you’ve never installed any non-Microsoft utilities, you should be OK by just making sure Windows Time is running. However, if it is not running, or something has broken time, these are steps that will help you fix your problems.

Let’s check to see if Windows Time is running

sc query w32time

You should get a result such as

SERVICE_NAME: w32time
TYPE               : 20  WIN32_SHARE_PROCESS
STATE              : 4  RUNNING (STOPPABLE, NOT_PAUSABLE, ACCEPTS_SHUTDOWN)
WIN32_EXIT_CODE    : 0  (0x0)
SERVICE_EXIT_CODE  : 0  (0x0)
CHECKPOINT         : 0x0
WAIT_HINT          : 0x0

If you don’t, start services.msc and start the service and set it to Automatic

Now let’s make sure that the server is setup correctly. Check to see if the domain server is our time server. Note the “:” is part of the command.

C:\WINDOWS>nltest /dsgetdc:

Look for the flag “TIMESERV.” This indicates that the Domain Controller is our Time Server.

DC: \\myDomainController.domain.com
Address: \\10.1.99.19
Dom Guid: 9db0908b-8f45-499f-9c20-49905773f553
Dom Name: domain.com
Forest Name: domain.com
Dc Site Name: Default-First-Site-Name
Our Site Name: Default-First-Site-Name
Flags: PDC DS LDAP KDC TIMESERV GTIMESERV WRITABLE DNS_DC DNS_DOMAIN DNS_FOREST CLOSE_SITE
The command completed successfully

Check that the client has the correct information

w32tm /dumpreg /subkey:parameters

The only thing to look for is a Type of NT5DS. That’s the protocol we use to speak to the the Domain Controller. Any other setting is wrong.

Value Name      Value Type          Value Data
-------------------------------------------------
 
ServiceMain     REG_SZ              SvchostEntry_W32Time
ServiceDll      REG_EXPAND_SZ       C:\WINDOWS\system32\w32time.dll
NtpServer       REG_SZ              time.windows.com,0x1
Type            REG_SZ              NT5DS

To sync the server with the domain controller.

w32tm /resync /rediscover

You should now be getting in sync. You can see your offset shrinking if you type

w32tm /stripchart /computer:myDomainController /samples:5 /dataonly