From owner-freebsd-questions@FreeBSD.ORG Sat Dec 19 16:28:12 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 2262010656A8 for ; Sat, 19 Dec 2009 16:28:12 +0000 (UTC) (envelope-from omerfsen@gmail.com) Received: from mail-fx0-f227.google.com (mail-fx0-f227.google.com [209.85.220.227]) by mx1.freebsd.org (Postfix) with ESMTP id AD5CB8FC21 for ; Sat, 19 Dec 2009 16:28:11 +0000 (UTC) Received: by fxm27 with SMTP id 27so3663710fxm.3 for ; Sat, 19 Dec 2009 08:28:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=X+Exva39+d0DYS8y2Pl/deJ0FTwrupa1ABCRAl4HwmY=; b=ho21X8u3B+b5ol1Z/CaFWyxKcrIe4M0w+8jzbE7+xnRZ6VodeOeEB4pJLxujh8XRuv qUDaRUeaS1xDSa3loIx3WJ3ooqIFhmZ+v9dNA/0ixL+r48ky22vAg5qIYpRFlx3brr0Y WeK8JMNufbzozjO9GtuE4rucBQNZHZqG0mJf0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=J8THlbUEwEHjro4WiD6UykKG+EzPCnURIZSPG3DVOahKmj0/M0fBl+3T93fgibyXrO 9YWQXXIJP84RfMTWcJmngOS8GKkWhrQJXLo/7QK/hNLC2qTrVD/xVzOtQZeL4v4ZZJIV //7C6CnBpXkBwN3r/nhoGeKEZtpKTpRdQi0MU= MIME-Version: 1.0 Received: by 10.239.132.203 with SMTP id 11mr558381hbs.84.1261240090687; Sat, 19 Dec 2009 08:28:10 -0800 (PST) In-Reply-To: <75a268720912190410x5bd2790du44299c0bbb2aca40@mail.gmail.com> References: <75a268720912190410x5bd2790du44299c0bbb2aca40@mail.gmail.com> Date: Sat, 19 Dec 2009 18:28:10 +0200 Message-ID: <75a268720912190828k5683aafch28b2c75d35a9d6d0@mail.gmail.com> From: Omer Faruk Sen To: FreeBSD Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: ntpq command output and unreachable state? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 19 Dec 2009 16:28:12 -0000 I have used ntpq -c associations to see if the server is reachable or not. But even the peers are not reachable my ntpd answers to queries for some time and after recovering connection (reachable state) my ntpd doesn't answer to ntp clients even if ntpq -c peers states "*" state. But after certain amount of time time can be synced with my ntpd server. (this recovery process took more than 1 hour in my test setup). On Sat, Dec 19, 2009 at 2:10 PM, Omer Faruk Sen wrote: > 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 > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > 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 > =A0 =A0 remote =A0 =A0 =A0 =A0 =A0 refid =A0 =A0 =A0st t when poll reach = =A0 delay =A0 offset =A0jitter > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D > +194.27.110.130 =A0131.188.3.220 =A0 =A02 u =A027h 1024 =A0 =A00 =A0 67.8= 16 =A0 13.282 =A0 0.000 > *clock.isc.org =A0 204.123.2.5 =A0 =A0 =A02 u =A026h 1024 =A0 =A00 =A0224= .461 =A0-15.208 =A0 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 > =A0requests) > > Best Regards. >