ntpd problem freebsd 5.3 [ and Re: I found your question
about NTPd on Sep 27]
Christian Hiris
4711 at chello.at
Sun Nov 21 23:34:59 PST 2004
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Monday 22 November 2004 03:40, animecowboy at animecowboy.com wrote:
> I am having the same problem you mentioned here.
> http://lists.freebsd.org/pipermail/freebsd-questions/2004-September/059279.
> html
>
> I was wondering if you ever found out the cause and/or a way to correct the
> problem.
As this answer appears to be more complete, than my first one, I attached it
to the original thread, just for the archives. I'm not a ntp specialist, so
maybe there are some things that I misunderstood, but I think it's better
than no answer. ;-)
> Sep 23 17:13:41 panther ntpd[467]: kernel time sync enabled 2001
> Sep 23 21:29:44 panther ntpd[467]: kernel time sync enabled 6001
> Sep 23 21:46:48 panther ntpd[467]: kernel time sync enabled 2001
> Sep 24 01:11:39 panther ntpd[467]: kernel time sync enabled 6001
> Sep 24 01:45:47 panther ntpd[467]: kernel time sync enabled 2001
> Sep 24 02:19:59 panther ntpd[467]: kernel time sync enabled 6001
IMHO this isn't a problem - the messages are informational. ntpd just switches
(kernel) clock discipline modes between PLL (Phase-Locked-Loop) and FLL
(Frequency-Locked-Loop).
I recently found a good documentation on ntpd PLL/FLL hybrid mode (including
the differences between ntp v3/v4 PLL/FLL mode's handling):
http://www.eecis.udel.edu/~mills/database/papers/allan.pdf
I was pointed to the above link by
http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/contrib/ntp/html/kern.html
You also can find this document in /usr/src, if you have sources installed on
your system.
As I mentioned, there seems to be nothing wrong with messages 6001 and 2001.
Kernel time discipline (and probably kernel time discipline messages) could
be disabled via ntpdc control message's or ntpd config-file's "disable
kernel" option. I think this also would disable nano-second
clock-disciplining ability, so I would left it enabled. I never tried to
disable kernel time discipline, so I can't imagine what would happen in real
life ...
http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/contrib/ntp/html/miscopt.html
See also the option "tinker allan" option. This option allows you to change
the seconds for minimum Allan intercept, which is a parameter of the PLL/FLL
clock discipline algorithm. I left this at default value, too.
http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/contrib/ntp/html/miscopt.html
Loopfilter's implementation can be found at:
http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/contrib/ntp/ntpd/ntp_loopfilter.c
http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/sys/sys/timex.h
Two simple examples of ntpd status decoding (see timex.h):
Status message "time sync enabled 2001" tells us:
STA_PLL 0x0001 [true] /* enable PLL updates (rw) */
STA_NANO 0x2000 [true] /* resolution (0 = us, 1 = ns) (ro) */
STA_MODE 0x4000 [false] /* mode (0 = PLL, 1 = FLL) (ro) *
STA_CLK 0x8000 [false] /* clock source (0 = A, 1 = B) (ro) */
- ------------------------------------------------------------------
0x2001 PLL upd. on, Resolution=ns, mode=PLL, clock-src=A
Status message "time sync enabled 6001" tells us:
STA_PLL 0x0001 [true] /* enable PLL updates (rw) */
STA_NANO 0x2000 [true] /* resolution (0 = us, 1 = ns) (ro) */
STA_MODE 0x4000 [true] /* mode (0 = PLL, 1 = FLL) (ro) *
STA_CLK 0x8000 [false] /* clock source (0 = A, 1 = B) (ro) */
- -----------------------------------------------------------------
0x6001 PLL upd. on, Resolution=ns, mode=FLL, clock-src=A
Cheers,
ch
- --
Christian Hiris <4711 at chello.at> | OpenPGP KeyID 0x3BCA53BE
OpenPGP-Key at hkp://wwwkeys.eu.pgp.net and http://pgp.mit.edu
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (FreeBSD)
iD8DBQFBoZag09WjGjvKU74RAoveAJ9vbuBz+wDK24VZL9+KSKL4GDvMcgCbBvzm
4Yd/BHzqkNicKibb+rlDky0=
=SH5B
-----END PGP SIGNATURE-----
More information about the freebsd-questions
mailing list