Where do I find NTP logs?

Hi everybody,

I am looking for NTP logs on our TrueNAS Scale. There are none under the keyword “NTP” or Service = “NTP” in the Audit section and also none with journalctl | grep ntp or journalctl | grep systemd-timesyncd on the shell.

I got an NTP server listed under “System Settings → General” but it doesn’t seem to be syncing (at least the time is incorrect by 3 minutes) while other servers in the network sync fine with this server.

To troubleshoot the issue, I was looking for any kind of logs that contain error messages related to NTP. On my other servers, the command journalctl | grep systemd-timesyncd will yield messages like:

Dec 27 05:13:32 hostname systemd-timesyncd[1608192]: Timed out waiting for reply from 80.153.195.191:123 (0.debian.pool.ntp.org).
Dec 27 05:13:32 hostname systemd-timesyncd[1608192]: Contacted time server 129.70.132.33:123 (0.debian.pool.ntp.org).

But in Scale it doesn’t. Which NTP service is used there?

Thanks in advance for any help!

Q: Are you running TrueNAS virtualized or bare metal?

TrueNAS SCALE uses chronyd daemon for time sync

journalctl | grep chronyd
chronyc sources -v

Conf file is located /etc/chrony/chrony.conf

You have to uncomment the following line to enable statistics

#log tracking measurements statistics

Then use the following CLI to restart the chronyd daemon

service chronyd restart

Note: if you make subsequent changes via the System → General → NTP Servers it will over write the conf file.

Thanks a lot!

The chronyc sources -v command shows that the NTP server is “unusable” and has an offset of 181.9 seconds. That does not sound like it is working. Maybe I need to check the network connections between it and the TrueNAS, then. :smiley:

Offset might be too large for it to sync or too much jitter.

chronyc -a makestep

Might want to check the CMOS battery. New is typically 3.3V. Anything less than 3.0V it might be time to replace.

cat /proc/driver/rtc | grep batt
journalctl -k -g rtc   

Personally, I run a Stratum 0 GPS+PPS reference clock on my pfSense firewall backed up with a time.nist.gov pool

For the battery it just says “batt_status: okay”, so that looks good.

I now added a pool.ntp.org server as a second NTP server and it synced well with that. Our server is still showing up as “unusable” so probably an issue with the network between the TrueNAS and the server. It is a different network than the other servers that sync fine to this NTP server.