ntpd 4.2.2가 자체적으로 선택되고 간헐적으로 동기화에 실패합니다. 이것이 버그입니까?

ntpd 4.2.2가 자체적으로 선택되고 간헐적으로 동기화에 실패합니다. 이것이 버그입니까?

질문

안녕하세요, ntp에 문제가 있습니다. 이 상황은 ntpd 버전 4.2.2 및 rhel6에서 항상 발생합니다. rhel7은 이제 ntpd-4.2.6을 사용하지만 일부 시스템에서는 ntpd-4.2.2도 사용합니다. ntpd-4.2.2를 실행하는 수백 대의 시스템이 있지만그 중 절반은 동기화에 실패하고 간헐적으로 자신을 선택합니다.. 왜 이런 일이 발생하는지 모르시나요? 이것은 ntpd의 버그입니까?

client: dmsag(10.13.1.41)
SERVER: 10.13.2.1, 10.13.2.2

클라이언트 NTP 버전:

[[email protected]:/root]
#ntpd --version
ntpd: ntpd [email protected] Mon Dec 29 09:33:00 UTC 2014 (1)

클라이언트 NTP 구성:

[root@dmsag /root]
#cat /etc/ntp.conf

driftfile /var/lib/ntp/drift
pidfile /var/run/ntpd.pid
#logfile /var/log/ntp.log

# Access Control Support
restrict    default ignore
restrict -6 default ignore
restrict    127.0.0.1

restrict    10.13.2.1
restrict    10.13.2.2
# local clock
server 127.127.1.0
fudge 127.127.1.2 stratum 10


server 10.13.2.1 iburst minpoll 4 maxpoll 6 prefer
server 10.13.2.2 iburst minpoll 4 maxpoll 6

서버 NTP 버전:

[root@r7f4a4100 ~]# ntpd --version
ntpd 4.2.6p5
ntpd [email protected] Sat Dec 20 11:11:28 UTC 2014 (1)

클라이언트와 서버 사이에 패킷 교환이 있습니다

[root@dmsag /root]
#tcpdump -i any host 10.13.2.2 and port 123 -nn
tcpdump: WARNING: Promiscuous mode not supported on the "any" device
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on any, link-type LINUX_SLL (Linux cooked), capture size 96 bytes

13:05:44.366753 IP 10.13.1.41.123 > 10.13.2.2.123: NTPv4, Client, length 48
13:05:44.372187 IP 10.13.1.41.123 > 10.13.2.2.123: NTPv4, Client, length 48
13:05:44.366923 IP 10.13.2.2.123 > 10.13.1.41.123: NTPv4, Server, length 48
13:06:48.366735 IP 10.13.1.41.123 > 10.13.2.2.123: NTPv4, Client, length 48
13:06:48.366739 IP 10.13.1.41.123 > 10.13.2.2.123: NTPv4, Client, length 48
13:06:48.366896 IP 10.13.2.2.123 > 10.13.1.41.123: NTPv4, Server, length 48
^C
6 packets captured
6 packets received by filter
0 packets dropped by kernel

고객은 항상 스스로 선택합니다.

[root@dmsag /root]
#ntpq -np
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
*127.127.1.0     .LOCL.           5 l   63   64  377    0.000    0.000   0.001
 10.13.2.1       10.98.94.5       4 u   26   64  377    0.108   -9.741   4.278
 10.13.2.2       10.98.94.5       4 u   23   64  377    0.118  -12.981   5.226

NTP 서버

[root@dmsag /root]
#ssh 10.13.2.1
Last login: Thu Feb  9 13:02:29 2017 from testx.tbsite.net
[root@r7f4a4100 ~]# ntpq -np
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
 127.127.1.0     .LOCL.           5 l  88m   64    0    0.000    0.000   0.000
*10.98.94.5      40.118.106.130   3 u   17   64  377    0.378   23.436  11.696
 10.13.2.1       .INIT.          16 u    -   16    0    0.000    0.000   0.000
+10.13.2.2       10.98.94.5       4 u   11   16  376    0.389    5.377   1.966

디버그

스트레스

