ntpd flipping between PLL and FLL mode

Roland Smith rsmith at xs4all.nl
Tue Dec 19 05:34:51 PST 2006

On Tue, Dec 19, 2006 at 04:41:51AM -0800, Jeremy Chadwick wrote:
> Dec 19 00:22:26 icarus ntpd[624]: kernel time sync enabled 2001
> Dec 19 01:47:48 icarus ntpd[624]: kernel time sync enabled 6001
> Dec 19 02:04:52 icarus ntpd[624]: kernel time sync enabled 2001

Looks very familiar, unfortunately.

> I looked at the ntpd code for this, and there does not appear to
> be a way to disable logging of this message without impacting other
> important ntpd messages.  :-(

Since this is about the only message I ever see from ntpd, I put the
following line in /etc/ntpd.conf:

logconfig -syncall

At least this got rid of those annoying messages. Maybe syncinfo or
syncevents would be sufficient to kill these messages. I haven't checked
if LOG_NOTICE in the source code is equivalent to the message type
"info" in the manpage. 

IMHO, it violates the tradition that programs shouldn't blather.

The following patch to ntp_loopfilter.c should quell the message:
-------------------- STFU patch --------------------
--- ntp_loopfilter.c.orig       Tue Dec 19 14:13:25 2006
+++ ntp_loopfilter.c    Tue Dec 19 14:14:02 2006
@@ -593,12 +593,6 @@
                                    "kernel time sync disabled %04x",
                        ntv.status &= ~(STA_PPSFREQ | STA_PPSTIME);
-               } else {
-                       if (ntv.status != pll_status)
-                               NLOG(NLOG_SYNCEVENT | NLOG_SYSEVENT)
-                                   msyslog(LOG_NOTICE,
-                                   "kernel time sync enabled %04x",
-                                   ntv.status);
                pll_status = ntv.status;
                if (pll_nano)
-------------------- STFU patch --------------------

R.F.Smith                                   http://www.xs4all.nl/~rsmith/
[plain text _non-HTML_ PGP/GnuPG encrypted/signed email much appreciated]
pgp: 1A2B 477F 9970 BA3C 2914  B7CE 1277 EFB0 C321 A725 (KeyID: C321A725)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20061219/6e30ac86/attachment.pgp

More information about the freebsd-stable mailing list