Does the -g apply to sync the daemon to the local clock driver with this configuration, if external server takes longer time to become reachable?
ntpd.config.param=restrict default noquery nomodify notrap;restrict 127.0.0.1;server 127.127.1.0 minpoll 3 maxpoll 3 iburst;tos orphanwait 8 minclock 6;server 192.168.1.14 iburst minpoll 6;
ntpd.init.param=-g -f /tffs0/ntpd_driftfile
If for example the local system clock is defaulted to Jan 01, 2000; then when system is started, the daemon will synch up with the local clock driver first as it will likely take longer time for the external server to become reachable. Thus, when the external server is reachable, and daemon detects a large offset, the daemon will exit (since the -g applies only once).
How can we make the -g option apply only when external server becomes reachable and not when it synch's to the local clock?
If we keep the orphanwait time to default of 300 seconds, the daemon will not have this issue as it should not take that long to reach the external server and synch up with it under normal conditions. But this 5 minutes delay will make the daemon (server part) not ready to serve clients for at least 5 minutes, which is problematic in our case.
Using the orphanwait to reduce the time it takes ntpd to synch up with the local system clock, as in this configuration, we need to have the server part of ntpd to be ready as soon as possible to serve some other devices (regardless of whether the time is valid or not, or has synch'ed or not with the external server). If we keep the default orphanwait (300 seconds), the daemon won't be able to serve the other devices while trying to synch with the
external server and may take up to 5 minutes before it can start serving them if the external server was not reachable/could synch with earlier.
Configuring a local refclock as we want ntpd to be a server for other devices,
and so we want this server to become available asap and sync with a time source quickly.
Configuring a local refclock as we want ntpd to be a server for other devices,
and so we want this server to become available asap and sync with a time source quickly.
rcheaito via questions Mailing List wrote:
Using the orphanwait to reduce the time it takes ntpd to synch up with the >> local system clock, as in this configuration, we need to have the server partAll that sounds reasonable, IFF you don't know anything about how NTPD actually works!
of ntpd to be ready as soon as possible to serve some other devices
(regardless of whether the time is valid or not, or has synch'ed or not with >> the external server). If we keep the default orphanwait (300 seconds), the >> daemon won't be able to serve the other devices while trying to synch with the
external server and may take up to 5 minutes before it can start serving them
if the external server was not reachable/could synch with earlier.
Configuring a local refclock as we want ntpd to be a server for other devices,
and so we want this server to become available asap and sync with a time
source quickly.
What you need is iburst, possibly along with burst and minpoll 4,
against a network-locally ntpd server.
You really, really, really does not want your NTP server to provide
bodus time to any client, at any point in time! It is far better to not
reply than to be a falseticker for several minutes.
If you cannot guarantee WAN network connectivity, then I strongly
encourage you to setup a local GPS reference for your server. I don't
know what the current best/cheapest option is but more than 10 years ago
you could buy a Sure reference board for ~$80, solder a single line to
route the PPS signal to the RS232 Carrier Detect pin, and you would have
a clock that was accurate to maybe 25 ns RMS.
Terje
On 2025-03-28, Terje Mathisen <terje.mathisen@tmsw.no> wrote:
rcheaito via questions Mailing List wrote:
Using the orphanwait to reduce the time it takes ntpd to synch up with the >>> local system clock, as in this configuration, we need to have the server partAll that sounds reasonable, IFF you don't know anything about how NTPD
of ntpd to be ready as soon as possible to serve some other devices
(regardless of whether the time is valid or not, or has synch'ed or not with
the external server). If we keep the default orphanwait (300 seconds), the >>> daemon won't be able to serve the other devices while trying to synch with the
external server and may take up to 5 minutes before it can start serving them
if the external server was not reachable/could synch with earlier.
Configuring a local refclock as we want ntpd to be a server for other devices,
and so we want this server to become available asap and sync with a time >>> source quickly.
actually works!
What you need is iburst, possibly along with burst and minpoll 4,
against a network-locally ntpd server.
You really, really, really does not want your NTP server to provide
bodus time to any client, at any point in time! It is far better to not
reply than to be a falseticker for several minutes.
If you cannot guarantee WAN network connectivity, then I strongly
encourage you to setup a local GPS reference for your server. I don't
know what the current best/cheapest option is but more than 10 years ago
you could buy a Sure reference board for ~$80, solder a single line to
route the PPS signal to the RS232 Carrier Detect pin, and you would have
a clock that was accurate to maybe 25 ns RMS.
I think the biggest problem is that most computers no longer have a
serial or parallel input port and
I don't think usb has the needed interrupt accuracy.
The price of gps receivers is less than $50, but am not sure of their
timing capability
Terje
Caution advised. When I monitored a FC-NTP-Mini 1.5 years ago the
timestamp resolution was only 1 msec.
Additionally once in 2000 NTP responses the time stamp was in error by 1 second (top of the second problem).
Things may have improved since then.
C:\Users\win-8>ntpq -pn osloI note that you are not processing NMEA data at all. You might want to
remote refid st t when poll reach delay offset jitter
==============================================================================
127.127.20.1 .NMEA. 0 l - 16 0 0.000 +0.000 0.000
o127.127.22.1 .uPPS. 0 l 14 16 377 0.000 +0.033 0.002
*192.168.0.20 .GPS. 1 u 21 32 377 0.462 -0.106 0.028
+192.168.0.3 .PPS. 1 u 6 32 377 0.463 -0.142 0.030
+192.168.0.71 .PPS. 1 u 9 32 377 0.693 -0.139 0.029
fix that.
On Fri, Mar 28, 2025 at 04:37:09PM -0500, Steven Sommars wrote:
Caution advised. When I monitored a FC-NTP-Mini 1.5 years ago the
timestamp resolution was only 1 msec.
Additionally once in 2000 NTP responses the time stamp was in error by 1
second (top of the second problem).
Things may have improved since then.
I have been running a pair of them for 995 days, do extensive graphing
of all the ntp servers here, and have noticed nothing strange.
remote refid st t when poll reach delay offset jitter
==============================================================================
*127.127.28.0 .SHM. 0 l 5 16 377 0.000 +3.562 2.434
-192.168.0.21 .PPS. 1 u 19 64 377 1.326 -2.751 1.908
+192.168.0.100 .PPS. 1 u 48 64 377 0.077 -3.755 0.878
+192.168.0.101 .PPS. 1 u 56 64 377 1.150 -3.295 1.724
-192.168.0.185 .PPS. 1 u 2 64 377 1.120 -1.329 0.890
The SHM server is a ublox USB GNSS.
The .21 server is a Raspberry Pi with a late model GNSS HAT.
The .100 and .101 servers are FC-NTP-Minis.
The .185 server is a precision steared, temperature controlled
oscillator box with a GNSS receiver and a specified PPS accurace of +/-
1 nanosecond.
On 28/03/2025 21:54, Jim Pennino wrote:
On Fri, Mar 28, 2025 at 04:37:09PM -0500, Steven Sommars wrote:
Caution advised. When I monitored a FC-NTP-Mini 1.5 years ago the
timestamp resolution was only 1 msec.
Additionally once in 2000 NTP responses the time stamp was in error by 1 >>> second (top of the second problem).
Things may have improved since then.
I have been running a pair of them for 995 days, do extensive graphing
of all the ntp servers here, and have noticed nothing strange.
remote refid st t when poll reach delay offset jitter
==============================================================================
*127.127.28.0 .SHM. 0 l 5 16 377 0.000 +3.562 2.434
-192.168.0.21 .PPS. 1 u 19 64 377 1.326 -2.751 1.908
+192.168.0.100 .PPS. 1 u 48 64 377 0.077 -3.755 0.878
+192.168.0.101 .PPS. 1 u 56 64 377 1.150 -3.295 1.724
-192.168.0.185 .PPS. 1 u 2 64 377 1.120 -1.329 0.890
The SHM server is a ublox USB GNSS.
The .21 server is a Raspberry Pi with a late model GNSS HAT.
The .100 and .101 servers are FC-NTP-Minis.
The .185 server is a precision steared, temperature controlled
oscillator box with a GNSS receiver and a specified PPS accurace of +/-
1 nanosecond.
Jim,
May I suggest making comparisons on a device with (working) PPS synchronisation.
This should make the jitter and offset values more consistent.
As an example, here I'm looking at a Win-11 PC (Oslo) with PPS sync for its NTP,
viewing its remote servers:
C:\Users\win-8>ntpq -pn oslo
remote refid st t when poll reach delay offset jitter
==============================================================================
127.127.20.1 .NMEA. 0 l - 16 0 0.000 +0.000 0.000
o127.127.22.1 .uPPS. 0 l 14 16 377 0.000 +0.033 0.002
*192.168.0.20 .GPS. 1 u 21 32 377 0.462 -0.106 0.028
+192.168.0.3 .PPS. 1 u 6 32 377 0.463 -0.142 0.030
+192.168.0.71 .PPS. 1 u 9 32 377 0.693 -0.139 0.029
.20 - LeoNTP (old version)
.3 - Linux box (x86) with PPS feed
.71 - Raspberry Pi with PPS feed
The delays are higher than I would wish, but likely due to multiple switches in
the paths and some parts be just 100 Mbps links
Cheers,
David
--
SatSignal Software - Quality software for you
Web: https://www.satsignal.eu
Email: davidtaylor@writeme.com
BlueSky: @gm8arv.bsky.social, Twitter: @gm8arv
On 29/03/2025 14:47, Jim Pennino wrote:
C:\Users\win-8>ntpq -pn osloI note that you are not processing NMEA data at all. You might want to
remote refid st t when poll reach delay offset jitter
==============================================================================
127.127.20.1 .NMEA. 0 l - 16 0 0.000 +0.000 0.000
o127.127.22.1 .uPPS. 0 l 14 16 377 0.000 +0.033 0.002
*192.168.0.20 .GPS. 1 u 21 32 377 0.462 -0.106 0.028
+192.168.0.3 .PPS. 1 u 6 32 377 0.463 -0.142 0.030
+192.168.0.71 .PPS. 1 u 9 32 377 0.693 -0.139 0.029
fix that.
I hope the new values you post will help others to determine the performance of
the FC-NTP-Minis.
You are correct about the NMEA. In the configuration I used above there is only
the PPS line in use from the GPS. The other servers provide the date information, and are marked as "prefer" in the NTP configuration.
Cheers,
David
--
SatSignal Software - Quality software for you
Web: https://www.satsignal.eu
Email: davidtaylor@writeme.com
BlueSky: @gm8arv.bsky.social, Twitter: @gm8arv
So why bother to have a configuration line for something that doesn't
exist?
You could of course attach a USB device to provide NMEA data.
New values for what?
On 30/03/2025 15:27, Jim Pennino wrote:
So why bother to have a configuration line for something that doesn't
exist?
You could of course attach a USB device to provide NMEA data.
New values for what?
Jim,
It was probably history just copying from a previous configuration. I might add
NMEA later but it's not needed in my configuration.
New values for the comparison of the FC-NTP-Minis you presented.
Cheers,
David
--
SatSignal Software - Quality software for you
Web: https://www.satsignal.eu
Email: davidtaylor@writeme.com
BlueSky: @gm8arv.bsky.social, Twitter: @gm8arv
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 498 |
Nodes: | 16 (3 / 13) |
Uptime: | 48:06:16 |
Calls: | 9,807 |
Calls today: | 9 |
Files: | 13,754 |
Messages: | 6,190,080 |