Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 19 Dec 2009 14:10:40 +0200
From:      Omer Faruk Sen <omerfsen@gmail.com>
To:        FreeBSD <freebsd-questions@freebsd.org>
Subject:   ntpq command output and unreachable state?
Message-ID:  <75a268720912190410x5bd2790du44299c0bbb2aca40@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi,

I am trying to understand output of ntpq -c peers (or ntpq -p). What I
am trying to understand that when a ntp server is announced as
unreachable. I have made a test. I setup a test ntp server with


/etc/ntp.conf
=============
restrict default nomodify notrap noquery
restrict 127.0.0.1
server 0.pool.ntp.org
server clock.isc.org

and started ntpd daemon using

/usr/sbin/ntpd -c /etc/ntp.conf -p /var/run/ntpd.pid -f
/var/db/ntpd.drift -g -l /var/log/ntpd.log

and blocked all port 123 traffic that goes out from this ntp server at
my gateway (to simulate to lost connection on ntp servers at ntp.conf)
After 26 hours later my ntpd still thinks that it can reach to
"clock.isc.org" (as can be seen with "*" mark before clock.isc.org
below)

# ntpq -c peers
     remote           refid      st t when poll reach   delay   offset  jitter
==============================================================================
+194.27.110.130  131.188.3.220    2 u  27h 1024    0   67.816   13.282   0.000
*clock.isc.org   204.123.2.5      2 u  26h 1024    0  224.461  -15.208   0.000

But I am sure that it can't reach (I sniff my firewall so no traffic
comes from clock.isc.org). My question is how can I find out that my
ntp servers defined at ntp.conf are unreachable (I know that if ntp
server is unreachable than my local ntp server stops to answer for ntp
 requests)

Best Regards.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?75a268720912190410x5bd2790du44299c0bbb2aca40>