[chrony-users] chrony with gps + pps not stable

[ Thread Index | Date Index | More chrony.tuxfamily.org/chrony-users Archives ]


Hello,
        My imxu6l board have RTC and GPS device, sometime,  it maybe should work without network. it use GPIO PPS。
I wan to get high-precision (10 ms) time between different board 。chrony.conf like below:
--------------------------------------------------------------------
logchange 0.5
noclientlog
rtcsync
lock_all
makestep 0.1 -1

refclock SHM 0  offset 0.9 refid GPSD noselect
refclock PPS /dev/pps2 lock GPSD prefer refid PPS trust
--------------------------------------------------------------------

And gpsd run with parameters:
--------------------------------------------------------------------
/usr/sbin/gpsd -n -P /var/run/gpsd.pid -S 2947 /dev/ttymxc2
-------------------------------------------------------------------

When chronyd work with this, the log will record some information:

Thu Dec 23 09:34:03 2021 daemon.info chronyd[1253]: chronyd version 2.4.1 starting (+CMDMON +NTP +REFCLOCK +RTC +PRIVDROP -SCFILTER -SECHASH +ASYNCDNS +IPV6 +DEBUG)
Thu Dec 23 09:34:03 2021 daemon.info chronyd[1253]: Initial frequency -50.497 ppm
Thu Dec 23 09:35:18 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 09:35:18 2021 daemon.warn chronyd[1253]: System clock wrong by -4.158916 seconds, adjustment started
Thu Dec 23 09:35:18 2021 daemon.warn chronyd[1253]: System clock was stepped by -4.158916 seconds
Thu Dec 23 09:41:43 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 09:45:11 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 09:47:19 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 09:48:23 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 09:50:31 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 09:55:03 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 09:59:20 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:04:56 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:07:04 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:10:32 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:12:40 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:13:44 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:15:52 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:17:12 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:19:21 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:24:57 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:29:13 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:34:01 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:38:02 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:41:46 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:43:54 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:50:34 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 10:52:42 2021 daemon..info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 10:57:15 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 11:01:31 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 11:06:03 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 11:08:11 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources
Thu Dec 23 11:13:47 2021 daemon.info chronyd[1253]: Selected source PPS
Thu Dec 23 11:15:56 2021 daemon.info chronyd[1253]: Can't synchronise: no selectable sources


Why it work unstable ? some board work fine at begining, but after few hours, it  lost lock foever !

Then chrony config directive "offset" set to 0.9,  I think this is not suitable, it will case 1 second  deviation。I try to set to 0.2~0.5, it can not lock with SHM0.


tangmc@xxxxxxxxxxx


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/