[root@dmsag /root]
#strace -p 32121
Process 32121 attached - interrupt to quit
select(19, [16 17 18], NULL, NULL, NULL) = ? ERESTARTNOHAND (To be restarted)
--- SIGALRM (Alarm clock) @ 0 (0) ---
rt_sigreturn(0xe)                       = -1 EINTR (Interrupted system call)
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\1\0\1\0\0\0\0\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef4704, 1092, 0, 0x7fdf33ef45e0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\201\0\1\300\21\0\0\0\0\0\fqb\220\24qc\220\24qd\220\24", 24, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, 16) = 24
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\2\0\0qb\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef51f4, 1092, 0, 0x7fdf33ef50d0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\2\220\24qb\0\0\1\324srcadr=127.127.1.0, "..., 480, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\2\220\24qb\1\324\0\201offset= 0.00 0.00 0."..., 144, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, 16) = 144
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\3\0\0qc\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef5ce4, 1092, 0, 0x7fdf33ef5bc0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\3\220\24qc\0\0\1\322srcadr=10.13.2.1, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\3\220\24qc\1\322\0qfiltoffset= -8.65 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\4\0\0qd\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef67d4, 1092, 0, 0x7fdf33ef66b0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\4\220\24qd\0\0\1\322srcadr=10.13.2.2, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\4\220\24qd\1\322\0qfiltoffset= -9.52 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(55549), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = ? ERESTARTNOHAND (To be restarted)
--- SIGALRM (Alarm clock) @ 0 (0) ---
rt_sigreturn(0xe)                       = -1 EINTR (Interrupted system call)
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\1\0\1\0\0\0\0\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef72c4, 1092, 0, 0x7fdf33ef71a0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\201\0\1\300\21\0\0\0\0\0\fqb\220\24qc\220\24qd\220\24", 24, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, 16) = 24
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\2\0\0qb\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef6d4c, 1092, 0, 0x7fdf33ef6c28, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\2\220\24qb\0\0\1\324srcadr=127.127.1.0, "..., 480, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\2\220\24qb\1\324\0\201offset= 0.00 0.00 0."..., 144, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, 16) = 144
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\3\0\0qc\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef4c7c, 1092, 0, 0x7fdf33ef4b58, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\3\220\24qc\0\0\1\322srcadr=10.13.2.1, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\3\220\24qc\1\322\0qfiltoffset= -8.65 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\4\0\0qd\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef576c, 1092, 0, 0x7fdf33ef5648, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\4\220\24qd\0\0\1\322srcadr=10.13.2.2, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\4\220\24qd\1\322\0qfiltoffset= -9.52 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(45660), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = ? ERESTARTNOHAND (To be restarted)
--- SIGALRM (Alarm clock) @ 0 (0) ---
rt_sigreturn(0xe)                       = -1 EINTR (Interrupted system call)
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\1\0\1\0\0\0\0\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef625c, 1092, 0, 0x7fdf33ef6138, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\201\0\1\300\21\0\0\0\0\0\fqb\220\24qc\220\24qd\220\24", 24, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, 16) = 24
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\2\0\0qb\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef783c, 1092, 0, 0x7fdf33ef7718, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\2\220\24qb\0\0\1\324srcadr=127.127.1.0, "..., 480, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\2\220\24qb\1\324\0\201offset= 0.00 0.00 0."..., 144, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, 16) = 144
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\3\0\0qc\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef4704, 1092, 0, 0x7fdf33ef45e0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\3\220\24qc\0\0\1\322srcadr=10.13.2.1, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\3\220\24qc\1\322\0qfiltoffset= -8.65 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\4\0\0qd\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef51f4, 1092, 0, 0x7fdf33ef50d0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\4\220\24qd\0\0\1\322srcadr=10.13.2.2, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\4\220\24qd\1\322\0qfiltoffset= -9.52 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(37351), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\1\0\1\0\0\0\0\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef5ce4, 1092, 0, 0x7fdf33ef5bc0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\201\0\1\300\21\0\0\0\0\0\fqb\220\24qc\220\24qd\220\24", 24, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, 16) = 24
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\2\0\0qb\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef67d4, 1092, 0, 0x7fdf33ef66b0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\2\220\24qb\0\0\1\324srcadr=127.127.1.0, "..., 480, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\2\220\24qb\1\324\0\201offset= 0.00 0.00 0."..., 144, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, 16) = 144
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\3\0\0qc\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef72c4, 1092, 0, 0x7fdf33ef71a0, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\3\220\24qc\0\0\1\322srcadr=10.13.2.1, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\3\220\24qc\1\322\0qfiltoffset= -8.65 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = 1 (in [17])
select(19, [16 17 18], NULL, NULL, {0, 0}) = 1 (in [17], left {0, 0})
recvfrom(17, "\26\2\0\4\0\0qd\0\0\0\0", 1092, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, [16]) = 12
recvfrom(17, 0x7fdf33ef6d4c, 1092, 0, 0x7fdf33ef6c28, 0x7fffe66de59c) = -1 EAGAIN (Resource temporarily unavailable)
sendto(17, "\326\242\0\4\220\24qd\0\0\1\322srcadr=10.13.2.2, sr"..., 480, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, 16) = 480
sendto(17, "\326\202\0\4\220\24qd\1\322\0qfiltoffset= -9.52 -9"..., 128, 0, {sa_family=AF_INET, sin_port=htons(52421), sin_addr=inet_addr("127.0.0.1")}, 16) = 128
select(19, [16 17 18], NULL, NULL, NULL) = ? ERESTARTNOHAND (To be restarted)

