How is Windows time synchronized?

It's time to talk about how Windows time synchronization works. The service called W32Time is responsible for this on Microsoft operating systems.

Windows time synchronization

In order to configure it, you must make the appropriate changes to the registry. The most commonly used parameters relate to the lists of sources for time, as well as the intervals of this synchronization, after which the source will be accessed.

Windows XP time synchronization occurs from only one source. Even if your list has a rich list, the system will use only one. Why indicate a large number of sources? Everything is very simple. This is done so that if the first is unavailable, the system will refer to the next in the list.

If there are problems with the next one, the call will occur to the third, fourth and so on until the procedure is completed successfully. Windows 7 time synchronization occurs on the same principle.

Windows 7 time synchronization

The specified list of sources for synchronization is set using a special registry key. It looks like this: HKEY_LOCAL_MACHINES \ SYSTEMS \ CurrentControlSets \ Servicing \ W32Times \ Parameter \ NtpServers. The last value is the key, which is separated by spaces and is a list of exact time servers. It can be set either by a domain name or by the IP address itself. Each of these servers can have specified hexadecimal values โ€‹โ€‹for flags, which must be specified with a comma. This is written after each server name.

There are a total of four possible flag values. The first is 0x01. Called a special interval. The second is 0x02. It is called "used only as a spare." The third is 0x4. It is called - symmetrically active. And finally, the fourth - 0x08. It is called a client. Windows time synchronization can occur only with these flags.

When you use the first, you must specify a value for the interval in the key that is responsible for this interval. By default, the system sets one week. Thus, Windows time synchronization occurs every 604800 seconds. If the accuracy of the system clock is low, this interval is too long.

windows xp synchronization

Some devices have an error of a few minutes from update to update. Therefore, it makes sense to reduce the interval so that Windows time synchronization takes place after a few hours. Such a change does not significantly increase your traffic or server load. However, such an adjustment will make it possible to maintain a rather high accuracy of your watch on a computer.

When you make the necessary changes to your registry, confirm them, after which you will need to reboot your system. After that, the update interval will be reduced by the indicator that you set for this purpose.

Now you can be one hundred percent sure that the clock on your computer or laptop will display the correct time. I just want to warn you that working with the registry must be very careful and attentive. No errors are allowed. Otherwise, you risk reinstalling your operating system.

Source: https://habr.com/ru/post/C32861/


All Articles