Linuxベースのオペレーティングシステムおよび多くのネットワークデバイスのほとんどのディストリビューションは、*。pool.ntp.orgサーバーを使用してクロックを設定します。
サーバーデータの出所、独自のサーバーを作成してこのクラスターに追加し、時間同期コミュニティを支援するために必要なものを詳しく見てみましょう。
ウェブサイトhttps://www.ntppool.org/ru/に記載されているように 、これはタイムサーバーの巨大なクラスターであり、信頼性が高く使いやすいNTPサービスを数百万のクライアントに提供し、世界中の数千万のシステムがそのサービスを使用しています。
サーバーのインストール方法、これには何が必要ですか?
Linux / BSD、またはインターネット上で動作するNTPプロトコルhttps://ru.wikipedia.org/wiki/NTPを使用してntpサーバーとして安定して動作できる同様のデバイスである、最新のオペレーティングシステムを備えた静的な実IPアドレスを持つ通常のサーバーが必要です。ポート123 / udpのネットワーク
リソースとチャネルの消費量が少ないため(最大10〜15キロビット/秒)、ほとんどすべての構成が適しています。たとえば、リソースが最小限のKVMベースのVPS / VDSです。
私はサイトhttps://www.ntppool.org/ru/join.htmlから引用します
「現在、ほとんどのサーバーは1秒あたり約5〜15のNTPパケットを受信します。1日に数回、1秒あたり60〜120パケットのピークが発生する可能性があります。キロビットに変換すると、平均で約10〜15Kbps、ピーク負荷で約50〜120Kbpsが得られます。ますます多くのサーバーが徐々にプールに参加しているため、将来的に負荷が急激に増加することはありません。したがって、(受信および送信用に)384〜512Kビットを超える帯域幅が必要になる可能性はほとんどありません。」
NTPサーバーのインストール
ほとんどのLinuxディストリビューションでは、オペレーティングシステムの標準リポジトリに含まれているため、インストールするだけで済みます。
aptのNTPのインストールのDebian / Ubuntuのためか、yumをNTPのインストールCentOSのために
/etc/ntp.conf 99% :
pool 0.debian.pool.ntp.org iburst
pool 1.debian.pool.ntp.org iburst
pool 2.debian.pool.ntp.org iburst
pool 3.debian.pool.ntp.org iburst
#,
http://support.ntp.org/bin/view/Servers/StratumTwoTimeServers http://support.ntp.org/bin/view/Servers/StratumOneTimeServers
google “ntp server _”
4 6
2+2+2 -
2 - StratumOne
2 - StratumTwo
2 -
, ( ) - time.apple.com / time.facebook.com / time.google.com. - , "-" , , google leap second.
ntpdate -q -
root@gw:~# ntpdate -q ntp4.vniiftri.ru
server 89.109.251.24, stratum 1, offset 0.001008, delay 0.08249
8 Jan 03:50:07 ntpdate[1414]: adjust time server 89.109.251.24 offset 0.001008 sec
, , “ ” (stratum 1).
(stratum) https://habr.com/ru/post/79461/
(, GPS-) (stratum 0).
(, GPS-) 1.
2 3 - .
( ntpdate -q) ntp- (service ntp restart) ntpq -pn
root@gw:~# ntpq -pn
remote refid st t when poll reach delay offset jitter
==============================================================================
-51.15.74.121 131.176.107.13 2 u 48 64 17 1.009 -0.030 0.246
*193.190.230.37 .EXT. 1 u 41 64 17 4.825 -0.263 0.853
+145.238.203.14 .MRS. 1 u 41 64 17 14.549 -0.857 0.127
-89.109.251.24 .MRS. 1 u 44 64 17 46.043 0.501 1.539
+62.231.6.98 .GPS. 1 u 43 64 17 41.770 -1.292 0.647
-80.60.208.118 193.67.79.202 2 u 43 64 17 8.324 -1.364 1.338
* - .
ntp . delay jitter, .
ntpdate -q ip- , udp/123
pool.ntp.org
https://www.ntppool.org/ru/join.html -
IP , .
( score) 10 - .
サーバー管理ページには、グラフとcsv形式の監視があり、時計の安定性とNTPサーバーの応答を追跡できます。使用できない場合は、問題に関する電子メールが送信されます。
tcpdump port 123コマンドを使用してパケットを監視できます。主にクライアントデバイス(インターネットルーター)からの、さまざまなプロバイダーのさまざまなネットワークからの要求が表示されます。
04:00:50.531801 IP gw.mytimeserver.net.ntp > 82-217-46-231.cable.dynamic.v4.ziggo.nl.59634: NTPv4, Server, length 48
04:00:50.888803 Imytimeserver.netP 51.144.84.29.ntp > gw.mytimeserver.net.ntp: NTPv4, Client, length 48
04:00:50.888998 IP gw.mytimeserver.net.ntp > 51.144.84.29.ntp: NTPv4, Server, length 48
04:00:51.621673 IP 46.11.105.3.54627 > gw.mytimeserver.net.ntp: NTPv4, Client, length 48
04:00:51.621916 IP gw.mytimeserver.net.ntp > 46.11.105.3.54627: NTPv4, Server, length 48
04:00:52.037807 IP 51.136.36.226.ntp > gw.mytimeserver.net.ntp: NTPv4, Client, length 48
04:00:52.052103 IP gw.mytimeserver.net.ntp > 40.68.72.138.ntp: NTPv4, Server, length 48
この点で、インターネットサービスプロバイダーがネットワークにntpサーバーをインストールし、それをntpプールに含めることを強くお勧めします。
便利なリンク
https://ru.wikipedia.org/wiki/NTP