doktor5000 wrote:xerxes2 wrote:The problem is that Chrony got a feature "rtcsync" that tells the kernel to update the RTC (if kernel got support enabled). But I can't find any info about systemd-timesyncd having the same feature?
That's because that is being done by systemd-timedated:
https://www.freedesktop.org/software/sy ... rvice.html
I see, didn't find that info before. But I uninstalled Chrony and rebooted with timesyncd enabled and haven't rebooted for more than a week and the clocks seems to follow each other.
[xerxes2@ninja ~]$ uptime
19:43:53 up 7 days, 23:29, 1 user, load average: 0,42, 0,52, 0,45
[xerxes2@ninja ~]$ timedatectl status
Local time: sön 2023-11-19 19:43:57 CET
Universal time: sön 2023-11-19 18:43:57 UTC
RTC time: sön 2023-11-19 18:43:57
Time zone: Europe/Stockholm (CET, +0100)
System clock synchronized: yes
NTP service: active
RTC in local TZ: no
And using the adjtimex tool for checking if the setting for telling the kernel/system if NTP is working gives:
[xerxes2@ninja ~]$ adjtimex -p|grep status
status: 24577
24577 decimal is 110000000000001 binary. And the adjtimex manpage says that the sixth bit is the one that says if NTP is working or not. And it looks like 0 means that it does work.
For Linux kernels 2.0 through 2.6, the value is a sum of these:
1 PLL updates enabled
2 PPS freq discipline enabled
4 PPS time discipline enabled
8 frequency-lock mode enabled
16 inserting leap second
32 deleting leap second
64 clock unsynchronized
128 holding frequency
256 PPS signal present
512 PPS signal jitter exceeded
1024 PPS signal wander exceeded
2048 PPS signal calibration error
4096 clock hardware fault
Guessing here the manpage isn't updated in some time haha. So my final conclusion, for now, must be that timesyncd and timedated are updating the setting for telling the system that NTP is working properly.