[ntp:questions] Test ntpd performance
Dave Hart
hart at ntp.org
Sat Sep 25 23:31:24 UTC 2010
On Fri, Sep 24, 2010 at 6:23 PM, R C <rc_work at yahoo.com> wrote:
> I want to test the performance of the ntpd server. Are there any free/open
> source ntp clients that measure the server scalability?
I don't know of any such scalability-testing client software, but I
can tell you ntpd scalability is typically a non-issue. The traffic
involves small packets, which take very little time to process, so
typically you'll run into router scalability issues before server
ones.
I am involved with a publicly-accessible pool.ntp.org server running
on a 2.5 GHz Celeron. It uses ntpd built without disabling ntpd's
built-in debugging support, though it is using compiler optimization,
it's also carrying around extra sanity-checking code and activity
tracing that is typically not enabled at runtime, but still causes
extra overhead compared to a ntpd configured with --disable-debugging.
Here's some hard data on its scalability:
hart at pool1> ps ax | fgrep ntpd
3332 ?? Rs 193:57.22 /usr/local/bin/ntpd -c /etc/ntp.conf -g
3333 ?? I 0:16.44 /usr/local/bin/ntpd -c /etc/ntp.conf -g
21884 p0 R+ 0:00.00 fgrep ntpd
hart at pool1> ntpq -c sysstats
uptime: 789921
sysstats reset: 789921
packets received: 181690517
current version: 115060504
older version: 50474534
bad length or format: 16152355
authentication failed: 369435
declined: 2605
restricted: 11647
rate limited: 15114153
KoD responses: 1291563
processed for time: 54715
hart at pool1>
There are two ntpd processes, the second is a DNS worker child of the
first. Apparently there's a DNS name in its ntp.conf which isn't
resolving which it is continuing to retry occasionally. In 789921s,
it has consumed 11654s of CPU time, or about 1.5%. Undoubtedly
there's some system overhead not accounted for in that CPU time, but
you can see the CPU requirement to keep up with an average of 230
requests/s is marginal. Its ntpd performance is great:
hart at pool1> ntpq -crv -p
associd=0 status=0618 leap_none, sync_ntp, 1 event, no_sys_peer,
version="ntpd 4.2.7p50 at 1.2188-o Thu Sep 16 19:45:06 UTC 2010 (3)",
processor="i386", system="FreeBSD/6.4-STABLE", leap=00, stratum=2,
precision=-20, rootdelay=1.637, rootdisp=10.881, refid=127.67.113.92,
reftime=d04902de.fb29a07c Sat, Sep 25 2010 23:23:10.981,
clock=d0490453.ef2cc9cb Sat, Sep 25 2010 23:29:23.934, peer=37589, tc=7,
mintc=3, offset=-0.035, frequency=-67.148, sys_jitter=0.831,
clk_jitter=0.092, clk_wander=0.001
remote refid st t when poll reach delay offset jitter
==============================================================================
192.168.4.255 .BCST. 16 B - 64 0 0.000 0.000 0.001
-clock.sjc.he.ne .CDMA. 1 u 1 128 377 0.550 -1.135 1.203
+clock.fmt.he.ne .PPS. 1 u 122 128 377 1.092 0.015 0.056
*clock.fmt.he.ne .PPS. 1 u 108 128 377 1.637 -0.203 0.883
+clepsydra.dec.c .GPS. 1 u 116 128 377 0.679 0.017 0.015
+usno.pa-x.dec.c .USNO. 1 u 102 128 377 0.616 0.048 0.235
-psp-os1.ntp.org 192.168.4.22 3 s 63 64 376 0.111 -0.019 0.039
-clock.isc.org .GPS. 1 u 7 128 377 0.228 -3.965 0.390
149.20.54.20 (p 131.107.13.100 2 u 109 128 377 0.328 8.792 3.214
hart at pool1>
Would you mind elaborating on what question(s) you hope to answer
through testing?
Cheers,
Dave Hart
More information about the questions
mailing list