You are not logged in.
Pages: 1
Hi all,
I'm currently having problems configuring my time correctly. According to https://wiki.archlinux.org/index.php/Ne … col_daemon:
The ntp package provides a default configuration file that should make ntpd work out of the box in client mode, without requiring custom configuration.
I've never touched any of ntp's config files, so I would assume that
ntpd -q
would just work. However, this is not the case:
ntpd -qd
9 Apr 15:43:43 ntpd[4399]: ntpd 4.2.8p1@1.3265-o Fri Feb 6 17:14:44 UTC 2015 (1): Starting
9 Apr 15:43:43 ntpd[4399]: Command line: ntpd -qd
9 Apr 15:43:43 ntpd[4399]: proto: precision = 0.105 usec (-23)
Finished Parsing!!
move_fd: estimated max descriptors: 1024, initial socket boundary: 16
9 Apr 15:43:43 ntpd[4399]: Listen and drop on 0 v6wildcard [::]:123
9 Apr 15:43:43 ntpd[4399]: Listen and drop on 1 v4wildcard 0.0.0.0:123
9 Apr 15:43:43 ntpd[4399]: Listen normally on 2 lo 127.0.0.1:123
restrict: op 1 addr 127.0.0.1 mask 255.255.255.255 mflags 00003000 flags 00000001
9 Apr 15:43:43 ntpd[4399]: Listen normally on 3 eth1 134.96.222.6:123
restrict: op 1 addr 134.96.222.6 mask 255.255.255.255 mflags 00003000 flags 00000001
9 Apr 15:43:43 ntpd[4399]: Listen normally on 4 vpn0 134.96.160.58:123
restrict: op 1 addr 134.96.160.58 mask 255.255.255.255 mflags 00003000 flags 00000001
9 Apr 15:43:43 ntpd[4399]: Listen normally on 5 lo [::1]:123
restrict: op 1 addr ::1 mask ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff mflags 00003000 flags 00000001
9 Apr 15:43:43 ntpd[4399]: Listen normally on 6 eth1 [fe80::222:4dff:fe89:589a%4]:123
restrict: op 1 addr fe80::222:4dff:fe89:589a%4 mask ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff mflags 00003000 flags 00000001
9 Apr 15:43:43 ntpd[4399]: Listening on routing socket on fd #23 for interface updates
restrict: op 1 addr 0.0.0.0 mask 0.0.0.0 mflags 00000000 flags 000005f0
restrict: op 1 addr :: mask :: mflags 00000000 flags 000005f0
restrict: op 1 addr 127.0.0.1 mask 255.255.255.255 mflags 00000000 flags 00000000
restrict: op 1 addr ::1 mask ffff:ffff:ffff:ffff:ffff:ffff:ffff:ffff mflags 00000000 flags 00000000
event at 0 0.0.0.0 c016 06 restart
peer_name_resolved(0.arch.pool.ntp.org) rescode 0
key_expire: at 0 associd 41893
peer_clear: at 0 next 2 associd 41893 refid INIT
event at 0 81.88.24.155 8011 81 mobilize assoc 41893
newpeer: 134.96.160.58->81.88.24.155 mode 3 vers 4 poll 6 10 flags 0x101 0x1 ttl 0 key 00000000
peer_name_resolved(1.arch.pool.ntp.org) rescode 0
key_expire: at 0 associd 41894
peer_clear: at 0 next 5 associd 41894 refid INIT
event at 0 80.70.176.51 8011 81 mobilize assoc 41894
newpeer: 134.96.160.58->80.70.176.51 mode 3 vers 4 poll 6 10 flags 0x101 0x1 ttl 0 key 00000000
peer_name_resolved(2.arch.pool.ntp.org) rescode 0
key_expire: at 0 associd 41895
peer_clear: at 0 next 5 associd 41895 refid INIT
event at 0 85.10.240.253 8011 81 mobilize assoc 41895
newpeer: 134.96.160.58->85.10.240.253 mode 3 vers 4 poll 6 10 flags 0x101 0x1 ttl 0 key 00000000
peer_name_resolved(3.arch.pool.ntp.org) rescode 0
key_expire: at 0 associd 41896
peer_clear: at 0 next 3 associd 41896 refid INIT
event at 0 129.70.132.35 8011 81 mobilize assoc 41896
newpeer: 134.96.160.58->129.70.132.35 mode 3 vers 4 poll 6 10 flags 0x101 0x1 ttl 0 key 00000000
select() returned -1: Interrupted system call
auth_agekeys: at 1 keys 0 expired 0
select() returned -1: Interrupted system call
transmit: at 2 134.96.160.58->81.88.24.155 mode 3 len 48
select() returned -1: Interrupted system call
transmit: at 3 134.96.160.58->129.70.132.35 mode 3 len 48
select() returned -1: Interrupted system call
select() returned -1: Interrupted system call
transmit: at 5 134.96.160.58->85.10.240.253 mode 3 len 48
transmit: at 5 134.96.160.58->80.70.176.51 mode 3 len 48
select() returned -1: Interrupted system call
select() returned -1: Interrupted system call
select() returned -1: Interrupted system call
...
and then the command hangs repeating the "Interrupted system call" message endlessly.
Last edited by knue (2015-04-09 12:43:12)
Offline
I've not used ntpd for some time. IIRC, something happened where it had to be run with elevated privilege. Did you try it as root?
Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way
Offline
yes, I've issued above command as root.
Offline
Do you get a response from the ntp server?
ping -c 3 0.arch.pool.ntp.org
Offline
yes
Offline
this is the relevant output I get with strace for the interrupted system call:
select(24, [16 17 18 19 20 21 22 23], NULL, NULL, NULL) = ? ERESTARTNOHAND (To be restarted if no handler)
--- SIGALRM {si_signo=SIGALRM, si_code=SI_KERNEL} ---
rt_sigreturn({mask=[]}) = -1 EINTR (Interrupted system call)
write(1, "select() returned -1: Interrupte"..., 46select() returned -1: Interrupted system call
) = 46
Offline
did you try sniff if some packets are coming back to you and if yes, what is in those reponses?
Offline
not yet. what's a quick way of doing this?
Last edited by knue (2015-04-15 22:49:58)
Offline
Here is the official explanation:
[https://barlog.rusu.info/valentin/blog/?p=395]short answer: we have to wait till all kde5 applications are ported to KF5.
Did you reply to the wrong thread knue?
Offline
yes, I edited the correct reply above, but apparently you were faster
anyway, what's a quick way of doing this sniffing?
Last edited by knue (2015-04-16 10:57:48)
Offline
tcpdump or wireshark
Offline
I had the same problem.
And I checked with tcpdump and I think it was simply because ntpd got no answer from the servers, probably firewalled.
When I use time servers from my network, it works as normal.
Question is why ntpd keeps waiting for so long that one might think it hangs? I think that doesn't make much sense, especially considering the purpose is synchronizing clocks.
Last edited by cro (2015-05-27 13:56:18)
Offline
Try "ntpq -qn".
Tim
Offline
That won't work, try ntpq -p or ntpq -pd .
Last edited by Lone_Wolf (2015-05-28 13:47:29)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Online
Sorry, my mistake. I meant -pn. I've been using systemd-timesyncd so long, I'm forgetting the ntp commands.
Tim
Last edited by ratcheer (2015-05-29 18:33:33)
Offline
Pages: 1