From owner-freebsd-stable@FreeBSD.ORG Wed Oct 10 22:43:09 2012 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 102269A3 for ; Wed, 10 Oct 2012 22:43:09 +0000 (UTC) (envelope-from mavbsd@gmail.com) Received: from mail-la0-f54.google.com (mail-la0-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 7B70F8FC08 for ; Wed, 10 Oct 2012 22:43:08 +0000 (UTC) Received: by mail-la0-f54.google.com with SMTP id e12so956306lag.13 for ; Wed, 10 Oct 2012 15:43:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:message-id:date:from:user-agent:mime-version:to:subject :references:in-reply-to:content-type:content-transfer-encoding; bh=aUcmEje0unzequVkzZ7/DXSXgPDQAekSBwdvrQ55Zi0=; b=Z1g9oUN4MS8vxVAbU+cIXS8pfDO5uWnoPtskp9DxPXVxWfawhoc/NkFqDiZao0Vwj9 h6Dt3AlCJGr+t15E3V36V1O0iGsasymZUy3Wm0RO01nDH/vbwWcivNiEc5EPNsJQsjW5 7l0EL2T7wGojg2dmJ+U4K46DRB2g8Gx8Qlw9OmM4Hy0ndZHG0O634FFXzjK9/wbukarn uhL0/vBn4MstpjolqG9myG9CptCmvwdUi8xoZd6LzCRIK790dFgRTfsBZ4OG7Za38SWj RwPxIAYeWPUppghIeaQuRN+8E0SlFb8d6EG6Qe3p0+pTKVXCFlf8qsLLMBSYuU2MTGak CipA== Received: by 10.152.104.240 with SMTP id gh16mr21407829lab.56.1349908987075; Wed, 10 Oct 2012 15:43:07 -0700 (PDT) Received: from mavbook.mavhome.dp.ua (mavhome.mavhome.dp.ua. [213.227.240.37]) by mx.google.com with ESMTPS id d1sm898944lbh.7.2012.10.10.15.43.05 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 10 Oct 2012 15:43:06 -0700 (PDT) Sender: Alexander Motin Message-ID: <5075F9F7.1040007@FreeBSD.org> Date: Thu, 11 Oct 2012 01:43:03 +0300 From: Alexander Motin User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:13.0) Gecko/20120628 Thunderbird/13.0.1 MIME-Version: 1.0 To: freebsd-stable@FreeBSD.org, jmg@funkthat.com Subject: Re: time keeps on slipping... slipping... References: <20121008040239.GE1967@funkthat.com> In-Reply-To: <20121008040239.GE1967@funkthat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.14 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, 10 Oct 2012 22:43:09 -0000 On 08.10.2012 07:02, John-Mark Gurney wrote: > I recently put together a new machine w/ a SuperMicro H8SCM and an > AMD Opteron 4228 HE... I've having an issue where the clock on the > machine skips around... The wierd part is that it's very sudden when > it happens... ntp sometimes brings it back, but it can't when the clock > gets too far ahread (1000 seconds), ntp dies... > > In order to catch it happening, I ran a sleep 60 loop fetching time > from another server that keeps time correctly via: > while sleep 60; do echo -n h2:; nc h2 13; date; ntpdate h2.funkthat.com; done > > here are some snippits: > h2:Sun Oct 7 17:12:54 2012^M > Sun Oct 7 17:12:54 PDT 2012 > 7 Oct 17:12:54 ntpdate[31036]: the NTP socket is in use, exiting > h2:Sun Oct 7 17:13:48 2012^M > Sun Oct 7 17:20:21 PDT 2012 > 7 Oct 17:20:21 ntpdate[31045]: the NTP socket is in use, exiting > > but then ntp brings it back in sync: > h2:Sun Oct 7 17:28:49 2012^M > Sun Oct 7 17:35:21 PDT 2012 > 7 Oct 17:35:21 ntpdate[31164]: the NTP socket is in use, exiting > h2:Sun Oct 7 17:29:49 2012^M > Sun Oct 7 17:29:49 PDT 2012 > 7 Oct 17:29:49 ntpdate[31170]: the NTP socket is in use, exiting > > It happens pretty often: > Oct 7 00:19:13 gold ntpd[3721]: time reset -785.347912 s > Oct 7 00:46:37 gold ntpd[3721]: time reset -392.673256 s > Oct 7 01:04:24 gold ntpd[3721]: time reset -785.346533 s > Oct 7 15:00:59 gold ntpd[3721]: time reset -392.681720 s > Oct 7 16:32:11 gold ntpd[3721]: time reset -392.671268 s > Oct 7 17:29:29 gold ntpd[3721]: time reset -392.671752 s > Oct 7 18:04:37 gold ntpd[3721]: time reset -785.346987 s > > but as you can see above, the time slip happens abruptly.. looks like > a rounding error or something... > > I'm now reducing the sleep to 5 seconds... but as you can see the sleep > ends a few seconds early and local time suddenly jumped forward 6 > minutes 33 seconds... > > $ sysctl kern.timecounter > kern.timecounter.fast_gettime: 1 > kern.timecounter.tick: 1 > kern.timecounter.choice: TSC-low(1000) ACPI-safe(850) HPET(950) i8254(0) dummy(-1000000) > kern.timecounter.hardware: TSC-low > kern.timecounter.stepwarnings: 0 > kern.timecounter.tc.i8254.mask: 65535 > kern.timecounter.tc.i8254.counter: 11598 > kern.timecounter.tc.i8254.frequency: 1193182 > kern.timecounter.tc.i8254.quality: 0 > kern.timecounter.tc.HPET.mask: 4294967295 > kern.timecounter.tc.HPET.counter: 3257069245 > kern.timecounter.tc.HPET.frequency: 14318180 > kern.timecounter.tc.HPET.quality: 950 > kern.timecounter.tc.ACPI-safe.mask: 16777215 > kern.timecounter.tc.ACPI-safe.counter: 4219134510 > kern.timecounter.tc.ACPI-safe.frequency: 3579545 > kern.timecounter.tc.ACPI-safe.quality: 850 > kern.timecounter.tc.TSC-low.mask: 4294967295 > kern.timecounter.tc.TSC-low.counter: 2854866610 > kern.timecounter.tc.TSC-low.frequency: 10937740 > kern.timecounter.tc.TSC-low.quality: 1000 > kern.timecounter.smp_tsc: 1 > kern.timecounter.invariant_tsc: 1 > $ sysctl kern.eventtimer > kern.eventtimer.choice: LAPIC(400) i8254(100) RTC(0) > kern.eventtimer.et.LAPIC.flags: 15 > kern.eventtimer.et.LAPIC.frequency: 100002217 > kern.eventtimer.et.LAPIC.quality: 400 > kern.eventtimer.et.i8254.flags: 1 > kern.eventtimer.et.i8254.frequency: 1193182 > kern.eventtimer.et.i8254.quality: 100 > kern.eventtimer.et.RTC.flags: 17 > kern.eventtimer.et.RTC.frequency: 32768 > kern.eventtimer.et.RTC.quality: 0 > kern.eventtimer.periodic: 0 > kern.eventtimer.timer: LAPIC > kern.eventtimer.activetick: 1 > kern.eventtimer.idletick: 0 > kern.eventtimer.singlemul: 2 > > I have switched my timecounter to HPET to see if things are different... > > Any clues? Mentioned switching to HPET could tell a lot about the problem. Switching event timer also may be interesting. -- Alexander Motin