- NTP Windows клиент ( Настройка Windows клиента NTP. )
- Настройка синхронизации времени в домене Active Directory (через групповые политики)
- Поставшики времени
- Настроить NTP клиент Windows (сервер времени)
- Настроить NTP клиент Windows (все остальные)
- w32tm
- Заказать создание и поддержку безопасной IT-инфраструктуры любой сложности
- Bat скрипт для быстрой настройки NTP клиента
- NTP Software Downloads
- Current versions of NTP
- Source releases
- Release Notes and Version Numbering
- Third-party Implementations and ports
- Ntp клиенты для windows
- Download:
- Frequently Asked Questions (FAQs)
- Configuration Notes:
- Notes for Administrators:
- Update History:
- Source Notes:
- Contact me:
- Accuracy Notes:
- History & Other Notes:
NTP Windows клиент ( Настройка Windows клиента NTP. )
23 марта 2010 (обновлено 2 ноября 2014)
OS: Windows 2000/XP/2003/Vista/2008/7.
Задача: настроить Windows системы для получения показателей точного времени с определённых NTP серверов.
Пользователям операционных систем Windows XP/2003/2008 придётся проделать ряд манипуляций.
Указать на применяемые NTP серверы (где ntp.local, ntp1.local и так далее — наши NTP серверы):
Далее, отдать в командной строке указания о выборе приоритетного NTP сервера, перезапуске службы точного времени и принудительной синхронизации времени в NTP сервером:
В результате должны получить нечто вроде этого:
Через некоторое время можно проверить журнал событий системы. Если все настроено и отработало верно, то в журнале будет информационное сообщение от источника W32Time с кодом (ID) 35 и текстом «Служба времени выполняет синхронизацию системного времени с источником времени». Если возникли какие-то проблемы, то в журнал будут записаны ошибки с кодами. Поисковая система поможет и в этом.
Для локализации проблемы в командной строке можно выполнить запрос информации о используемом NTP сервере:
Для определения величины расхождения локального времени и времени любого компьютера в сети, можно использовать следующую команду:
Иногда помогает вульгарная перерегистрация службы времени Windows:
Как вариант, можно настроить синхронизацию времени с помощью графического интерфейса.
Можно указать на применяемые NTP серверы с помощью утилиты regedit.exe:
Необходимо пройти в ветку (если её нет — создать) «HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\DateTime\Servers»:
Создать или изменить строковые параметры с именами «0» и «1» указав в них доменные имена или IP адреса наших NTP серверов:
В диалоговом окне настроки параметров даты и времени снять «галочку» инициирования сервиса синхронизации времени, тем самым останавливая соответствующую системную службу:
Заново активировать систему синхронизации времени и попытаться его синхронизировать с указанными серверами:
[ уже посетило: 358682 / +3 ] [ интересно! / нет ]
Поблагодарить автора ( сделайте свой денежный вклад в хорошее настроение )
Настройка синхронизации времени в домене Active Directory (через групповые политики)
Очень удобно, когда все сервера и рабочие станции в AD имеют одинаковое время. Это избавляет от кучи проблем в структуре Active Directory.
Требования для статьи:
Будем считать, что у нас есть отдельные груповые политики для контроллера домена (или другого сервера, который будет выполнять эту роль) и для все остальных серверов и рабочих станций.
Синхронизацию сервера времени настраиваем с внешним сервером. Поэтому для сервера, который является центральным сервером времени, нужно открыть вовне порт 123, а так же для все остальных серверов и ПК должен быть открыт порт 123 во внутренней сети (NTP работает по этому порту).
Для того, чтобы это сделать открываем групповые политики
Поставшики времени
И переходим Конфигурация компьютера->Административные шаблоны->Система->Службы времени Windows->Поставшики времени
Теперь нам нужно настроить 3 параметра.
Включить NTP клиент Windows — включено (для всех политик).
Включить NTP сервер Windows — включено (только в политике для локального сервера времени).
Настроить NTP клиент Windows (сервер времени)
Настроить NTP клиент Windows (все остальные)
Настроить NTP клиент Windows — Включаем и настраиваем параметры:
NtpServer: для локального сервера времени — time.windows.com,0x9 для всех остальных — имя сервера времени в нашей сети.
Type: для локального сервера времени — NTP для всех остальных — NT5DS.
Теперь дожидаемся применения политики, или применяем ее принудительно, командой:
w32tm
w32tm /query /status
проверяем какие сервера используются (параметр Источник)
Для сервера он будет — time.windows.com,0x9
Для всех остальных — имя локального сервера времени.
На этом настройка синхронизации часов в домене завершена.
Заказать создание и поддержку безопасной IT-инфраструктуры любой сложности
Быть уверенным в своей IT-инфраструктуре — это быть уверенным в завтрашнем дне.
Bat скрипт для быстрой настройки NTP клиента
Выкладываю bat-скрипт для быстрой настройки ntp-клиента Windows. Написал его для себя и решил поделиться.
- запускаем скрипт от имени администратора (актуально для семейства Windows старше XP).
- вводим адрес ntp сервера который хотим задать.
- вводим время периода обновлений времени в минутах.
- ждем выполнения, и наблюдаем результат выполнения в консоли.
Данная статья не подлежит комментированию, поскольку её автор ещё не является полноправным участником сообщества. Вы сможете связаться с автором только после того, как он получит приглашение от кого-либо из участников сообщества. До этого момента его username будет скрыт псевдонимом.
- 16 ноября 2020 в 11:34 Автоматизация установки софта на чистую Windows
- 24 ноября 2020 в 14:25 Как за долгое время я вернулся на Windows (WSL)
- 15 февраля 2021 в 00:57 Android-клиент банка ВТБ показывает уведомления о всех операциях другого пользователя
- 24 марта 2021 в 18:30 Апгрейд старых ноутбуков как дополнительный зароботок
- 30 марта 2021 в 23:07 Отключается внешний жесткий диск. Что делать? [Человеческим языком]
Это «Песочница» — раздел, в который попадают дебютные посты пользователей, желающих стать полноправными участниками сообщества.
Если у вас есть приглашение, отправьте его автору понравившейся публикации — тогда её смогут прочитать и обсудить все остальные пользователи Хабра.
Чтобы исключить предвзятость при оценке, все публикации анонимны, псевдонимы показываются случайным образом.
Не надо пропускать:
- рекламные и PR-публикации
- вопросы и просьбы (для них есть Хабр Q&A);
- вакансии (используйте Хабр Карьеру)
- статьи, ранее опубликованные на других сайтах;
- статьи без правильно расставленных знаков препинания, со смайликами, с обилием восклицательных знаков, неоправданным выделением слов и предложений и другим неуместным форматированием текста;
- жалобы на компании и предоставляемые услуги;
- низкокачественные переводы;
- куски программного кода без пояснений;
- односложные статьи;
- статьи, слабо относящиеся к или не относящиеся к ней вовсе.
NTP Software Downloads
New users should consult the documentation page before contacting the NTP development team with questions.
Current versions of NTP
Release | Version | Date | Download | ||
---|---|---|---|---|---|
Production | 4.2.8p15 | 2020/06/23 | http / md5 | ||
http proxy / md5 | |||||
Development | 4.3.99 | 2019/06/07 | http / md5 | ||
http proxy / md5 |
RSS Feed for: Current Versions of NTP
Please use the NTP Public Services Project download page if the download links on this page don’t work.
Source code for previous releases of NTP is avilable in the HTTP archive (IPv4 only) and through the NTP Public Services Project HTTP archive proxy (IPv4/IPv6).
Source releases
The NTP project only produces source code releases of NTP. These releases may be installed using the standard Unix » make » command. Please contact your operating system vendor for binary packages or assistance with your package-management system. NTP users who wish to track the development version of NTP should see the development page.
Release Notes and Version Numbering
The NTP release notes are avilable linked from the NTP information page. Scroll to find a link.
The Release Numbering Scheme page, at the NTP Public Services Project, explains the current NTP version numbering scheme.
Third-party Implementations and ports
Third-party implementations and some ports of the NTP package are linked from the NTP Public Services Project links page.
Ntp клиенты для windows
NetTime is a Simple Network Time Protocol (SNTP) client for Windows 95/98/Me/NT/2000/XP/Vista/7/8/10 and Server 2003/2008/2012/2016. (32 bit and 64 bit operating systems are both supported)
If you’re looking for a program to keep your system time accurate, you’ve just found it!
Its main attributes are:
- Free
- Open Source
- Small
- Easy to Install and Use
- And most importantly: Reliable
NetTime was originally written by Graham Mainwaring in 1997 with an open source release made in 1998. Graham made a number of updates to the program until he lost interest and finally abandoned the project officially on the 1st of July 2004.
The NetTime project has been resurrected by myself, Mark Griffiths, and I’m now making an updated version available here:
If you find NetTime useful, please consider making a donation to show your appreciation and to encourage further development of NetTime!
Download:
Version 3.20 Alpha 1 — Previous Test Version:
- Installer: NetTimeSetup-320a1.exe
Version 3.20 Alpha 3 — Latest Test Version:
- Installer: NetTimeSetup-320a3.exe
Previous versions as well as the source code can be downloaded from the SourceForge project page
Note: When upgrading from a previous version, you will need to shut down both the NetTime Service as well as the Tray Icon before running the installer. If you uninstall the old version first, you will need to restart your computer before starting the new installer.
Frequently Asked Questions (FAQs)
NetTime is failing to sync — it reports that all servers failed: The most common cause of this error is that a firewall is blocking the Network Time Protocol (UDP Port 123) between your system and the servers that NetTime is attempting to use. It’s not always obvious that a firewall even exists as they generally allow regular web traffic to pass normally. If you have temporarily disabled all firewalls that you know of and continue to have this problem, then it’s almost certainly a firewall that you aren’t aware of. If you can run a UDP traceroute to port 123 on one of the time servers that you’re using, that should give you an indication of where the firewall is located.
NetTime is failing to sync — it reports that it had «Inconsistent responses» If there is a large time difference between the local system and the time returned by the time server, NetTime will automatically check with a secondary server to ensure that the time that it has received is actually valid. If it can’t find a unique secondary server that provides a time which is a close fit to the time returned by the primary server, it will fail with «Inconsistent Responses» The most common causes for this is if multiple servers are configured but point to the same IP address, or you’re using the default servers and you are in a region with only 1 actual server in the NTP Pool. Possible solutions are to either remove all but one server address — in which case, the time returned by it will always be used — even if it’s invalid, or change your servers — if you’re using the NTP Pool servers, then you should point to the servers for a larger geographic area.
NetTime is syncing, but the time is out by an hour — e.g. Daylight savings time isn’t be honoured correctly: NetTime works internally with UTC (Universal Time) and doesn’t have any code for handling daylight savings or time zones. As long as Windows is configured correctly, it should automatically handle daylight savings changes for you. If Windows isn’t handling it correctly, it most likely needs to be updated. You can also manually your time zone information using the free Microsoft tool: Windows Time Zone Editor tzedit.exe Alternatively, the Windows Server 2003 Resource Kit Tools reportedly includes a command line timezone.exe tool for advanced users.
I have configured NetTime to provide time to other systems, but it’s not working: Ensure that the Windows Time Service is disabled along with any other NTP servers that may be running. Also, make sure that the Windows Firewall, and other firewalls, aren’t bloicking the incoming connections to NetTime.
What does Offset mean? Offset is the time difference between the local system time and the time returned by the time server.
What does Lag mean? Lag is the amount of time that it took for the request from NetTime to go out to the server and for the response to come back. NetTime has code to try to compensate for high latency connections, but it won’t work well on connections with asymmetric network delays — i.e. when the time that it takes for the request to go out is significantly different to the time for the response to come back.
Can I configure NetTime to use a proxy server? Unfortunately, the Network Time Protocol doesn’t support the use of proxies, so that isn’t an option and there isn’t anything that I can do about this — sorry!
I have a problem not listed above: If NetTime isn’t working correctly for you, please enable Debug level logging, attempt to do another time sync and then send an email to me with your log file attached along with a detailed description of the problem that you’re having.
Configuration Notes:
Most settings should be fairly self explanatory, however some people have asked for clarification on certain settings:
Max Free Run: Indicates how long the program will run for without getting a valid sync before it considers the local time to no longer be accurate. Once this time period expires, the tray icon will change to a cross and if it’s configured to act as a time server, it will stop responding to requests for the time.
If Time adjustment greater than: The default setting for this means that the local time will be updated regardless of how much difference there is between the current local time and the time reported by the remote server. There shouldn’t normally be a reason to change this as the current version of NetTime will check with multiple servers to ensure that it isn’t using an invalid time.
Always provide time: Enabling this option isn’t recommended. Normally, NetTime will only provide time to other systems if it is configured to do so and it has successfully synced to an upstream server. If you enable the option to always provide time, you may find that it will give out invalid time to any systems that connect to it!
If you are using NetTime to act as a time server, you will need to disable the built in Time Service in Windows first. Although the description for the Windows Time Service indicates that disabling it may prevent other services from loading, I’m not currently aware of any such services that do actually require it. If you’re not using NetTime as a time server, disabling the Windows Time Service is optional, but there shouldn’t be any harm in disabling it to save a bit of RAM.
Notes for Administrators:
If you want to preconfigure settings that are different to the defaults, they are stored in the registry under:
HKLM\Software\Subjective Software\NetTime
On 64 bit systems, the above location is remapped to:
HKLM\Software\Wow6432Node\Subjective Software\NetTime
Update History:
Version 3.20 Alpha 3:
- Fixed an initialization failure error
Version 3.20 Alpha 2:
- Improved Handling of Kiss of Death Packets
- Fixed handling of «unsynchronized» replies
- Improved reporting of errors when configured to act as a time server — e.g. if Windows Time Service is still running
- Reduced minimum retry period when not using NTP Pool Servers.
- Improved display of forms on systems with large fonts.
- If NetTime is running as a tray icon, starting the program again will show a message instructing the user to click on the tray icon.
- Fixed loading of log files containing null characters or with one or more lines without the normal crlf pair.
- Several improvements to handling of system suspend and resume.
- Fixed handling of «Max Free Run Time»
- If time sync fails, the program won’t go straight to «Time Sync Lost» status until «Max Free Run Time» has elapsed — will now indicate «Time sync due» with an orange tray icon.
- Added description shown when viewing list of system services.
- Reworked IPC (Inter Process Communication) code to prevent crashes from occurring under certain circumstances.
- Log Viewer will now automatically update in real time when running as a service (would previously only update if not running as a service).
- Other minor changes and fixes
Version 3.20 Alpha 1:
- Added option to gradually correct small time errors instead of adjusting the time in one hit — thanks to code provided by Julien Blitte
- Added log file rotation — also thanks to Julien Blitte.
- Fixed a problem with high CPU usage when a lot of logging activity taking place.
- A few other minor improvements.
Version 3.14:
- Improved compatibility with other NTP/SNTP clients when NetTime is acting as a server — e.g. Windows built in time client.
- Added extra logging information.
- Fixed an error which could sometimes occur when installing over the top of a previous version.
- Fixed a problem preventing full uninstallation under certain circumstances.
- Removed requirement to manually shut down NetTime before installing a new version. (Windows restart may be required sometimes due to above bug)
- Improved handling when service is disabled & UAC disabled.
- Added code to re-show tray icon after Windows Explorer crashes.
- A few other minor improvements.
Version 3.13:
- Fixed an error that caused the program to always check for updates when run as a limited user.
Version 3.12:
- Fixed an Access Violation error.
Version 3.11:
- Added a workaround for a VCL bug which could prevent the NetTime service from being installed properly in very rare circumstances.
Version 3.1:
- Fixed a problem with running on Windows NT4.
- Added a balloon tip to the tray icon when run after installation to indicate that NetTime is running.
- When set to not change time on large adjustment, will now ask user when doing a manual check.
- Some changes to improve compatibility with newer versions of Delphi — notes added about upgrading to newer version of the Internet Component Suite.
- Added option to always provide time when acting as a server.
Version 3.0:
- Version Number Change only
Version 3.0 Release Candidate 1:
- No significant changes since Beta 4
Version 3.0 Beta 4:
- Fixed a few more bugs introduced with Beta 2
Version 3.0 Beta 3:
- Fixed a few bugs introduced with Beta 2
Version 3.0 Beta 2:
- Added capability to automatically check for new versions
- Added button to view log within NetTime
- Intervals can now be entered with units instead of only as a number of seconds
- Added support for Windows Themes
- Added option to quit if time adjustment is larger than a set value
- Added command line option to sync only once and then exit (/updateonce)
- Added command line option to only attempt syncing once and exit regardless of success (/tryonce)
Version 3.0 Beta 1:
- Various UI fixes and improvements
- Added default servers — thanks to the NTP Pool Project
- Added support for the Network Time Protocol «Kiss of Death» packet
- Added automatic syncing on additional triggers — e.g. resuming from suspend, time jumping forward or backwards
- Added logging capability
- Added extra information to the UI to show more details such as the time to the next sync, adjustment for the last sync and offsets and lag for each server queried
- Changed server query method to minimize server loads — it now queries only a single server, unless it finds a time difference of greater than 10 seconds, in which case it will check with an alternate server to ensure that an invalid time isn’t used
- Improved handling of UAC — User Account Control — under Windows Vista & 7
- Dropped Windows 95 pseudo service — Can still be used under Windows 98/98/Me as a regular application however
- Removed automatic configuration screens for searching for available servers — not needed with the NTP Pool default servers
- Fixed several UI problems
- Fixed problems with running the client under limited user accounts in conjunction with the NetTime Windows Service
- Various other minor fixes and improvements
Despite the amount of work that has gone into this updated version, most of the credit for it still lies with Graham Mainwaring.
Source Notes:
The latest version has been tested with Delphi XE2 Professional: The current version includes an older version of the Internet Component Suite which is not compatible with Unicode versions of Delphi (i.e. Delphi 2009 and newer) Upgrading to the latest version of the Internet Component Suite by Franзois Piette will resolve the Unicode issues. When upgrading to the new version of the Internet Component Suite, you will need to change the reference to HttpProt in the uses clause of UpdateCheck.pas to read OverbyteIcsHttpProt.
Contact me:
Of course, as this is free software, I can’t give any guarantees as to when (or even if) any feature requests will be incorporated into a future version — unless you’re wanting to pay for it of course! If you have a programming project that you would like me to work on for you, you’re certainly more than welcome to contact me!
Accuracy Notes:
SNTP clients resync the system time at regular intervals — between these time syncs, the system will be allowed to run at its normal speed which may mean that it runs either fast or slow — gradually putting the system time out until the next sync takes place. The speed at which the system time deviates from the correct time depends greatly on the system hardware and also to a certain extent what software is being run. Most PCs gain or lose a few seconds each day, however I’ve seen a system that loses 9 seconds per hour — more than 3.5 minutes per day!
The vast majority of users should find that NetTime more than meets their needs, however if you have specific requirements for very accurate time, I recommend that you investigate installing a full NTP client. Although you can set NetTime to sync more frequently to compensate for an inaccurate system clock, this isn’t really recommended because of the greater strain that it puts onto the public NTP servers. A full NTP client has extra features to ensure better time accuracy (normally well below 10 milliseconds even between time syncs) by adjusting the rate that the system clock runs at. If you are administering a large number of PCs for an organization, it’s also recommended that you configure a full NTP client on your network and have the rest of your systems sync to it with an SNTP client — this reduces the load on the public time servers even further as well as ensuring that all systems are in sync with a single time source.
History & Other Notes:
Part of the apparent reason why Graham abandoned the NetTime project was because Windows 2000 and XP already include an SNTP Client and a free download was available from Microsoft for Windows NT. Graham characterized the Microsoft NTP client as being full featured, however, I strongly disagree with this — I would call the Windows SNTP client very basic — the user interface has only 2 features — allowing the SNTP server to be changed and a button to attempt an immediate sync. The Microsoft SNTP client does have more features available, but they require manual editing of the system registry — something which most users are understandably reluctant to do. In the end, even with editing the registry settings, the Microsoft client is still just an SNTP client with the limitation of being able to sync with only a single remote server.
Like the vast majority of SNTP clients that can only sync with one server, (and also most of the remainder that only have backups for if the primary server fails completely) the Microsoft SNTP client has a major problem when it receives a reply with a vastly different time to what is currently set on the system — the software simply has no way to know which is closer to being correct — either the system time could be wildly inaccurate (e.g. because the CMOS battery has failed) or the answer from the server could be wrong (either accidentally or maliciously.)
For Windows XP, in order to prevent the Microsoft SNTP client from setting the system time to a wildly incorrect value, Microsoft made the design decision that their client would only update the system time if the server response was within 15 hours of the current system time. This reduced the risk of an invalid time being set on the system (but not completely) but also has the effect that if the system time isn’t at least reasonably accurate it never would be until manually fixed! For a system with a failed CMOS battery, the Microsoft SNTP client is pretty much useless.
For Windows Vista (and 7) Microsoft relaxed the rules so that (at least when manually triggering an update) the current system time being wrong doesn’t prevent the SNTP client from updating the system time. This of course does mean that an incorrect response from the time server can put the system time way out. The Windows Time Service in Windows 7 is also configured by default to not start automatically each time the system is started — the user interface reports that Windows is configured to automatically update the system time, but it doesn’t unless the user manually starts the Windows Time Service either through the Services Control Panel applet, or by requesting a manual sync. Unless the user reconfigures the Windows Time Service to start automatically, it will be effectively disabled every time the system is restarted!
NetTime ensures that it is not setting the system time to an incorrect value by always checking with a second server (when configured) if the time adjustment is more than 10 seconds. Short of a major bug in the program design or a very sustained attempt to maliciously skew the system time by a rogue time server, NetTime simply won’t set an invalid system time!