I noticed the time on a Microsoft Windows 7 Professional system was ahead of the actual time by 22 minutes. The system was part of a Windows domain, but the domain controller (DC) was decommissioned. I checked the Network Time Protocol (NTP) settings from a command-line interface (CLI) by opening a command prompt window with administrator level access and using the Microsoft Windows w32tm command. to check the current configuration for querying time servers.
C:\>w32tm /query /peers #Peers: 1 Peer: State: Pending Time Remaining: 1441.6885058s Mode: 0 (reserved) Stratum: 0 (unspecified) PeerPoll Interval: 0 (unspecified) HostPoll Interval: 0 (unspecified) C:\>w32tm /query /status Leap Indicator: 3(last minute has 61 seconds) Stratum: 0 (unspecified) Precision: -6 (15.625ms per tick) Root Delay: 0.0000000s Root Dispersion: 0.0000000s ReferenceId: 0x00000000 (unspecified) Last Successful Sync Time: unspecified Source: Free-running System Clock Poll Interval: 10 (1024s) C:>
I noticed that the time source was listed as "Free-running System Clock"
indicating that the time value was being obtained from the system clock in
the laptop. A PC's clock will tend to drift from the actual value over time
and, in this case, was now 22 minutes fast. I first tried setting time servers
from the command line with a
w32tm /config /update /manualpeerlist
command - you can specify time servers to be queried by using
manualpeerlist: followed by a list of time servers enclosed within
double quotes and separated by a space character. But that didn't seem to
have an effect, at least not any immediate effect, and the time source
remained listed as "Free-running System Clock" when I checked the time server
C:\>w32tm /config /update /manualpeerlist:"time.windows.com time.nist.gov" The command completed successfully. C:\>w32tm /query /peers #Peers: 1 Peer: State: Pending Time Remaining: 1044.0837641s Mode: 0 (reserved) Stratum: 0 (unspecified) PeerPoll Interval: 0 (unspecified) HostPoll Interval: 0 (unspecified) C:\>
I then clicked on the time displayed at the lower, right-hand corner of the screen and clicked on "Change date and time settings".
I then clicked on the Internet Time tab on the next window.
I then clicked on the Change settings button on the next window where with the checkbox next to "Synchronize with an Internet time server" checked and time.windows.com in the "Server" field, I could click on an Update now button, which immediately updated the time to the correct time.
Then when I issued the
w32tm /query /peers command from the
command line, I saw time.windows.com listed as a peer and the
/query /status command showed
C:\>w32tm /query /peers #Peers: 1 Peer: time.windows.com,0x9 State: Active Time Remaining: 1973.4149994s Mode: 3 (Client) Stratum: 4 (secondary reference - syncd by (S)NTP) PeerPoll Interval: 10 (1024s) HostPoll Interval: 10 (1024s) C:\>w32tm /query /status Leap Indicator: 0(no warning) Stratum: 5 (secondary reference - syncd by (S)NTP) Precision: -6 (15.625ms per tick) Root Delay: 0.1957988s Root Dispersion: 7.9521302s ReferenceId: 0x34A88A91 (source IP: 188.8.131.52) Last Successful Sync Time: 11/12/2017 4:09:01 PM Source: time.windows.com,0x9 Poll Interval: 10 (1024s) C:\>