From owner-freebsd-questions@FreeBSD.ORG Fri Apr 14 15:54:00 2006 Return-Path: X-Original-To: freebsd-questions@freebsd.org Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D23FB16A400 for ; Fri, 14 Apr 2006 15:54:00 +0000 (UTC) (envelope-from dan@dan.emsphone.com) Received: from dan.emsphone.com (dan.emsphone.com [199.67.51.101]) by mx1.FreeBSD.org (Postfix) with ESMTP id 79BF843D6D for ; Fri, 14 Apr 2006 15:53:56 +0000 (GMT) (envelope-from dan@dan.emsphone.com) Received: (from dan@localhost) by dan.emsphone.com (8.13.1/8.13.4) id k3EFrh5m058803; Fri, 14 Apr 2006 10:53:43 -0500 (CDT) (envelope-from dan) Date: Fri, 14 Apr 2006 10:53:43 -0500 From: Dan Nelson To: Jonathan Horne Message-ID: <20060414155343.GD89228@dan.emsphone.com> References: <5507.208.11.134.3.1145029242.squirrel@mail.dfwlp.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <5507.208.11.134.3.1145029242.squirrel@mail.dfwlp.com> X-OS: FreeBSD 5.5-PRERELEASE X-message-flag: Outlook Error User-Agent: Mutt/1.5.11 Cc: freebsd-questions@freebsd.org Subject: Re: Proper Method of Time Sync? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 14 Apr 2006 15:54:01 -0000 In the last episode (Apr 14), Jonathan Horne said: > i have read about 2 methods to sync the time on a freebsd box. > > 1) add these entries to /etc/rc.conf: > ntpdate_enable="YES" > ntpdate_flags="us.pool.ntp.org" > ... and let the system do a one-time sync at bootup, and rely on this > single method for timesync. > > 2) add this entry to /etc/rc.conf > ntpd_enable="YES" > add the file with these contents to /etc/rc.conf: > server us.pool.ntp.org > driftfile /var/db/ntp.drift > restrict 192.168.1.0 mask 255.255.255.0 nomodify notrap > > so, i have a workstation and a server, which i originally did method > 1 on, but soon enough, time drifted quite a bit. so i switched it to > the 2nd method, and they appear to be sync'd perfectly. a third box > i set up, i did only method 2, and this one did not stay synced at > all. after i manually ran 'ntpdate -v -b us.pool.ntp.org', this box > straightend up. > > are both methods required for proper time syncronization, or can one > rely only on the ntpd method? ntpd takes a while to sync up and by default won't adjust the clock if it's more than 1000 seconds off, so it's a good idea to enable ntpdate as well. You don't need the ntpdate_flags variable; the startup script will grab server names out of /etc/ntp.conf . -- Dan Nelson dnelson@allantgroup.com