Skip to content
GitLab
  • Menu
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
  • Sign in / Register
  • ntpsec ntpsec
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 58
    • Issues 58
    • List
    • Boards
    • Service Desk
    • Milestones
    • Requirements
  • Merge requests 23
    • Merge requests 23
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Monitor
    • Monitor
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • NTPsecNTPsec
  • ntpsecntpsec
  • Issues
  • #55
Closed
Open
Created May 06, 2016 by Gary E. Miller@garyedmundsmiller💬Maintainer

ntpd refclock GPSD_JSON just stops working.

I have a long running time server. It has gpsd on a GPS, doing PPS. gpsd is reporting time over refclocks SHM and GPSD_JSON. This is a production server, things are only changed infrequently, the gpsd is rock solid.

After a while the GPSD_JSON stops reporting time. The SHM keeps running.

catbert:~# ntpq -p
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
-clepsydra.hpl.h .GPS.            1 u   36   64  377   26.297   -0.420   0.133
-204.152.184.72  .GPS.            1 u   34   64  377   29.243   -2.724   0.357
 nist.netservice .ACTS.           1 u  853 1024    0   59.516   -0.373   0.000
+spidey.rellim.c .GPS1.           1 s   58   64  376    0.189   -0.248   0.025
 SHM(0)          .GPS.            0 l   15   16  377    0.000   11.468   2.281
+SHM(1)          .GPS1.           0 l   15   16  377    0.000    0.203   0.404
*SHM(2)          .SHM.            0 l   13   16  377    0.000   -0.225   0.023
 GPSD_JSON(0)    .GPSD.           0 l 133m   64    0    0.000  -123.69   0.000
 GPSD_JSON(128)  .GPSD.           0 l 134m   64    0    0.000    0.895   0.000

Notice the GPSD_JSON reflock is dead, while the SHM is still working!

SHM(0) is NMEA time

SHM(1) is PPS time

GPSD_JSON(0) is NMEA time from the same gpsd as SHM(0)

GPSD_JSON(128) is GPS time from the same gpsd as SHM(1)

Wild card: SHM(2) is PTP from another local server!

Killing and restarting ntpd fixed the GPSD_JSON() crash.

Here is my mtpq -p after the ntpd restart, notice HSM() and GPSD_JSON() are fine.

catbert:~#  ntpq -p
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
-clepsydra.labs. .GPS.            1 u   27   64    3   26.393   -0.422   0.719
-204.152.184.72  .GPS.            1 u   28   64    3   29.191   -2.215   0.005
 nist.netservice .ACTS.           1 u   24   64    0    0.000    0.000   0.000
+spidey.rellim.c .GPS1.           1 s    6   64    3    0.266   -0.249   0.005
 SHM(0)          .GPS.            0 l    9   16   77    0.000   12.037   0.821
-SHM(1)          .GPS1.           0 l    8   16   77    0.000    0.638   0.351
*SHM(2)          .SHM.            0 l    6   16   77    0.000   -0.248   0.033
-GPSD_JSON(0)    .GPSD.           0 l   22   64    3    0.000  -130.39   0.104
+GPSD_JSON(128)  .GPSD.           0 l   21   64    3    0.000    0.134   0.817

[edited to fix typos and use new driver nomenclature]

Edited Aug 17, 2017 by Eric S. Raymond
Assignee
Assign to
Time tracking