ntpd 디버깅 정보

[root@dmsag /root]
#ntpd -d
ntpd [email protected] Mon Dec 29 09:33:00 UTC 2014 (1)
addto_syslog: precision = 1.000 usec
create_sockets(123)
addto_syslog: no IPv6 interfaces found
addto_syslog: ntp_io: estimated max descriptors: 655360, initial socket boundary: 16
bind() fd 16, family 2, port 123, addr 0.0.0.0, flags=9
Added addr 0.0.0.0 to list of addresses
addto_syslog: Listening on interface wildcard, 0.0.0.0#123 Disabled
bind() fd 17, family 2, port 123, addr 127.0.0.1, flags=5
Added addr 127.0.0.1 to list of addresses
addto_syslog: Listening on interface lo, 127.0.0.1#123 Enabled
bind() fd 18, family 2, port 123, addr 10.13.1.41, flags=25
Added addr 10.13.1.41 to list of addresses
addto_syslog: Listening on interface bond0, 10.13.1.41#123 Enabled
init_io: maxactivefd 18
local_clock: time 0 base 0.000000 offset 0.000000 freq 0.000 state 0
addto_syslog: frequency initialized 51.952 PPM from /var/lib/ntp/drift
key_expire: at 0
peer_clear: at 0 next 1 assoc ID 57098 refid INIT
newpeer: 127.0.0.1->127.127.1.0 mode 3 vers 4 poll 6 10 flags 0x1021 0x1 ttl 0 key 00000000
key_expire: at 0
peer_clear: at 0 next 2 assoc ID 57099 refid INIT
newpeer: 10.13.1.41->10.13.2.1 mode 3 vers 4 poll 4 6 flags 0x281 0x1 ttl 0 key 00000000
key_expire: at 0
peer_clear: at 0 next 3 assoc ID 57100 refid INIT
newpeer: 10.13.1.41->10.13.2.2 mode 3 vers 4 poll 4 6 flags 0x201 0x1 ttl 0 key 00000000
local_clock: time 0 base 0.000000 offset 0.000000 freq 51.952 state 1
report_event: system event 'event_restart' (0x01) status 'sync_alarm, sync_unspec, 1 event, event_unspec' (0xc010)
refclock_transmit: at 1 127.127.1.0
refclock_receive: at 1 127.127.1.0
peer LOCAL(0) event 'event_reach' (0x84) status 'unreach, conf, 1 event, event_reach' (0x8014)
refclock_sample: n 1 offset 0.000000 disp 0.010000 jitter 0.000001
clock_filter: n 1 off 0.000000 del 0.000000 dsp 7.937500 jit 0.000001, age 0
auth_agekeys: at 1 keys 1 expired 0
timer: refresh ts 0
transmit: at 2 10.13.1.41->10.13.2.1 mode 3
receive: at 2 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
peer 10.13.2.1 event 'event_reach' (0x84) status 'unreach, conf, 1 event, event_reach' (0x8014)
clock_filter: n 1 off -0.003512 del 0.000076 dsp 7.937501 jit 0.000001, age 0
transmit: at 3 10.13.1.41->10.13.2.2 mode 3
receive: at 3 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
peer 10.13.2.2 event 'event_reach' (0x84) status 'unreach, conf, 1 event, event_reach' (0x8014)
clock_filter: n 1 off -0.016462 del 0.000136 dsp 7.937501 jit 0.000001, age 0
transmit: at 4 10.13.1.41->10.13.2.1 mode 3
receive: at 4 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 2 off -0.003512 del 0.000076 dsp 3.937516 jit 0.000001, age 2
transmit: at 5 10.13.1.41->10.13.2.2 mode 3
receive: at 5 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 2 off -0.016537 del 0.000132 dsp 3.937508 jit 0.000075, age 0
transmit: at 6 10.13.1.41->10.13.2.1 mode 3
receive: at 6 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 3 off -0.003512 del 0.000076 dsp 1.937538 jit 0.000008, age 4
transmit: at 7 10.13.1.41->10.13.2.2 mode 3
receive: at 7 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 3 off -0.016604 del 0.000129 dsp 1.937516 jit 0.000111, age 0
transmit: at 8 10.13.1.41->10.13.2.1 mode 3
receive: at 8 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 4 off -0.003512 del 0.000076 dsp 0.937565 jit 0.000011, age 6
transmit: at 9 10.13.1.41->10.13.2.2 mode 3
receive: at 9 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 4 off -0.016604 del 0.000129 dsp 0.937537 jit 0.000099, age 2
transmit: at 10 10.13.1.41->10.13.2.1 mode 3
receive: at 10 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 5 off -0.003512 del 0.000076 dsp 0.437593 jit 0.000013, age 8
transmit: at 11 10.13.1.41->10.13.2.2 mode 3
receive: at 11 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 5 off -0.016745 del 0.000128 dsp 0.437533 jit 0.000192, age 0
transmit: at 12 10.13.1.41->10.13.2.1 mode 3
receive: at 12 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 6 off -0.003512 del 0.000076 dsp 0.187620 jit 0.000015, age 10
transmit: at 13 10.13.1.41->10.13.2.2 mode 3
receive: at 13 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 6 off -0.016745 del 0.000128 dsp 0.187558 jit 0.000175, age 2
transmit: at 14 10.13.1.41->10.13.2.1 mode 3
receive: at 14 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 7 off -0.003512 del 0.000076 dsp 0.062639 jit 0.000019, age 12
transmit: at 15 10.13.1.41->10.13.2.2 mode 3
receive: at 15 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 7 off -0.016886 del 0.000129 dsp 0.062544 jit 0.000274, age 0
transmit: at 16 10.13.1.41->10.13.2.1 mode 3
receive: at 16 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 8 off -0.003512 del 0.000076 dsp 0.000167 jit 0.000020, age 14
transmit: at 17 10.13.1.41->10.13.2.2 mode 3
receive: at 17 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 8 off -0.016886 del 0.000129 dsp 0.000066 jit 0.000255, age 2
transmit: at 18 10.13.1.41->10.13.2.1 mode 3
receive: at 18 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 8 off -0.003512 del 0.000106 dsp 0.000136 jit 0.000023, age 14
transmit: at 19 10.13.1.41->10.13.2.1 mode 3
key_expire: at 19
transmit: at 19 10.13.1.41->10.13.2.2 mode 3
receive: at 19 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 8 off -0.017033 del 0.000112 dsp 0.000048 jit 0.000320, age 0
receive: at 19 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 8 off -0.003543 del 0.000110 dsp 0.000060 jit 0.000012, age 5
transmit: at 20 10.13.1.41->10.13.2.2 mode 3
key_expire: at 20
receive: at 20 10.13.1.41<-10.13.2.2 mode 4 code 1 auth 0
clock_filter: n 8 off -0.017033 del 0.000112 dsp 0.000035 jit 0.000260, age 1
transmit: at 35 10.13.1.41->10.13.2.1 mode 3
receive: at 35 10.13.1.41<-10.13.2.1 mode 4 code 1 auth 0
clock_filter: n 8 off -0.003543 del 0.000110 dsp 0.000271 jit 0.000018, age 21

답변1

내 생각엔 현지 시계의 등급이 너무 높은 것 같아요. 동기화하려는 시계보다 최소 2레벨 낮아야 합니다. 로컬 시계에 권장되는 구성은 다음과 같습니다.

단일 시간 서버:

# local clock
server 127.127.1.0
fudge  127.127.1.0 stratum 10

당신은:

# local clock
server 127.127.1.0
fudge 127.127.1.2 stratum 10

당신의 NTPQ:

#ntpq -np
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
*127.127.1.0     .LOCL.           5 l   63   64  377    0.000    0.000   0.001
 10.13.2.1       10.98.94.5       4 u   26   64  377    0.108   -9.741   4.278
 10.13.2.2       10.98.94.5       4 u   23   64  377    0.118  -12.981   5.226

이는 레이어 10이 아닌 레이어 5에 대한 로컬 시계를 보여줍니다.완벽한시계, 사용됩니다.

(원천)

관련 정보