From owner-freebsd-stable Thu Jul 22 23: 6:36 1999 Delivered-To: freebsd-stable@freebsd.org Received: from zibbi.mikom.csir.co.za (zibbi.mikom.csir.co.za [146.64.24.58]) by hub.freebsd.org (Postfix) with ESMTP id 708751568F for ; Thu, 22 Jul 1999 23:06:23 -0700 (PDT) (envelope-from jhay@zibbi.mikom.csir.co.za) Received: (from jhay@localhost) by zibbi.mikom.csir.co.za (8.9.3/8.9.3) id IAA30989; Fri, 23 Jul 1999 08:05:44 +0200 (SAT) (envelope-from jhay) From: John Hay Message-Id: <199907230605.IAA30989@zibbi.mikom.csir.co.za> Subject: Re: Tuning the system's clock In-Reply-To: <001801bed47a$0efc31a0$021d85d1@youwant.to> from David Schwartz at "Jul 22, 1999 12:40:31 pm" To: davids@webmaster.com (David Schwartz) Date: Fri, 23 Jul 1999 08:05:44 +0200 (SAT) Cc: stable@FreeBSD.ORG X-Mailer: ELM [version 2.4ME+ PL54 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Ok, lets try this the other way around. Changing the frequency with the machdep.tsc_freq or machdep.i8254_freq sysctl (depending on your machine type) should work. I does work for me here on a lot of machines where I have it in a script in /usr/local/etc/rc.d/ and I have used it on the commandline a lot. So if there is a problem with it, it probably is something specific to your machine. Can you give us some more info about your machine? Do you have apm enabled? The dmesg output would be nice and also the versions of the source files: /sys/kern/kern_ntptime.c /sys/kern/kern_clock.c /sys/i386/isa/clock.c Or if you don't have the source but installed from a -STABLE snapshot and are still using the standard kernel, just the date of the snap should do. John -- John Hay -- John.Hay@mikom.csir.co.za > > > > > > FreeBSD's internal high-precision clock seems to be based on the > > > processor's instruction cycle counter. I've found that on one > > machine, the > > > clock is about 150 ppm fast. So I tried to reduce the machdep.tsc_freq > > > value. That was bad -- instant reboot. ... > (tock.gpsclock.com). It takes it about 15 minutes after a reboot to > stabilize. I think I could halve this time if I could set an initial > estimate of the TSC counter. > ... > > In any event, tuning the TSC divisor via sysctl causes my FreeBSD-STABLE > machine to reboot instantly. I've just found that NTP seems to work the best > when the system is already keeping pretty good time. > > David Schwartz > http://www.gpsclock.com/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message