11 | | |
12 | | * /etc/ntp.conf |
13 | | |
14 | | == IPv6 == |
15 | | === fource IPv4 === |
| 10 | * http://wiki.nothing.sh/page/NTP |
| 11 | |
| 12 | == /etc/ntp.conf == |
| 13 | * SakuraのVPSで運用中 |
| 14 | {{{ |
| 15 | # /etc/ntp.conf, configuration for ntpd; see ntp.conf(5) for help |
| 16 | |
| 17 | driftfile /var/lib/ntp/ntp.drift |
| 18 | |
| 19 | |
| 20 | # Enable this if you want statistics to be logged. |
| 21 | #statsdir /var/log/ntpstats/ |
| 22 | |
| 23 | statistics loopstats peerstats clockstats |
| 24 | filegen loopstats file loopstats type day enable |
| 25 | filegen peerstats file peerstats type day enable |
| 26 | filegen clockstats file clockstats type day enable |
| 27 | |
| 28 | |
| 29 | # You do need to talk to an NTP server or two (or three). |
| 30 | #server ntp.ubuntu.com |
| 31 | server -4 ntp1.sakura.ad.jp # Sakura => 210.188.224.14 |
| 32 | server ntp1.sakura.ad.jp # Sakura => 2001:e40:100:208::123 |
| 33 | server -4 ntp.nict.jp # NICT => 133.243.238.163 |
| 34 | server -4 ntp.nict.jp # NICT => 133.243.238.164 |
| 35 | server -4 ntp.nict.jp # NICT => 133.243.238.243 |
| 36 | server -4 ntp.nict.jp # NICT => 133.243.238.244 |
| 37 | server ntp.nict.jp # NICT => 2001:2f8:29:100::fff3 |
| 38 | server ntp.nict.jp # NICT => 2001:2f8:29:100::fff4 |
| 39 | server ntp.jst.mfeed.ad.jp # MFEED => 210.173.160. |
| 40 | server ntp.netlab.is.tsukuba.ac.jp # => 130.158.83.97 |
| 41 | |
| 42 | server 127.127.1.0 # local system clock (not IP address) |
| 43 | |
| 44 | # Access control configuration; see /usr/share/doc/ntp-doc/html/accopt.html for |
| 45 | # details. The web page <http://support.ntp.org/bin/view/Support/AccessRestrictions> |
| 46 | # might also be helpful. |
| 47 | # |
| 48 | # Note that "restrict" applies to both servers and clients, so a configuration |
| 49 | # that might be intended to block requests from certain clients could also end |
| 50 | # up blocking replies from your own upstream servers. |
| 51 | |
| 52 | # By default, exchange time with everybody, but don't allow configuration. |
| 53 | #restrict -4 default kod notrap nomodify nopeer noquery |
| 54 | #restrict -6 default kod notrap nomodify nopeer noquery |
| 55 | restrict -4 default ignore |
| 56 | restrict -6 default ignore |
| 57 | |
| 58 | # Local users may interrogate the ntp server more closely. |
| 59 | restrict 127.0.0.1 |
| 60 | restrict ::1 |
| 61 | |
| 62 | # Clients from this (example!) subnet have unlimited access, but only if |
| 63 | # cryptographically authenticated. |
| 64 | #restrict 192.168.123.0 mask 255.255.255.0 notrust |
| 65 | |
| 66 | |
| 67 | restrict 210.188.224.14 mask 255.255.255.255 nomodify notrap noquery |
| 68 | restrict 133.243.238.163 mask 255.255.255.255 nomodify notrap noquery |
| 69 | restrict 133.243.238.164 mask 255.255.255.255 nomodify notrap noquery |
| 70 | restrict 133.243.238.243 mask 255.255.255.255 nomodify notrap noquery |
| 71 | restrict 133.243.238.244 mask 255.255.255.255 nomodify notrap noquery |
| 72 | restrict 210.173.160.27 mask 255.255.255.255 nomodify notrap noquery |
| 73 | restrict 210.173.160.57 mask 255.255.255.255 nomodify notrap noquery |
| 74 | restrict 210.173.160.87 mask 255.255.255.255 nomodify notrap noquery |
| 75 | restrict 130.158.83.97 mask 255.255.255.255 nomodify notrap noquery |
| 76 | restrict 2001:e40:100:208::123 mask ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff nomodify notrap noquery |
| 77 | restrict 2001:2f8:29:100::fff3 mask ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff nomodify notrap noquery |
| 78 | restrict 2001:2f8:29:100::fff4 mask ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff nomodify notrap noquery |
| 79 | |
| 80 | |
| 81 | # If you want to provide time to your local subnet, change the next line. |
| 82 | # (Again, the address is an example only.) |
| 83 | #broadcast 192.168.123.255 |
| 84 | |
| 85 | # If you want to listen to time broadcasts on your local subnet, de-comment the |
| 86 | # next lines. Please do this only if you trust everybody on the network! |
| 87 | #disable auth |
| 88 | #broadcastclient |
| 89 | }}} |
| 90 | * $ ntpq -p |
| 91 | {{{ |
| 92 | remote refid st t when poll reach delay offset jitter |
| 93 | ============================================================================== |
| 94 | -ntp1.sakura.ad. .GPS. 1 u 5 64 377 0.695 -0.011 0.888 |
| 95 | +2001:e40:100:20 .GPS. 1 u 10 64 377 1.434 -1.154 0.829 |
| 96 | *ntp-a3.nict.go. .NICT. 1 u 13 64 377 1.411 -0.539 0.481 |
| 97 | +ntp-a2.nict.go. .NICT. 1 u 62 64 377 1.357 -1.173 0.486 |
| 98 | +ntp-b3.nict.go. .NICT. 1 u 1 64 377 3.049 -1.105 0.676 |
| 99 | +ntp-a3.nict.go. .NICT. 1 u 61 64 377 2.029 -1.144 0.675 |
| 100 | -ntp-a2.nict.go. .NICT. 1 u 2 64 377 2.069 0.197 0.737 |
| 101 | -ntp3.jst.mfeed. 210.173.160.86 2 u - 64 377 1.292 -0.154 0.824 |
| 102 | -phoenix-gw.netl 210.173.160.87 3 u 61 64 377 8.147 1.432 0.591 |
| 103 | LOCAL(0) .LOCL. 5 l 63 64 377 0.000 0.000 0.001 |
| 104 | }}} |
| 105 | |
| 106 | == fource IPv4 == |