You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What do you think of adding to the NTP monitor an optional check for which source we are currently synchronized with? I have the case that although my chrony configuration is set to prefer a computer connected via ethernet, it sometimes switches to another source. I would like to detect this in the diagnostics.
Implementation details
I only researched how to do it for chrony. Unfortunately there is no python library for chrony so the method uses subprocess.run. We would run chronyc tracking and parse the server name (in this case nuc) and check whether it matches the user-configured wished server
chronyc tracking
Reference ID : C0A80032 (nuc)
Stratum : 4
Ref time (UTC) : Tue Jun 04 14:10:00 2024
System time : 0.000340873 seconds fast of NTP time
Last offset : +0.000357083 seconds
RMS offset : 0.000497816 seconds
Frequency : 10.381 ppm slow
Residual freq : +3.072 ppm
Skew : 1.499 ppm
Root delay : 0.037382413 seconds
Root dispersion : 0.001741173 seconds
Update interval : 32.5 seconds
Leap status : Normal
The text was updated successfully, but these errors were encountered:
tonynajjar
changed the title
NTP monitor: implement diagnostic to check if connected to the correct source
NTP monitor: implement diagnostic to check if synchronized to the correct source
Jun 4, 2024
What do you think of adding to the NTP monitor an optional check for which source we are currently synchronized with? I have the case that although my chrony configuration is set to prefer a computer connected via ethernet, it sometimes switches to another source. I would like to detect this in the diagnostics.
Implementation details
I only researched how to do it for chrony. Unfortunately there is no python library for chrony so the method uses
subprocess.run
. We would runchronyc tracking
and parse the server name (in this casenuc
) and check whether it matches the user-configured wished serverWhat do you think @ct2034?
The text was updated successfully, but these errors were encountered: