[ntp:questions] PPS on Linux status?

Michael L. Semon mlsemon33 at verizon.net
Mon May 14 19:05:42 UTC 2007

Martin Karsten wrote:
> My apologies if I am beating a dead horse, but I've spent several hours
> today searching for a definite answer to the subject line question.
> The PPS part of the ntp documentation at one point refers to the PPSkit
> for Linux and at another point says "The FreeBSD, Linux and Solaris
> implementations can be used with the stock kernels provided with those
> systems;" about the ntp PPS driver.
> I understand that a full-scale PPS "system" in the kernel (and the PPS
> api) may not be needed to get ntp working with PPS (e.g. that seems to
> be the case for Solaris), but at least some level of support is probably
> required from the kernel (in the serial driver)? Does the stock Linux
> kernel (e.g. any recent 2.6 variant) support PPS or do I have to use an
> extension such as PPSkit to use a PPS signal on Linux for ntpd?
> I have a setup (server GPS/PPS) for which on a FreeBSD
> machine, ntptime shows the PPSSIGNAL status bit, but not on Linux.
> Any help would be greatly appreciated.
> Thanks,
> Martin

You have a FreeBSD reference system, so this should be easy.  If your 
Linux boxes keep time almost as well as does the FreeBSD system--but not 
quite--then you're done.  Otherwise, you have some work to do.

AFAIK, stock Linux kernels do not support PPS.  Whatever you're using 
with the NMEA driver (, an `ntpq -p` should give you what 
you want.  Check the offsets and see if they're typical of your GPS with 
PPS or without PPS.  For my GPS (a Garmin GPS 18 LVC), the offsets are 
typically +/- 3-4 ms without PPS and +/- 0.010 ms with PPS.  The `ntpdc 
-c kerninfo` command is quite handy, too, and will break down the flags 
to show how well your PPS is or is not being recognized.

My take on the NMEA driver doc is this:  If the OS supports PPSAPI, then 
the driver will use the PPS; otherwise, the driver will act like the PPS 
is not there.

You can get PPSkit for Linux 2.4 kernels, and it works great.  You can 
get an alpha version of PPSkit for early 2.6 kernels, and it does the 
job but with not so much finesse.  For 2.6 kernels in general, you can 
hunt down LinuxPPS, which is pretty good.

The ppssignal flag seems to be related to whether the kernel is using 
hardpps, as if you had this in your ntp.conf...

server flag3 1

...but absence of the ppssignal flag is no big deal.  Just make sure 
that the overall accuracy is to your liking.


More information about the questions mailing list