[ntp:questions] Question about using server stratum 15

Toshikazu Nakayama nakayama.ts at ncos.nec.co.jp
Tue Aug 20 13:31:16 UTC 2019


Hello, 

I recently update ntp version from 4.2.6p1to 4.2.8p13.
After updated ntp client in equipment, it become not to synchronize to ntp server at all.
(This ntp server send PDU with stratum filed 15 to new client, new client drop such PDUs)

We investigated this issue and found corresponding changes between 4.2.6p1 and 4.2.8p13
committed around Dec 2011. (I'm sorry about the old updates.)

At first, this is already described in html/select.html. as known restriction.
"Note that 15 is a valid stratum, but a server operating at that stratum cannot synchronize clients."

And this description seems to be appended by Bug#2068 (ntpd sends nonprintable stratum 16 refid to ntpq.).

-int    sys_ceiling = STRATUM_UNSPEC; /* cluster stratum ceiling */
+int    sys_ceiling = STRATUM_UNSPEC - 1; /* cluster stratum ceiling */

This sys_ceiling change (16=>15) makes TEST6 failure if pstratum value is 15.
And I understood this TEST6 failure is described as stratum 15 sever restrction html/select.html..

        /*
         * Verify the server is synchronized; that is, the leap bits,
         * stratum and root distance are valid.
         */
        if (   pleap == LEAP_NOTINSYNC          /* test 6 */
            || pstratum < sys_floor || pstratum >= sys_ceiling)
                peer->flash |= TEST6;           /* bad synch or strat */

My question is why condition could not be changed to (pstratum > sys_ceiling)
instead of appending restriction for stratum 15 sever at that time?

However, I wonder our ntp usage is insane?
I can not find any discussions for this from archives although it was done for 8 years ago.

Regards,
Toshikazu Nakayama.



More information about the questions mailing list