From owner-freebsd-current@FreeBSD.ORG Thu Feb 5 05:20:53 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D2FC916A4CE for ; Thu, 5 Feb 2004 05:20:53 -0800 (PST) Received: from critter.freebsd.dk (critter.freebsd.dk [212.242.86.163]) by mx1.FreeBSD.org (Postfix) with ESMTP id D557743D73 for ; Thu, 5 Feb 2004 05:20:35 -0800 (PST) (envelope-from phk@phk.freebsd.dk) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.12.10/8.12.10) with ESMTP id i15DK8DF044132; Thu, 5 Feb 2004 14:20:08 +0100 (CET) (envelope-from phk@phk.freebsd.dk) To: "Cyrille Lefevre" From: "Poul-Henning Kamp" In-Reply-To: Your message of "Thu, 05 Feb 2004 14:15:13 +0100." <075c01c3ebea$178b36e0$7890a8c0@dyndns.org> Date: Thu, 05 Feb 2004 14:20:08 +0100 Message-ID: <44131.1075987208@critter.freebsd.dk> cc: "current @FreeBSD.org" Subject: Re: wrong kern.boottime X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 Feb 2004 13:20:53 -0000 In message <075c01c3ebea$178b36e0$7890a8c0@dyndns.org>, "Cyrille Lefevre" write s: >> >ntpd is running, so, I'm on time. >> >> Hmm, I'm not sure where last gets it's number from, maybe from utmp. > >no, from wtmp. > >> If the utmp record is written on boot before ntpd corrects the clock >> that would be one explanation... >> >> Either way, I'm pretty sure that kern.boottime contains what it should >> contain: Our best estimate of the time when the system was booted. > >absolutely not, the real boot time was the wtmp time which is the same >as /var/run/dmesg.boot. > >a proof of the real boot time : > ># bzgrep Accounting /var/log/messages.* >messages.2.bz2:Feb 1 21:40:43 gits kernel: Accounting enabled This is only a proof if the machine was NTPD'synced at this time. If your CMOS clock was a couple of days off, your system would boot with that time, and not until NTPD gets its act together would the clock be stepped to the right time. This is still the best theory I can come up with. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.