[ntp:questions] NTP server - Number of received petitions.

Miroslav Lichvar mlichvar at redhat.com
Tue Mar 21 12:17:44 UTC 2017

On Tue, Mar 21, 2017 at 12:01:21PM +0000, Raúl wrote:
> But I don't need anything special, I'm just looking how to know the load of
> my NTP server, how many request I'm receiving from clients. I thought that
> doing that would be easy.

If you just need current rate of requests and don't care about
individual clients, you could periodically call ntpdc -c iostats and
calculate the rate from the total number of received packets using awk
for instance:

while true; do ntpdc -c iostats; sleep 1; done | \
	awk '/received packets/{ print $3 - last; last=$3}' 

Miroslav Lichvar

More information about the questions mailing list