You are not logged in.
Hi,
I am trying to get the systemd ntpd variant working. I have enabled en started the systemd-timesyncd and systemd-timedated services. After the initial sync noting happens?! Shouldn't it be syncing once every so-and-so minutes?
Thanks.
Alexander
Last edited by K3N8 (2018-05-22 16:34:08)
Arch Linux x86_64 LTS
Offline
How are you determining that it isn't syncing?
The default config contains...
...
#PollIntervalMinSec=32
#PollIntervalMaxSec=2048
so the max interval is about 34 minutes between syncs.
Offline
OP, you may be seeing this bug https://bbs.archlinux.org/viewtopic.php?id=236598. That bug has been fixed in the systemd master branch but still exists in the current Arch systemd 238.76-1 package.
Offline
I have looked in the wrog place.
journalctl -r -u systemd-timesyncd
I should have looked at:
stat /var/lib/systemd/timesync/clock
Everything is ok.
Arch Linux x86_64 LTS
Offline
I have looked in the wrog place.
journalctl -r -u systemd-timesyncd
I should have looked at:
stat /var/lib/systemd/timesync/clock
That doesn't sound right. You are guaranteed to see a "Synchronized to time server xx.xx.xx.xx" message in the output of your journal seconds after boot if systemd-timesyncd is running correctly.
journalctl -b -u systemd-timesyncd | grep "Synchronized to time server"
Note that the /var/lib/systemd/timesync/clock file is first updated after boot at the same exact time as the above message is written. Also, that file can only be viewed/stat by root.
Offline
It only shows syncing on startup
journalctl -b -u systemd-timesyncd | grep "Synchronized to time server"
mei 18 19:53:25 boaz systemd-timesyncd[11149]: Synchronized to time server 5.39.184.5:123 (0.arch.pool.ntp.org).
mei 22 12:38:17 boaz systemd-timesyncd[18072]: Synchronized to time server 149.210.230.59:123 (0.arch.pool.ntp.org).
mei 22 13:33:15 boaz systemd-timesyncd[18560]: Synchronized to time server 213.109.127.82:123 (0.arch.pool.ntp.org).
cat /var/lib/systemd/timesync/clock
Bestand: /var/lib/systemd/timesync/clock
Grootte: 0 Blokken: 0 IO-blok: 4096 leeg normaal bestand
Apparaat: fd01h/64769d Inode: 1446401 Koppelingen: 1
Toegang: (0644/-rw-r--r--) UID: (62583/systemd-timesync) GID: (62583/systemd-timesync)
Toegang: 2018-05-23 10:01:08.954430716 +0200
Gewijzigd: 2018-05-23 10:01:08.954430716 +0200
Veranderd: 2018-05-23 10:01:08.954430716 +0200
Last edited by K3N8 (2018-05-24 08:06:58)
Arch Linux x86_64 LTS
Offline
'man systemd-timesyncd' suggests that the /var/lib/systemd/timesync/clock file should contain the timestamp of the last successful sync, but the file size (grootte) is 0 (empty), so I would second the opinion that there is a bug. Either that or the documentation is wrong.
FILES /var/lib/systemd/timesync/clock This file contains the timestamp of the last successful synchronization.
Sakura:-
Mobo: MSI MAG X570S TORPEDO MAX // Processor: AMD Ryzen 9 5950X @4.9GHz // GFX: AMD Radeon RX 5700 XT // RAM: 32GB (4x 8GB) Corsair DDR4 (@ 3000MHz) // Storage: 1x 3TB HDD, 6x 1TB SSD, 2x 120GB SSD, 1x 275GB M2 SSD
Making lemonade from lemons since 2015.
Offline