From owner-freebsd-stable@FreeBSD.ORG Wed Jun 7 13:07:03 2006 Return-Path: X-Original-To: stable@freebsd.org Delivered-To: freebsd-stable@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D7EA816DA73 for ; Wed, 7 Jun 2006 12:15:06 +0000 (UTC) (envelope-from freebsd-stable-local@be-well.ilk.org) Received: from mail8.sea5.speakeasy.net (mail8.sea5.speakeasy.net [69.17.117.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 796D043D48 for ; Wed, 7 Jun 2006 12:15:04 +0000 (GMT) (envelope-from freebsd-stable-local@be-well.ilk.org) Received: (qmail 2607 invoked from network); 7 Jun 2006 12:15:03 -0000 Received: from dsl092-078-145.bos1.dsl.speakeasy.net (HELO be-well.ilk.org) ([66.92.78.145]) (envelope-sender ) by mail8.sea5.speakeasy.net (qmail-ldap-1.03) with SMTP for ; 7 Jun 2006 12:15:03 -0000 Received: by be-well.ilk.org (Postfix, from userid 1147) id A39572842A; Wed, 7 Jun 2006 08:15:02 -0400 (EDT) To: John Nielsen References: <200606051335.32838.lists@jnielsen.net> From: Lowell Gilbert Date: Wed, 07 Jun 2006 08:15:02 -0400 In-Reply-To: <200606051335.32838.lists@jnielsen.net> (John Nielsen's message of "Mon, 5 Jun 2006 13:35:32 -0400") Message-ID: <44irnd6u2h.fsf@be-well.ilk.org> User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (berkeley-unix) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: stable@freebsd.org Subject: Re: MySQL, ntpd, and kern.timecounter X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 07 Jun 2006 13:07:32 -0000 John Nielsen writes: > I have a FreeBSD 6.1 machine set up as a web and MySQL database server. Since > the application is a bit database-intensive, I followed several of the MySQL > tuning recommendations from this page: > > http://wikitest.freebsd.org/MySQL > > One of those was to change kern.timecounter.choice from ACPI-fast to TSC. > > That was fine for MySQL, but the real-world timekeeping on this hardware with > TSC is so bad that it broke ntpd and the clock started drifting several > seconds every hour. Timekeeping with ACPI-fast was quite reliable. > > I'm looking for recommendations in general, but I'll pose a few specific > questions below as well. > > Should I change the timecounter back? How big an impact does the choice of > timecounter have on performance with MySQL 4.1.19 and FreeBSD 6.1? Is there a > conservative way I can answer this question myself for a server that's > already in production? Benchmarking on a live system is tough. You can switch the timecounter back and forth easily enough, but measuring performance requires a predictable load. I don't know anything about mysql in particular, but on a fast machine, with the database as the primary application, I wouldn't expect choice of clock tick to affect the performance very much. > Can ntpd be coaxed into working with such bad timekeeping (as long as it's > consistently bad)? You're not using a driftfile? That should compensate for systematic drift pretty well. You just specify the file (which ntpd has to be able to write) in the configuration file for ntpd (/etc/ntp.conf by default). > Would Bad Things happen if I ran ntpdate or ntpd -q once or twice a day? Would > this be considered an abuse of the ntp server(s)? Would I run a risk of > confusing / breaking cron or sendmail or syslogd or anything else with the > time jumps? Nothing horrible would happen, but it could be annoying. I'd recommend you avoid it.