From owner-freebsd-questions Thu Apr 6 18:53:22 2000 Delivered-To: freebsd-questions@freebsd.org Received: from mail.hiwaay.net (fly.HiWAAY.net [208.147.154.56]) by hub.freebsd.org (Postfix) with ESMTP id D993137C1C4 for ; Thu, 6 Apr 2000 18:53:13 -0700 (PDT) (envelope-from dkelly@hiwaay.net) Received: from nospam.hiwaay.net (tnt8-216-180-72-75.dialup.hiwaay.net [216.180.72.75]) by mail.hiwaay.net (8.10.0/8.10.0) with ESMTP id e371r9S23922; Thu, 6 Apr 2000 20:53:09 -0500 (CDT) Received: from localhost (localhost [127.0.0.1]) by nospam.hiwaay.net (8.9.3/8.9.3) with ESMTP id UAA11635; Thu, 6 Apr 2000 20:24:53 -0500 (CDT) (envelope-from dkelly@nospam.hiwaay.net) Message-Id: <200004070124.UAA11635@nospam.hiwaay.net> X-Mailer: exmh version 2.1.1 10/15/1999 To: Sheldon Hearn Cc: Greg Black , FreeBSD-questions@FreeBSD.ORG From: David Kelly Subject: Re: Kernel adjustment for clock drift In-reply-to: Message from Sheldon Hearn of "Thu, 06 Apr 2000 13:35:50 +0200." <13835.955020950@axl.ops.uunet.co.za> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Thu, 06 Apr 2000 20:24:53 -0500 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Sheldon Hearn writes: > > > On Thu, 06 Apr 2000 20:09:50 +1000, Greg Black wrote: > > > I have a machine that drifts about 7 seconds a day and I'd like to > > tweak something in the kernel to keep it closer to the truth. The > > clock gets corrected once a day by ntpdate, but I'd like to avoid such > > big adjustments. > > This is not a direct answer to the question you asked. :-) > > Is it impossible for you to > > a) run ntpdate at more regular intervals > > or > > b) use ntpd, also in the base system? > > Presumably you're talking about a frequently unconnected host using > automatic ppp? If so, you could run ntpdate out of ppp.linkup. > Alternatively, you could run ntpd and set up ppp's dial and active > filters so that ntpd's synchronization attempts do not cause a dial > attempt nor keep an existing connection alive. See my other posting to this list. I ran xntpd for years on a dialup connection. Connected an hour or two or three per day. Xntpd doesn't seem to have any problems resuming when the connection resumes. Xntpd *does* spit a message into syslogd whenever it first loses its connections. Observed xntpd disappeared with FreeBSD 4.0 and now we have ntpd. Seems to work exactly the same. I didn't change anything. One "gotcha" is that xntpd didn't like to be started unless it had a nework connection. So don't put it in an rc startup file. I start ntpd now by hand first time I think of it when connected after a reboot. The other "gotcha" is that you don't want [x]ntpd keeping your dialup ppp link active. I manually invoke pppd and kill it. There are filtering rules for pppd and ppp so auto-dial will not be triggered by ntp. [X]ntpd will calculate your system clock drift and apply pre-emptive adjustments to keep it tuned. Looks like ntpd has been adjusting my clock back 1 second about once per day when its connected. Its only had 4 days since I changed over from xntpd and the driftfile value may have changed units. -- David Kelly N4HHE, dkelly@hiwaay.net ===================================================================== The human mind ordinarily operates at only ten percent of its capacity -- the rest is overhead for the operating system. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message