[ntp:hackers] I do not know if it is a bug
Luis Batanero
luisbat at gmail.com
Thu Mar 25 10:50:06 UTC 2010
Hi,
I'm experimenting with the SHM driver with the driver ATOM.
My configuration is:
"
server 127.127.28.0 minpoll 4 prefer true
fudge 127.127.28.0 time1 0.275 flag4 1
server 127.127.22.0 minpoll 4
fudge 127.127.22.0 flag2 1 flag3 1 flag4 1
"
When I launch the program operation is correct: SHM is selected and
the ATOM used as PPS peer.
"
ntpq> pee
remote refid st t when poll reach delay offset jitter
==============================================================================
*SHM(0) .SHM. 0 l 13 16 77 0.000 5.652 2.928
oPPS(0) .PPS. 0 l 12 16 37 0.000 0.535 0.157
ntpq> rv
associd=0 status=011d leap_none, sync_pps, 1 event, kern,
version="ntpd 4.2.6 at 1.2089-o Wed Mar 24 08:49:57 UTC 2010 (2)",
processor="i386", system="FreeBSD/8.0-RELEASE-p2", leap=00, stratum=1,
precision=-19, rootdelay=0.000, rootdisp=438.511, refid=PPS,
reftime=cf54517c.0cce9eca Wed, Mar 24 2010 9:53:16.050,
clock=cf545184.c04d708c Wed, Mar 24 2010 9:53:24.751, peer=7815, tc=4,
mintc=3, offset=0.535, frequency=-67.674, sys_jitter=0.157,
clk_jitter=0.005, clk_wander=0.059
"
Soon the PPS is dismissed as falseticker:
"ntpq> pee
remote refid st t when poll reach delay offset jitter
==============================================================================
*SHM(0) .SHM. 0 l 4 16 377 0.000 -6.083 2.802
xPPS(0) .PPS. 0 l 2 16 377 0.000 -0.001 0.002
ntpq> rv
associd=0 status=091d leap_none, sync_telephone, 1 event, kern,
version="ntpd 4.2.6 at 1.2089-o Wed Mar 24 08:49:57 UTC 2010 (2)",
processor="i386", system="FreeBSD/8.0-RELEASE-p2", leap=00, stratum=1,
precision=-19, rootdelay=0.000, rootdisp=9.101, refid=SHM,
reftime=cf54653b.0ced5ed6 Wed, Mar 24 2010 11:17:31.050,
clock=cf54653c.c7c33e26 Wed, Mar 24 2010 11:17:32.780, peer=7814, tc=4,
mintc=3, offset=-5.186, frequency=-67.855, sys_jitter=2.269,
clk_jitter=0.002, clk_wander=0.004"
Apparently the intersection algorithm discards the PPS.
I found some code that I think is wrong but does not explain this malfunction:
--- ntp_proto.c.original 2010-03-24 11:35:01.000000000 +0100
+++ ntp_proto.c 2010-03-24 11:35:29.000000000 +0100
@@ -2677,7 +2677,7 @@
* if there is a prefer peer or there are no survivors and none
* are required.
*/
- if (typepps != NULL && fabs(sys_offset < 0.4) &&
+ if (typepps != NULL && fabs(sys_offset) < 0.4 &&
(typepps->refclktype != REFCLK_ATOM_PPS ||
(typepps->refclktype == REFCLK_ATOM_PPS && (sys_prefer !=
NULL || (typesystem == NULL && sys_minsane == 0))))) {
Thanks in advance,
Luis.
More information about the hackers
mailing list