Monitoring busy/pool servers

Hal Murray hmurray at
Thu Dec 15 01:07:22 UTC 2016

Context is mrulist not working on ntpq when there are lots of slots.]

> I think you have misdiagnosed this. My testing on your flaky wifi link
> suggested strongly that lots of clients isn't the issue - lots of packet
> dropouts is the issue. 

The new ntpq times out when run via localhost.

The old ntpq works over the net.

The old ntpq prints out occasional progress messages, like:
580 (0 updates) 
696 (0 updates) 
812 (0 updates) 
It actually rewrites the same line.  I poked return a few times to get that.

The new version never prints out anything so I have no idea if it's making 
any progress.

When it gets to the top of my list, I'll work on it.  In the mean time, 
anybody who tries to use it on a server with lots of clients should know it 
will appear to hang.

> The only way to fix this would be to extend the protocol, give mode 6
> clients a way to request newest first.  If we're going to do that we might
> as well support capping the count to be returned. 

The problem is what to do when the data you are trying to collect gets 

With oldest-first, an old one gets promoted and you get the updated version 
as a duplicate.  (That's the updates above.)  That doesn't work with 

I think we could hack it to do something like start at slot N rather than the 
end.   It would have to do a list traversal from the start to get to the 
starting point.  That would be tolerable for what we want if we put a 
reasonable limit on N.

I think the oldest first will hang if the retrieval is slow enough and the 
server is busy enough so that slots get updated faster than it can retrieve 

>> The mru sort options are also reversed in some options.
> That's trivial to fix.  I already told you how, in fact. 

You only pointed me at half the code - the place that sets up the sort.  I 
haven't found the place that actually does the sort.  I think I understand 
the setup code.  It looks like the actual sort is backwards.

I just need to find/make enough time to learn my way around the new ntpq and 
packet code.

These are my opinions.  I hate spam.

More information about the devel mailing list